Optimal Stepsize for Diffusion Sampling
Jianning Pei, Han Hu, Shuyang Gu
TL;DR
Diffusion sampling discretization creates a speed–fidelity trade-off that worsens with few steps. The paper introduces Optimal Stepsize Distillation (OSS), a dynamic-programming framework that distills a theoretically optimal stepsize schedule from a high-step teacher to a low-step student, minimizing global error under a fixed step budget $M$ and providing stability across architectures and solvers. OSS is architecture-agnostic, compatible with various direction strategies, and augmented by per-step amplitude calibration to mitigate low-step drift; it achieves up to $10\times$ acceleration with minimal loss of fidelity on GenEval benchmarks. This work offers a practical, plug-and-play pathway to deploy latency-efficient diffusion inference without re-training, by decoupling stepsize design from denoising directions and leveraging principled DP-based optimization.
Abstract
Diffusion models achieve remarkable generation quality but suffer from computational intensive sampling due to suboptimal step discretization. While existing works focus on optimizing denoising directions, we address the principled design of stepsize schedules. This paper proposes Optimal Stepsize Distillation, a dynamic programming framework that extracts theoretically optimal schedules by distilling knowledge from reference trajectories. By reformulating stepsize optimization as recursive error minimization, our method guarantees global discretization bounds through optimal substructure exploitation. Crucially, the distilled schedules demonstrate strong robustness across architectures, ODE solvers, and noise schedules. Experiments show 10x accelerated text-to-image generation while preserving 99.4% performance on GenEval. Our code is available at https://github.com/bebebe666/OptimalSteps.
