/CUGAN

[ Official ] - Toward Interactive Modulation for Photo-Realistic Image Restoration. CVPRW 2021 NTIRE.

Primary LanguagePython

CUGAN

Toward Interactive Modulation for Photo-Realistic Image Restoration. (Paper Link)

By Haoming Cai*, Jingwen He*, Yu Qiao, and Chao Dong in CVPRW, NTIRE workshop 2021.

Two-dimension Modulation

Real-World Modulation

Dependencies and Installation

How to Test

  • Prepare the test dataset

    1. Download LIVE1 dataset and CBSD68 dataset from Google Drive
    2. Generate LQ images with different combinations of degradations using matlab codes/data_scripts/generate_2D_val.m.
  • Download the pretrained model

    1. Download pretrained CUGAN from Google Drive
    2. Modify the pretrain_model_G in configuration file options/test/xxxxxx.yml.
  • Test CUGAN with range of restoration strength

    1. Modify the configuration file options/test/modulation_CUGAN.yml. ❗️Importantly, cond_init, range_mode, range_stride are crucial in this testing mode.
    2. Run command:
     cd codes
     python test-cugan_range-cond.py -opt options/test/modulation_CUGAN.yml
  • Test CUGAN with specific restoration strength

    1. Modify the configuration file options/test/test_CUGAN.yml. ❗️Importantly, cond is crucial in this testing mode.
    2. Run command:
     cd codes
     python test-cugan_specific-cond.py -opt options/test/test_CUGAN.yml

How to Train

  • Cooming Soon

Acknowledgement