sigmas_tools_and_the_golden_scheduler icon indicating copy to clipboard operation
sigmas_tools_and_the_golden_scheduler copied to clipboard

Denoise setting

Open CaptailTyler opened this issue 11 months ago • 2 comments

How can I implement a denoise setting for this sampler? This will help with use in an inpainting workflow.

Thanks,

CaptailTyler avatar Jan 02 '25 05:01 CaptailTyler

Hello! What do you mean by "for this sampler" since this repository is about the denoising schedule?

Extraltodeus avatar Jan 10 '25 03:01 Extraltodeus

I am going to assume they mean the manual scheduler. For example if they wanted to do image to image etc.. Inpainting is effectively img2img, you are just controlling the amount of denoise to anything other than a full denoise.

If this is the case, I don't think this requires any code changes. This could be something to amend to the documentation for users who don't understand.

I'm sorry if i explain this poorly. I will try my best.

I did some testing and made some examples of this. The key is modifying the y progression in the cosine equation using two coefficients: ((1 - cos(pi*(1 - (((y * DENOISE_STRENGTH + (1-DENOISE_STRENGTH)) + 0.008)/(1 + 0.008))**0.5)))/2)*sigmax + ...

No Denoise (strength=0): ((1 - cos(pi*(1 - (((y * 0.0 + 1.0) + 0.008)/(1 + 0.008))**0.5)))/2)*sigmax + ...

Full Denoise (strength=1.0): ((1 - cos(pi*(1 - (((y * 1.0 + 0.0) + 0.008)/(1 + 0.008))**0.5)))/2)*sigmax + ...

Partial Denoise (strength=0.58): this would be like setting ksampler's denoise to 0.58 ((1 - cos(pi*(1 - (((y * 0.58 + 0.42) + 0.008)/(1 + 0.008))**0.5)))/2)*sigmax + ...

Taithrah avatar Aug 02 '25 04:08 Taithrah