huawei-noah/Pretrained-IPT

初学者复现出现 PSNR: nan (Best: nan @epoch 1)

oneonejia opened this issue · 5 comments

I input :
python main.py --dir_data C:/Users/Lenovo/Desktop/Pretrained-IPT-main/data_test/benchmark/ --pretrain C:/Users/Lenovo/Desktop/Pretrained-IPT-main/pretrained_model/IPT_sr2.pt --data_test Set5+Set14+B100+Urban100 --scale 2

出现了
Making model...
Preparing loss function:
1.000 * L1

Evaluation:
0it [00:00, ?it/s]

[Set5 x2] PSNR: nan (Best: nan @epoch 1)
0it [00:00, ?it/s]
0it [00:12, ?it/s]

[Set14 x2] PSNR: nan (Best: nan @epoch 1)
0it [00:00, ?it/s]

[B100 x2] PSNR: nan (Best: nan @epoch 1)
0it [00:00, ?it/s]

[Urban100 x2] PSNR: nan (Best: nan @epoch 1)
Forward: 49.39s

代码未读取到数据集,请参考readme来设置数据路径

我新建了一个pretrained_model文件夹,把benchmark和CBSD68以及Rain100L放在下面
输入python main.py --dir_data pretrained_model/benchmark --pretrain pretrained_model/IPT_sr2.pt --data_test Set5+Set14+B100+Urban100 --scale 2
还是出现了
Evaluation:
0it [00:00, ?it/s]

[Set5 x2] PSNR: nan (Best: nan @epoch 1)
0it [00:00, ?it/s]
0it [00:12, ?it/s]

[Set14 x2] PSNR: nan (Best: nan @epoch 1)
0it [00:00, ?it/s]

[B100 x2] PSNR: nan (Best: nan @epoch 1)
0it [00:00, ?it/s]

[Urban100 x2] PSNR: nan (Best: nan @epoch 1)
Forward: 49.39s
是哪里出现了问题呀

文件夹中图片是否以如下路径存放?

Note: path of images should be like: $MODEL_PATH/benchmark/Set5/HR/XXX.png and $MODEL_PATH/benchmark/Set5/LR_bicubic/XXX.png

你好,关于分辨率和去噪我已经解决。但是去雨部分的还是读取不到数据集
输入
python main.py --dir test_data --pretrain model/IPT_derain.pt --scale 1 --derain
数据集是按如下放置的
$MODEL_PATH/Rain100L/rain-XXX.png 和 $MODEL_PATH/Rain100L/norain-XXX.png

@oneonejia 可以向你咨询一下IPTSR复现的问题吗