stable-diffusion-webui-forge icon indicating copy to clipboard operation
stable-diffusion-webui-forge copied to clipboard

adjust distilled cfg wont take effect if

Open WingeD123 opened this issue 1 year ago • 4 comments

seems it's related to 'Persistent cond cache' img1: first generate; img2: generated after adjust distilled cfg with SAME prompt; img3: generated after modify prompt(like add a comma); img4: generated after modify prompt BACK(like delete the comma added); all above fixed seed img1 & img2 should be different, but got same. img1 & img4 are different, so i believe distilled cfg is still working. guess when only distilled cfg changes, 'Persistent cond cache' is used.

WingeD123 avatar Aug 16 '24 18:08 WingeD123

Same to me. Every time you adjust the distilled cfg, you have to reload the model for the new distilled cfg to take effect (you can trigger this by using the Swap method twice). However, this does take some extra time.

IMTB682 avatar Aug 16 '24 18:08 IMTB682

Still the same. Not work

ptits avatar Aug 16 '24 23:08 ptits

As a temporary 'fix' you could disable Persistent cond cache in Settings->Optimizations, but this fully prevents cond caching so it's not ideal especially when using models with heavy text encoders.

For a better fix, I'll submit a PR. It's only a one line addition, so that a change to distilled CFG scale invalidates the cond cache. Though I'll add changes to step size for distilled CFG and CFG too, as I think 0.5 is too large a step with modern models. https://github.com/lllyasviel/stable-diffusion-webui-forge/pull/1240

DenOfEquity avatar Aug 17 '24 18:08 DenOfEquity

Should be fixed now, please check and close this issue if it is.

kerizane avatar Aug 18 '24 15:08 kerizane

works great

WingeD123 avatar Aug 20 '24 08:08 WingeD123