Coder Social home page Coder Social logo

nhnet's Introduction

DRNet

This code is a implement of the paper "NHNet: A Non-Local Hierarchical Network for Image Denoising".

Result for real image denoising:


image

Environment:

Please run this code in the terminal:

pip install -r requirements.txt

Datasets:

Trainsets

Testsets

  • For gray images

set12

bsd68

  • For color images

set5

McMaster

Kodak24

cbsd68

  • For real noise

Branchmark from SIDD(http://130.63.97.225/sidd/dataset.php)

Validation data from SIDD(http://130.63.97.225/sidd/dataset.php)

DND(https://noise.visinf.tu-darmstadt.de/)

Train

main_train_###.py

The file main_train_DRNet_###.py contains the best model in the paper:

  • For Gaussian denoising on gray images: main_train_NHNet.py
  • For Gaussian denoising on color images : main_train_NHNet_color.py
  • For real noise: main_train_NHNet_sidd.py

Other files, such as main_train_NHNet_no_bn.py, corresponds to the control model used in the ablation experiment.

Testing

main_test_###.py

For Gaussian noise, we provide pre-trained models of three noise level, 15, 25 and 50. Please ensure the test noise level is consistent with the model you select (you can select them in the test file). Names of the pre-trained models as follows:

---_gray15 ---_gray25 ---_gray50 ---_color15 ---_color25 ---_color50

For real noise, we provide the pre-trained model "real.pth". Test results can be produced by running file as follows:

---_sidd_valu.py for Validation data from SIDD

sidd_Submit.py for branchmark data from SIDD. The file generated by it should be submitted to http://130.63.97.225/sidd/dataset.php to receive the result report.

test_denoising_dnd.py for DND. The file generated by it also should be submitted.

Pre-trained model:

Link:https://pan.baidu.com/s/1ZjB-t4YuZkL0PAB8jkCDNA

code:xe88

Directory structure

  • model_zoo (there are some pretrained model in the papar)
  • options (Config files of the models)
  • models (network, train method definition)
  • model_zoo (pre-trained models)
  • testsets
  • trainsets
  • utils

If you meet this bug, please make sure that you are not running the code in Pycharm's test environment: E:\soft2\anaconda\envs\pytorchgpu37\python.exe E:\PyCharm2020.1\plugins\python\helpers\pycharm_jb_nosetest_runner.py --target test_DiehlAndCook2015.py::test Traceback (most recent call last): File "E:\PyCharm2020.1\plugins\python\helpers\pycharm_jb_nosetest_runner.py", line 4, in import nose ModuleNotFoundError: No module named 'nose'

nhnet's People

Contributors

jiahongz avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.