scraed / CharacteristicGuidanceWebUI

Provide large guidance scale correction for Stable Diffusion web UI (AUTOMATIC1111), implementing the paper "Characteristic Guidance: Non-linear Correction for Diffusion Model at Large Guidance Scale"
https://scraed.github.io/CharacteristicGuidance/
Apache License 2.0
78 stars 8 forks source link

Is it important to avoid unconverged steps #9

Closed Disguised-Giraffe closed 8 months ago

Disguised-Giraffe commented 8 months ago

Do I want to avoid steps that have greater iterations than the previous step or that are barely/not converged as much as possible for the best quality? Does it matter if the final image has convergence and I'm not worried about time or resource consumption? Or should I be using the Reuse Correction option when I see them?

scraed commented 8 months ago
  1. steps that have greater iterations than the previous step

This case is tricky. If it converges, I think it's OK. Increase the Regularization time range will mitigate this.

  1. barely/not converged if two or more steps are barley/not converged. Regularization should be increased to avoid it.

  2. Does it matter if the final image has convergence and I'm not worried about time or resource consumption.

I'm not sure what do you mean. If a step fails to converge, clasisifier free guidance will be adopted. This will cause some discontinuity. But if just one step fails to converge, it is OK.

My suggestion for adjusting the parameters is to achieve balance between regularization and convergence. In some cases, iteration convergence never occur without enough regularization, even if you don't care about the time and resource. I think the reason is the neural network is not smooth enough at that position.

I will try to eliminate the iteration in my next work to avoid the convergence issue and make the guidance faster.

  1. Or should I be using the Reuse Correction option when I see them?

I would recommend to adjust Regularization strength and time range to avoid discontinuity. I'm considering to remove/modify the Reuse Correction option since it is not very effective when previous step fails to converge.