Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add fast NL means denoiser node #1890

Merged
merged 13 commits into from
Jun 30, 2023
Merged

Add fast NL means denoiser node #1890

merged 13 commits into from
Jun 30, 2023

Conversation

adegerard
Copy link
Contributor

@adegerard adegerard commented Jun 23, 2023

This PR adds a Non-local Means Denoising algorithm.

Note: the "Color strength" input is only used when the input image is RGB/RGBA: is it possible to hide this field when the connected image is a grayscale image?

chaiNNer-fast-nlmeans-2023-6-23_20-07

@adegerard adegerard marked this pull request as ready for review June 23, 2023 18:12
@joeyballentine
Copy link
Member

is it possible to hide this field when the connected image is a grayscale image?

Yes actually. You would use an "if_group" with a type condition that matches RGB/RGBA, similar to this:

if_group(Condition.type(0, 'PyTorchModel { arch: "CodeFormer" }'))(

@adegerard
Copy link
Contributor Author

Yes actually. You would use an "if_group" with a type condition that matches RGB/RGBA, similar to this:

OK. I'll modify my code.

@adegerard
Copy link
Contributor Author

Done.
chaiNNer-fast-nlmeans-2023-6-23_21-06

@RunDevelopment
Copy link
Member

Formatting on tests currently fail. To fix the formatting, run the command npm run lint-fix - after installing our dev dependencies of course (npm ci and pip install -r requirements.txt). The tests fail because you added a new test case (the .chn file) but didn't update the test snapshots. Run npm test -- -u to update them.

…_nlmeans.py

Co-authored-by: Michael Schmidt <msrd0000@gmail.com>
@adegerard
Copy link
Contributor Author

Formatting on tests currently fail. To fix the formatting, run the command npm run lint-fix - after installing our dev dependencies of course (npm ci and pip install -r requirements.txt). The tests fail because you added a new test case (the .chn file) but didn't update the test snapshots. Run npm test -- -u to update them.

I didn't know. I am a beginner. Would it be possible to document the different steps before creating a pull request ? Thanks.

@RunDevelopment
Copy link
Member

Would it be possible to document the different steps before creating a pull request ?

Good point. I'll add it to our contributing docs.

Copy link
Member

@RunDevelopment RunDevelopment left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @adegerard!

@joeyballentine joeyballentine merged commit 0641dc5 into chaiNNer-org:main Jun 30, 2023
13 checks passed
@adegerard adegerard deleted the fast_nlmeans branch June 30, 2023 16:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants