Search papers, labs, and topics across Lattice.
This paper provides an in-depth analysis of classifier-free guidance (CFG) in diffusion models, revealing that the conventional product-distribution heuristic fails to accurately capture the distributions generated by CFG's deterministic dynamics. By employing probability flow ODEs, the authors derive exact analytic path-integral representations that highlight how CFG modifies the initial distribution through an exponential correction influenced by time-dependent guidance. The introduction of Distribution-Guided CFG (DG-CFG) demonstrates significant improvements in generation quality and diversity, especially under conditions where strong guidance typically leads to saturation and degradation in image quality.
DG-CFG not only enhances image generation quality but also reduces sampling costs by achieving target metrics with fewer steps, challenging the conventional wisdom of fixed guidance schedules.
Classifier-free guidance (CFG) is the default mechanism for conditional generation in diffusion models, but the distribution sampled by its deterministic guided dynamics is not captured by the usual product-distribution heuristic $p_0^\omega q_0^{1-\omega}$. We analyze CFG through the probability flow ODE and derive exact analytic path-integral representations of the induced distributions for both constant and time-dependent guidance. The resulting formulas show that CFG modifies $p_{t_0}$ by an exponential path-integral correction, and that a time-dependent schedule enters this correction through the weight $\omega(t)-1$. This characterization explains how score discrepancies accumulate along sampling trajectories and motivates Distribution-Guided CFG (DG-CFG), a schedule that balances timestep contributions while accounting for signal strength and low-noise score-error amplification. A toy model with analytic scores closely verifies the predicted distributions. On Stable Diffusion~1.5, DG-CFG improves generation and yields a stronger diversity--fidelity trade-off across guidance strengths, with especially clear gains when strong guidance causes saturation and quality degradation in constant and heuristic schedules. Across NFE budgets, DG-CFG reaches fixed image-quality targets with fewer sampling steps, reducing the sampling cost needed to achieve target metrics.