Repository navigation
Add support for DnCNN, FDnCNN, and DRUNet - #214
Merged
Merged
Conversation
joeyballentine
approved these changes
Mar 25, 2024
|
Interesting, so from the end user side of things. There should be no more hurdles than loading the arch with the provided classes and running |
Member
Author
Assuming that you loaded an RGB model, yes, this will just work. Well, it will after we release a new version :) |
|
Lovely, can't wait for 0.4 then :) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This implements some of the architectures for DPIR.
One thing to note is that FDnCNN and DRUNet actually take 2 input images, kinda. The idea is that a noise level map is concatenated as another channel to the input image. So a 4-channel input would be RGB + NoiseLevel map. The NL map just defines how much there is at this part of the image, In most cases, the NL map is a constant value, but it doesn't have to be. This NL map constant could also be user-controlled, but I set it to the default value DPIR uses. Both architectures are fairly accepting to "incorrect" NL values, so this shouldn't be an issue.
Lastly, DnCNN and FDnCNN are basically the same arch. The only difference is that DnCNN predicts the noise in an image and subtracts it from the image, while FDnCNN predicts the noise free image. This is why I implemented FDnCNN as a mode inside DnCNN.
I won't implement IRCNN from DPIR. It implements an interesting idea, but it does not perform well and will be a pain to implement. Closes #191