用平均速度替代瞬时速度,让流匹配推理更快更准
MeanCache: From Instantaneous to Average Velocity for Accelerating Flow Matching Inference
- 用缓存的雅可比-向量积计算区间平均速度
- 在三个模型上提速超4倍,生成质量更优
- 适合追求高效稳定生成的开发者和研究者
我们提出 MeanCache,一种无需训练的缓存框架,用于加速流匹配推理。现有缓存方法依赖瞬时速度信息(如特征缓存),在高加速比下易引发轨迹偏差和误差累积。MeanCache 提出平均速度视角:利用缓存的雅可比-向量积(JVP)从瞬时速度构建区间平均速度,有效缓解局部误差累积。为提升缓存时机与 JVP 重用稳定性,我们设计了轨迹稳定性调度策略,在预算约束下采用峰值抑制最短路径算法确定调度方案。在 FLUX.1、Qwen-Image 和 HunyuanVideo 上的实验表明,MeanCache 分别实现 4.12×、4.56× 和 3.59× 加速,且生成质量持续优于当前最优缓存基线。我们认为这一简单而有效的方法为流匹配推理提供了新视角,将推动商业级生成模型中以稳定性驱动的加速探索。
原文摘要 · Abstract (English)
We present MeanCache, a training-free caching framework for efficient Flow Matching inference. Existing caching methods reduce redundant computation but typically rely on instantaneous velocity information (e.g., feature caching), which often leads to severe trajectory deviations and error accumulation under high acceleration ratios. MeanCache introduces an average-velocity perspective: by leveraging cached Jacobian--vector products (JVP) to construct interval average velocities from instantaneous velocities, it effectively mitigates local error accumulation. To further improve cache timing and JVP reuse stability, we develop a trajectory-stability scheduling strategy as a practical tool, employing a Peak-Suppressed Shortest Path under budget constraints to determine the schedule. Experiments on FLUX.1, Qwen-Image, and HunyuanVideo demonstrate that MeanCache achieves 4.12X and 4.56X and 3.59X acceleration, respectively, while consistently outperforming state-of-the-art caching baselines in generation quality. We believe this simple yet effective approach provides a new perspective for Flow Matching inference and will inspire further exploration of stability-driven acceleration in commercial-scale generative models.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。