HyZhu39 / De2Net

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

De2Net

Python 3.7 pytorch 1.7.0 CUDA 10.1

overall_structure

Overview of our proposed De2Net . Two main components are embedded into the backbone architecture, i.e., the feature-level Wiener deconvolution layer and the decomposed kernel prediction network.

Dependencies and Installation

  1. Clone repo

    git clone https://github.com/HyZhu39/De2Net.git
  2. Install Dependencies

    cd De2Net
    pip install -r requirements.txt
  3. Install BasicSR

    Compile BasicSR without cuda extensions for DCN (Remember to modify the CUDA paths in make.sh and make sure that your GCC version: gcc >= 5)

    sh ./make.sh

Dataset Preparation

To grab datasets we used, Please see Dataset.md for details.

Our pretrained models are released on GoogleDrive or BaiduDrive.

Get Started

Test

We provide quick test code with the pretrained model.

  1. Download this repo, as well as the datasets and pretrained models from Google Drive or Baidu Drive, and unzip.

  2. Modify the paths to dataset and pretrained model in the following yaml files for configuration.

    ./options/test/ZTE_test.yml
    ./options/test/TOLED_test.yml
    ./options/test/POLED_test.yml
    ./options/test/ZTE_test_real_data.yml
  3. Run test code for synthetic data of ZTE dataset.

    python -u basicsr/test.py -opt "options/test/ZTE_test.yml" --launcher="none"
  4. Run test code for real data of ZTE dataset.

    python -u basicsr/test.py -opt "options/test/ZTE_test_real_data.yml" --launcher="none"
  5. Run test code for T-OLED dataset.

    python -u basicsr/test.py -opt "options/test/TOLED_test.yml" --launcher="none"
  6. Run test code for P-OLED dataset.

    python -u basicsr/test.py -opt "options/test/POLED_test.yml" --launcher="none"
  7. Check out the results in ./results.

Train

All logging files in the training process, e.g., log message, checkpoints, and snapshots, will be saved to ./experiments and ./tb_logger directory.

  1. Prepare datasets. Please refer to Dataset Preparation.

  2. Modify config files.

    ./options/train/ZTE_train.yml
    ./options/train/TOLED_train.yml
    ./options/train/POLED_train.yml
  3. Run training code for three different datasets.

    python -u basicsr/train.py -opt "options/train/ZTE_train.yml" --launcher="none"
    python -u basicsr/train.py -opt "options/train/TOLED_train.yml" --launcher="none"
    python -u basicsr/train.py -opt "options/train/POLED_train.yml" --launcher="none"

Results

ZTE_syn_result

Result on *synthetic* data of **ZTE** dataset.

ZTE_real_result Result on real data of ZTE dataset.

TOLED

Result on of T-OLED dataset.

POLED

Result on of P-OLED dataset.

About

License:MIT License


Languages

Language:Python 75.3%Language:Cuda 14.2%Language:C++ 10.6%Language:Shell 0.0%