MC-Sparse: Deconstructing and Closing the Dense-Sparse Attention Gap in Diffusion Transformers

AK's Picks GenAI Diffusion ML TAVR Transformer
2026年10月05日
稀疏注意力是降低扩散型Transformer模型在长序列生成任务(例如视频生成和高分辨率3D资产生成)中推理延迟的主要手段。然而,现有稀疏注意力方法在高稀疏度下往往导致生成质量与保真度显著下降。通过受控的“理想模型”对比实验,我们定位出造成该退化的三大根源:由token分组所施加的结构约束、交互关系选择不准确,以及因丢弃token而损失的注意力贡献。基于上述分析,我们提出了“元缓存稀疏注意力”(Meta-Cached Sparse Attention,简称MC-Sparse)——一种无需额外训练的通用框架:该框架以细粒度方式独立选取每个键值(KV)token,同时将语义相近的查询(query)组织为对齐GPU内存块(tile)的分组,从而兼顾计算精度与硬件执行效率。MC-Sparse在运行时缓存三类元数据:查询分组信息、基于精确注意力概率选定的KV索引,以及稠密注意力输出与稀疏注意力输出之间的残差;这些元数据可在后续各去噪步中重复复用。在视频生成与3D资产生成的多种模型上,MC-Sparse相较现有稀疏注意力基线方法,在更贴近稠密注意力输出保真度的同时,实现了更大的去噪加速比,且未引入任何肉眼可辨的质量下降。相较于稠密注意力基准,MC-Sparse在Minimax-H3-Base视频模型上实现1.80倍的去噪加速,在3D资产生成任务上实现2.32倍加速,两种场景下均仅带来可忽略不计的质量损失。
Sparse attention is a primary approach to reducing the latency of diffusion transformers in long-sequence generation tasks, such as video and high-resolution 3D asset generation. However, existing methods can degrade generation quality and fidelity at high sparsity levels. Through controlled oracle comparisons, we trace this degradation to three sources: constraints imposed by token grouping, inaccurate interaction selection, and the attention contributions lost when tokens are discarded. Guided by this analysis, we propose Meta-Cached Sparse Attention (MC-Sparse), a training-free framework that selects individual key-value (KV) tokens while organizing similar queries into tile-aligned groups for efficient GPU execution. MC-Sparse caches metadata comprising query groups, KV indices selected using exact attention probabilities, and residuals between dense and sparse attention outputs, and reuses them across subsequent denoising steps. Across video and 3D generation models, MC-Sparse achieves higher fidelity to dense-attention outputs and larger denoising speedups than existing sparse-attention baselines, without visible quality degradation. Relative to dense attention, it delivers a $1.80\times$ denoising speedup on Minimax-H3-Base and a $2.32\times$ speedup on 3D asset generation, both with negligible quality loss.
许愿