super-resolution icon indicating copy to clipboard operation
super-resolution copied to clipboard

Have you ever trained SRCNN with RGB three channels image?

Open YoungMagic opened this issue 6 years ago • 8 comments

I changed the ‘load_img' function in file ‘dataset.py’ to load RGB images. And the parameter 'num_channels' in 'build_model' function in 'solver.py' to 3. And the 'super_resolve.py' to load the model and generate HR. But the result is weird. Do you have any idea?

bsd100_007out_srf_4_22 808_0 6693

If I train only with Y channel, the final RGB image don't get much better compared with the bicubic interpolation. I guess it's caused by the fact that reconstruction with one channel and the other two using bicubic to form the final RGB image. set5_003srcnn

I'd like to train with RBG channels. But the final result is a bit unpleasing. Did I miss to change something?Do you have any suggestions? Thanks!

YoungMagic avatar Dec 27 '18 08:12 YoungMagic

i got the same problem like you. Maybe the algorithm does not fit for colorful image. amtsx4xbh3n21

amazingyyc avatar Mar 25 '19 14:03 amazingyyc

I got this issue too, but I don't know what causes this problem. RIght now I rarely have time diving into the papers to find out a solution. Maybe looking for some other implementation online?

soapisnotfat avatar Mar 25 '19 18:03 soapisnotfat

My result is based on another implement for FSRCNN. Maybe lost some algorithm detail. Maybe it does not works well for colorful image, Not sure....

amazingyyc avatar Mar 26 '19 02:03 amazingyyc

Happened to me too and it was caused by a color channel overflow (I have been scaling pixel vales from [0, 1] to [0, 255] and due to some rounding errors I sometimes got 255.00...1, which turned to 0). That's why this artefact happens mostly in bright areas. Solution is to clip the values to valid range with numpy.clip(img, 0, 1) or numpy.clip(img, 0, 255).

m-sche avatar Nov 22 '19 02:11 m-sche

Hello There is a problem makes me confused that how to train FSRCNN model for scale 2 or scale 4 on basic of scale 3

wfxiaobo avatar Mar 31 '20 03:03 wfxiaobo

Happened to me too and it was caused by a color channel overflow (I have been scaling pixel vales from [0, 1] to [0, 255] and due to some rounding errors I sometimes got 255.00...1, which turned to 0). That's why this artefact happens mostly in bright areas. Solution is to clip the values to valid range with numpy.clip(img, 0, 1) or numpy.clip(img, 0, 255).

I solve the problem using this too.

543877815 avatar Feb 04 '21 07:02 543877815

Hello There is a problem makes me confused that how to train FSRCNN model for scale 2 or scale 4 on basic of scale 3

I have encountered the same problem. How did you solve it?

liujie316316 avatar Oct 08 '22 07:10 liujie316316

We trained other scales based on scale 3 when the model is convergent on scale 3.

魏峰 @.***

 

------------------ 原始邮件 ------------------ 发件人: "soapisnotfat/super-resolution" @.>; 发送时间: 2022年10月8日(星期六) 下午3:15 @.>; @.@.>; 主题: Re: [soapisnotfat/super-resolution] Have you ever trained SRCNN with RGB three channels image? (#14)

Hello There is a problem makes me confused that how to train FSRCNN model for scale 2 or scale 4 on basic of scale 3

I have encountered the same problem. How did you solve it?

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you commented.Message ID: @.***>

wfxiaobo avatar Oct 11 '22 07:10 wfxiaobo