Abstract
Diffusion models have revolutionized image and video generation but suffer from high computational costs. Caching previous computations is a common acceleration strategy, yet it typically introduces feature shift and step amplification errors that degrade visual quality. We introduce ERTACache, a training-free framework that achieves a 2x speedup across state-of-the-art models like Wan2.1 and Flux-dev 1.0 while maintaining or improving visual fidelity. ERTACache utilizes offline policy calibration, dynamic timestep adjustment, and explicit error rectification to ensure the generation process remains on the intended trajectory.
Introduction
The core bottleneck in modern diffusion models, such as Stable Diffusion and Sora, is the requirement for multiple denoising steps, each involving a full pass through a massive Transformer (DiT). While caching methods like TeaCache attempt to skip redundant computations, they often introduce drift that results in blurry or incoherent outputs. ERTACache addresses these challenges by mathematically modeling and correcting caching errors, providing a robust, training-free solution for efficient inference.
Methodology
ERTACache addresses caching errors through three integrated components: offline policy calibration, trajectory-aware timestep adjustment, and explicit error rectification.
Offline Policy Calibration and Timestep Adjustment
The researchers observed that caching error patterns are remarkably stable across different prompts. By utilizing a small calibration set, ERTACache pre-calculates an optimal schedule for step skipping. This offline approach removes the computational overhead of real-time decision-making. Furthermore, when steps are skipped, the generation's "velocity" shifts. ERTACache dynamically adjusts the integration interval ($\Delta t$) to compensate for this drift, ensuring the solver's path remains aligned with the ground-truth trajectory.
Explicit Error Rectification
To mitigate feature shift, ERTACache employs a lightweight linear model to predict the additive error introduced by the cache. Using a first-order Taylor approximation, the framework analytically subtracts the expected error from the cached feature before it is utilized in the next step. This "rectification" ensures that the model's internal representations remain accurate even when skipping full computations.
Evaluation and Results
ERTACache was evaluated on high-performance models including Open-Sora 1.2, CogVideoX, Wan2.1, and Flux-dev 1.0 using benchmarks such as VBench and MS COCO.
- Acceleration: The framework consistently delivers a 2x speedup. For the Wan2.1 model (81 frames, 480p), inference latency was reduced from 199 seconds to 91.7 seconds.
- Visual Quality: ERTACache outperforms existing methods like TeaCache and PAB in visual quality metrics. On CogVideoX, it achieved a PSNR of 32.77, significantly higher than TeaCache's 20.97 at comparable acceleration levels.
- Efficiency: The additional computations for error rectification and timestep adjustment account for less than 0.5% of the total cost, making it highly practical for deployment.
Conclusion
ERTACache demonstrates that principled mathematical corrections can overcome the quality-speed trade-off in diffusion caching. By treating caching as a predictable error-correction problem, it enables significant speedups without the typical loss in visual quality. This approach provides a robust, plug-and-play solution for the next generation of efficient generative models.
Summary updated