Skip to content

krulllab/DirectDenoiser

Repository files navigation

DirectDenoiser

Code for Direct Unsupervised Denoising
1Benjamin Salmon and 2Alexander Krull
1, 2University of Birmingham
1[email protected], 2[email protected]
This project includes code from the Hierarchical DivNoising project, which is licensed under the MIT License - HDN project.

Unsupervised deep learning-based denoisers like Hierarchical DivNoising are trained to denoise images without examples of clean, noise-free images. They achieve excellent results, but are limited in application by prolonged inference times. This stems from the fact that unsupervised denoisers do not learn a direct mapping from noisy to clean, but instead learn to produce random samples from a posterior distribution over the clean images that could underlie a given noisy image. Practitioners are often interested in the mean of this distribution, which is typically estimated by averaging 100 to 1000 random samples, incurring prohibitively computation times.
In this project, we instead train an additional network to estimate this mean directly - the Direct Denoiser. This increases training time by around 1.25x (using our hardware) but reduces inference time by over 2000x by estimating the mean of the posterior distribution in a single pass. This turns hours of inference time into seconds and days into minutes.

BibTeX

@inproceedings{salmon2023direct,
  title={Direct Unsupervised Denoising},
  author={Salmon, Benjamin and Krull, Alexander},
  booktitle={Proceedings of the IEEE/CVF International Conference on Computer Vision},
  pages={3838--3845},
  year={2023}
}

Dependencies

We recommend installing the dependencies in a conda environment. If you haven't already, install miniconda on your system by following this link.
Once conda is installed, create and activate an environment by entering these lines into a command line interface:

  1. conda create --name directdenoiser
  2. conda activate directdenoiser

Next, install PyTorch and torchvision for your system by following this link.
After that, you're ready to install the dependencies for this repository:
pip install lightning jupyterlab matplotlib tifffile scikit-learn tensorboard

Example notebooks

This repository contains 3 notebooks that will first download then denoise the C. Majalis dataset, 1-train_noise_model.ipynb, 2-train_denoisers.ipynb and 3-evaluation.ipynb.

About

Direct Unsupervised Denoising

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published