•  


GitHub - Saafke/EDSR_Tensorflow: TensorFlow implementation of 'Enhanced Deep Residual Networks for Single Image Super-Resolution'.
Skip to content

TensorFlow implementation of 'Enhanced Deep Residual Networks for Single Image Super-Resolution'.

License

Notifications You must be signed in to change notification settings

Saafke/EDSR_Tensorflow

Folders and files

Name Name
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

EDSR in Tensorflow

TensorFlow implementation of Enhanced Deep Residual Networks for Single Image Super-Resolution [1].

It was trained on the Div2K dataset - Train Data (HR images).

Google Summer of Code with OpenCV

This repository was made during the 2019 GSoC program for the organization OpenCV. The trained models (.pb files) can easily be used for inference in OpenCV with the 'dnn_superres' module . See the OpenCV documentation for how to do this.

Requirements

  • tensorflow
  • numpy
  • cv2

EDSR

This is the EDSR model, which has a different model for each scale. Architecture shown below. Go to branch 'mdsr' for the MDSR model.

Alt text

Running

Download Div2K dataset . If you want to use another dataset, you will have to calculate the mean of that dataset, and set the new mean in 'main.py'. Code for calculating the mean can be found in data_utils.py.

Train:

  • from scratch python main.py --train --fromscratch --scale <scale> --traindir /path-to-train-images/

  • resume/load previous python main.py --train --scale <scale> --traindir /path-to-train-images/

Test (compares edsr with bicubic with PSNR metric): python main.py --test --scale <scale> --image /path-to-image/

Upscale (with edsr): python main.py --upscale --scale <scale> --image /path-to-image/

Export to .pb python main.py --export --scale <scale>

Extra arguments (Nr of resblocks, filters, batch, lr etc.) python main.py --help

Example

(1) Original picture
(2) Input image
(3) Bicubic scaled (3x) image
(4) EDSR scaled (3x) image
Alt text Alt text Alt text Alt text

Notes

The .pb files in these repository are quantized. This is done purely to shrink the filesizes down from ~150MB to ~40MB, because GitHub does not allow uploads above 100MB. The performance loss due to quantization is minimal. (To quantize during exporting use $ --quant <1,2 or 3> (2 is recommended.))

References

[1] Bee Lim, Sanghyun Son, Heewon Kim, Seungjun Nah, and Kyoung Mu Lee, "Enhanced Deep Residual Networks for Single Image Super-Resolution," 2nd NTIRE: New Trends in Image Restoration and Enhancement workshop and challenge on image super-resolution in conjunction with CVPR 2017 . [ PDF ] [ arXiv ] [ Slide ]

About

TensorFlow implementation of 'Enhanced Deep Residual Networks for Single Image Super-Resolution'.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

- "漢字路" 한글한자자동변환 서비스는 교육부 고전문헌국역지원사업의 지원으로 구축되었습니다.
- "漢字路" 한글한자자동변환 서비스는 전통문화연구회 "울산대학교한국어처리연구실 옥철영(IT융합전공)교수팀"에서 개발한 한글한자자동변환기를 바탕하여 지속적으로 공동 연구 개발하고 있는 서비스입니다.
- 현재 고유명사(인명, 지명등)을 비롯한 여러 변환오류가 있으며 이를 해결하고자 많은 연구 개발을 진행하고자 하고 있습니다. 이를 인지하시고 다른 곳에서 인용시 한자 변환 결과를 한번 더 검토하시고 사용해 주시기 바랍니다.
- 변환오류 및 건의,문의사항은 juntong@juntong.or.kr로 메일로 보내주시면 감사하겠습니다. .
Copyright ⓒ 2020 By '전통문화연구회(傳統文化硏究會)' All Rights reserved.
 한국   대만   중국   일본