Guide image for -denoise

Hi @David_Tschumperle, I was wondering if it was possible to add a guide image as an input to denoise?


I do this quite often; of course, with much less sophistication. :blush:

Definitely, great idea.
As denoise is a native command, the guided version will be available only in next release 2.7.0 though.

1 Like

Thanks David

And I took the opportunity to parallelize the algorithm. Will be available in 2.7.0.


Thanks! I made a small donation to show my appreciation.

1 Like

I’ll try to release new binary packages for 2.7.0_pre this afternoon, so it will be easier to test!

@David_Tschumperle There’s a pull request on hold.


I have found a problem.

-denoise[0] [1],10,$strength,5,7,0,0

with low values of ‘strength’ artefacts appear.

Edit: This also occurs without a guide image

-denoise[0] 10,$strength,5,7,0,0
1 Like

This may be related to precision issues with the calculations, leading to slightly out-of-range (negative in your case) values that are converted to 255 afterwards.
Could you check with a cut 0,255 just after the call to denoise ?

(if this is what I think, there is still a bug, but at least, I should be able to fix this easily).

A small number of artefacts are solved with

-c 0,255

-replace_inf 0

Turns the majority black.

Ah, that is super interesting. So, there are some divisions by zero that have to be fixed too.
I have some time this morning to look at it.

I’ve done some changes, I’m building window binaries and will upload them asap.

Windows binaries for 2.7.0_pre have just been posted.
I’m interested by your feedback !

1 Like

Thanks, David, I would have replied sooner, but I have been rather distracted by using the improvements to denoise to update my denoise filter.

A guide image is great because previously I was applying processing before the denoising and then reversing the process after. One of the things I discovered I prefer is doing chroma denoising by desaturating a certain amount first and then undoing that afterwards, unfortunately you can’t desaturate it 100% otherwise it won’t work. A guide image solves all of those problems.

And now that denoise is parallelised that makes things easier than using apply_parallel etc.


1 Like