Denoising strength determines how much noise is added to an image before the sampling steps. It is a common setting in image-to-image applications in Stable Diffusion.
The value of denoising strength ranges from 0 to 1. 0 means no noise is added to the input image. 1 means the input image is completely replaced with noise.
You can understand denoising strength as the balance between preserving the original image and creating a completely new image.
The higher the denoising strength, the more the image will change.
Table of Contents
Denoising strength in AUTOMATIC1111
In AUTOMATIC1111, you can set the denoising strength on the img2img page. It controls how image the input image will change.
Denoising strength in image-to-image
You can use Image-to-image to generate a similar image.
In AUTOMATIC1111, go to img2img > Generation > img2img.
Upload an image to the image canvas.
Click the interrogate CLIP button (The paper clip icon) under the Generate button. This function uses a CLIP model to guess the prompt of your image.
A prompt should be populated.
Click Generate to create an image.
You can adjust the amount of variation by changing the denoising strength. A higher value changes the image more.
0 – No change.
0.2 – Slight change.
0.6 – Large change.
1.0 – Very large change.
Denoising strength in inpainting
Inpainting regenerates part of the image.
The effect of denoising strength in inpainting is similar to image-to-image: A higher value changes the image more.
But there are some nuisances in its usage.
Suppose you want to regenerate the face of the previous image. You upload the image to img2img > Generation > Inpaint.
Use the Clip Interrogator to guess the prompt.
Below are the effects of changing the denoising strength.
You should not set the denoising strength too high in inpainting. Otherwise, the generation will be incoherent to the rest of the image.
There are ways to use a high denoising strength in inpainting:
- Use an inpainting checkpoint model.
- Use ControlNet.
See the inpainting tutorial for details.
Denoising strength in ComfyUI
The effects of changing the denoising strength in ComfyUI are the same as in AUTOMATIC1111. You can change the denoising strength in the KSampler node.
Alternative to denoising strength
Tuning the denoising strength in image-to-image is not the only way to generate an image variation.
You can also use the IP-adapter (Image Prompt Adapter) in Stable Diffusion to generate a similar image. IP-adapter is a small add-on to a Stable Diffusion model. It can be used to generate an image variation, copying a face, among other things.