Guidance Breaks the Fitted Operator: A Terminal-Fitted Repair for Classifier-Free Guidance
Summary
Classifier-free guidance (CFG), a standard method for strengthening class-conditioning in diffusion and flow-matching samplers, suffers from oversaturation and destabilization at large guidance, often necessitating more steps or limited-interval schedules. An analysis reveals that CFG re-stiffens the discriminative subspace to an anomalous exponent 1+w, causing the deterministic DDIM step to become unfitted and its guided residual to diverge as sigma_min approaches zero. This leads to a "guided clock barrier" and identifies one-step oversaturation as a solver artifact. A proposed repair, requiring one coefficient and zero extra NFE, replaces CFG's w(r-1) with r^(1+w)-r on the guidance direction. This modification eliminates the sigma_min-divergent blow-up and achieves first-order accuracy. Tested on CIFAR-10 checkpoints and Stable Diffusion 1.5 DDIM, the repair stabilizes high-guidance scenarios, yielding 9/9 point-FID wins over CFG and preserving classifier-proxy target accuracy, though it is not a universal image-quality improvement.
Key takeaway
For Machine Learning Engineers optimizing diffusion models with classifier-free guidance, you should consider implementing the proposed one-coefficient repair. This modification directly addresses the numerical instability causing oversaturation at high guidance values, potentially improving stability and FID scores without extra computational cost. While not a universal image quality solution, it offers significant gains in specific high-guidance scenarios, particularly with models like Stable Diffusion 1.5. Evaluate its impact on your specific checkpoints.
Key insights
Classifier-free guidance fails at high values due to a numerical instability, repairable by a simple coefficient adjustment.
Principles
- Guidance re-stiffens discriminative subspace.
- DDIM becomes unfitted at high guidance.
- Oversaturation is a solver artifact.
Method
Replace CFG's w(r-1) with r^(1+w)-r on the guidance direction to remove sigma_min-divergent blow-up and achieve first-order accuracy.
In practice
- Apply the repair for high-guidance stability.
- Use on CIFAR-10 and Stable Diffusion 1.5.
- Expect FID wins, not universal quality.
Topics
- Classifier-Free Guidance
- Diffusion Models
- Flow Matching Samplers
- DDIM
- Numerical Stability
- Image Generation
- Stable Diffusion 1.5
Best for: AI Engineer, Computer Vision Engineer, AI Scientist, Machine Learning Engineer, Research Scientist
Related on AIssential
See Counsel's argued verdicts on the open AI decisions leaders are weighing →
Editorial summary, takeaway, and curation by AIssential. Original article published by Takara TLDR - Daily AI Papers.