DehazeNet_Pytorch
DehazeNet_Pytorch copied to clipboard
The effect of the result image is very poor, how should I modify the code?
I ran the DehazeNet-pytorch.py.
Then I got a result image like this:
While its origin like this:
Please tell me what to do to correct the image!!
I have encountered the same problem. Could I ask you if the problem have been solved?
请问这个问题解决了吗?求解决方法
求解决方法
保存结果的时候换一种保存方式就好了,比如用 torchvision.utils.save_image(torch.cat((img2, img3), 0), "DehazeNet_results/" + pic_dir.split("\")[-1])
DehazeNet_pytorch.py的195行和196行的defog_img = transforms.ToPILImage()(img2)和defog_img.save('/home/panbing/PycharmProjects/defog/test/test.jpg')注释掉,改为torchvision.utils.save_image(img2, './test.jpg')