sanghyun-son / EDSR-PyTorch

PyTorch version of the paper 'Enhanced Deep Residual Networks for Single Image Super-Resolution' (CVPRW 2017)
MIT License
2.42k stars 668 forks source link

Superresolution at x1 #33

Closed ontheway16 closed 6 years ago

ontheway16 commented 6 years ago

Hello, I am new to SR and playing with your creation. Decided to use it on formerly scanned paper printed photos from past and get very nice results. But the problem is, scans are already big in filesize so I am splitting them to many pieces due to GPU mem limit. If we can use SR to just to enhance photo while preserving the same resolution, It will (probably) consume less memory during process, meaning less parts to split. May it be possible to give a command like below, one day? :)

python main.py --data_test Demo --scale 1 --pre_train ../experiment/model/EDSR_baseline_x1.pt --test_only --save_results

I appreciate if you consider possibilities for this.

sanghyun-son commented 6 years ago

Hello.

As I understand, you want to enhance the image quality without increasing their resolutions.

However, we do not use the term 'super-resolution'.

I guess simple edge sharpening or denoising can give you nice outputs in that case.

If you are having problem with limited GPU memory, we support --chop argument for inference.

It internally chops down the input image and prevent GPU memory from overflow, so you can use very large images for the input.

I am wondering if I understood your question correctly.

Please let me know if you have any trouble with my answer.

Thank you!

ontheway16 commented 6 years ago

First, thank you very much for your kind answer.

For enhance, I need more than regular image enhancement tools available in photshop etc.

Old photos (developed from film roll) is mostly not sharp or not detailed, or slightly out of focus, slightly blurry in general. Thats why I desired to utilize a SR network, and the fact is, I am very happy with the results, compared to traditional enhancement methods, my only issue is, when stitching SR-applied pieces together manually, seam lines was appearing but you are saying theres a -chop option. I am going to try this as soon as possible.

Again, appreciate for this code.

suke27 commented 6 years ago

it seems you just want to deblur, denoise, but not super resolution, I think you can search some DL algorithm for deblur and denoise

ontheway16 commented 6 years ago

@suke27 Thanks I will investigate this option too, but my split-rebuild problem is already solved thanks to the chop option. Since number of photo scans are not so many, the code is working very well for my need. My request for x1 was related to the need to manually split images (GPU mem limit), which is not necessary anymore. Just tested with a 7200x5400 jpeg image, processed in 111 seconds, perfect.

@thstkdgus35 Accidentally realized capital file extensions may cause failure, like .JPG, for your information.