Manuscript Offprint

arXiv:2610.21129

Sparse Attention for Video Generation Acceleration via Growing Sparsity and Reduced Search

Yun Dai, Yuyun Chen, Jiarui Wen, Huiping Zhuang, Cen Chen, Ziqian Zeng

Abstract

Diffusion Transformers (DiTs) dominate video generation but suffer from high inference cost due to the quadratic complexity of self-attention. Sparse attention mitigates this by skipping unnecessary computation in the attention matrix, but existing methods apply a fixed sparsity ratio throughout denoising and struggle to accurately determine which computations to skip. To address these limitations, we analyze attention dynamics through attention entropy and mean attention distance, and find that attention becomes increasingly concentrated across denoising steps. We further observe that blocks selected early continue to capture a large fraction of the total attention weight at later steps. These findings suggest two acceleration opportunities: the sparsity ratio should grow as denoising progresses, and earlier search results can be reused to reduce the search space. Based on these findings, we propose Growing Sparsity and Reduced Search (GSRS), a training-free framework that retains more computation early and progressively reduces it later, while restricting subsequent searches to an early candidate set to reduce search overhead. GSRS adopts Top-p selection for adaptive sparsity control, supported by a precise evaluation scheme that computes exact attention weights within the FlashAttention computation at negligible overhead. Experiments on HunyuanVideo and Wan 2.1 validate that GSRS achieves 1.55×−2.21×1.55 \times -2.21 \times speedup while maintaining generation quality comparable to full attention.

1. Introduction

Diffusion Transformers (DiTs) [38] represent the dominant architecture in the field of video generation [5, 11, 16, 24], with models such as Sora [31], HunyuanVideo [20], and Wan [49] achieving state-of-the-art performance in high-resolution and long-duration synthesis. Despite their success, the 3D full attention [48] has emerged as the primary computational bottleneck within this framework [55]. The 3D full attention converts video and text tokens into a single unified token sequence and apply self-attention across them, which causes inference costs to rise sharply as video resolution and temporal length increase. For instance, generating a 125-frame 720p video using HunyuanVideo on a single NVIDIA A800 GPU requires processing more than 115K tokens and takes approximately 38 minutes, with self-attention operations accounting for roughly 80% of the total latency.

Recent studies have shown that attention computation in DiTs contains substantial redundancy [6, 44, 52, 68], with the majority of token interactions making a negligible contribution to the final output. Sparse attention methods [14, 61] exploit this redundancy by partitioning the attention matrix into fixed-size blocks and selecting a subset of blocks to compute. Existing sparse attention strategies generally fall into two categories. Static methods [21, 22, 30, 51, 65] restrict block interactions to fixed windows, and dynamic methods [19, 29, 39, 43, 56, 58, 67] identify critical blocks at runtime. Critical blocks are blocks that actually contribute to the final output. These approaches achieve notable speedups, yet they share two limitations. First, a fixed sparsity ratio or selection threshold may allocate computation inefficiently across denoising steps. Second, accurately and efficiently identifying critical blocks remains challenging. Static methods rely on predefined blocks that may misalign with the ground truth. Evaluating block importance on the fly is expensive for dynamic methods, which may reduce identification accuracy to improve evaluation efficiency.

A detailed analysis of how attention behavior changes during the denoising process can guide the design of a better sparse attention strategy. To characterize this change, we measure how concentrated each query's attention is via attention entropy [1] and how far each query attends to via mean attention distance [23]. Lower entropy indicates that attention is focused on fewer tokens, while shorter distance means attention is more localized on nearby tokens. We observe that both metrics generally decrease across denoising steps, meaning that attention focuses on fewer and closer tokens as denoising progresses. This observation suggests growing sparsity. Retaining more computation early and progres-

∗^{*}Corresponding author.

sively reducing it later can improve the quality-efficiency trade-off. Meanwhile, we find that a candidate set of blocks selected early in denoising continues to capture a large fraction of the total attention weight at later steps. This finding suggests reduced search. Subsequent searches can focus on the candidate set established at an early denoising step rather than repeatedly evaluating all blocks, reducing search overhead while maintaining high coverage of critical blocks.

Based on these insights, we propose Growing Sparsity and Reduced Search (GSRS), a training-free framework that translates the above findings into two concrete acceleration strategies. To realize growing sparsity, GSRS progressively lowers selection thresholds over denoising steps, retaining more computation early and allowing greater sparsity later. To realize reduced search, GSRS establishes a candidate set of blocks at an early denoising step and restricts subsequent searches to this set, avoiding repeated evaluation of all blocks. This helps reduce search overhead while maintaining high coverage of critical blocks. Both mechanisms rely on selecting critical blocks at each search step. GSRS adopts cumulative attention probability (Top-p) [17, 25, 72] to adaptively adjust the number of retained blocks based on the actual attention concentration, which requires precise measurement of block importance to correctly select critical blocks. To support reliable Top-p selection, we design a precise block importance evaluation scheme fused into the FlashAttention [9] computation at negligible overhead. Together, these strategies allocate computation according to the changing attention concentration and reduce the cost of identifying critical blocks, improving the quality-efficiency trade-off.

Our contributions are summarized as follows:

• We systematically analyze DiT attention using attention entropy, mean attention distance, and how much attention weight early-selected blocks retain at later denoising steps, providing empirical motivation for growing sparsity and reduced search.

• We propose GSRS, a training-free sparse attention framework that combines growing sparsity and reduced search. To support reliable Top-p selection in GSRS, we design a precise block importance evaluation scheme fused into FlashAttention at negligible overhead.

• Extensive experiments on HunyuanVideo and Wan2.1 demonstrate that GSRS achieves up to 2.21×2.21 \times speedup while maintaining generation quality comparable to full attention, and delivers a superior quality-efficiency trade-off compared to compared sparse attention methods.

References (67)