TL;DR
SPADE is a training-free, algorithm-system co-designed sparse attention engine that significantly accelerates video generation in Video Diffusion Transformers (vDiTs). By dynamically selecting optimal 3D blocking schemes and pruning redundant attention tokens with minimal overhead, it achieves up to $3.44\times$ attention speedup and $1.80\times$ end-to-end acceleration while fully preserving video quality.
What Problem Does This Paper Address?
Video Diffusion Transformers (vDiTs)—such as Sora, Hunyuan-Video, and Wan 2.1—produce stunning, high-fidelity videos but suffer from massive computational bottlenecks. Because video data spans three dimensions (time, height, and width), the number of tokens explodes quadratically ($O(N^2)$) within the self-attention mechanism, making inference incredibly expensive and slow.
While sparse attention can theoretically reduce this redundancy, existing methods fall short in practice:
- Static methods use fixed attention windows that fail to adapt to dynamic video content.
- Semi-static methods offer limited adaptivity by choosing from a few predefined masks, which can hurt accuracy.
- Dynamic methods generate masks on the fly based on the input, but the computational overhead of creating these masks often erases any actual wall-clock speedups.
The authors introduce SPADE to solve this dilemma, delivering a high-sparsity, dynamic attention mechanism with negligible runtime overhead.
Methods
SPADE achieves its performance through a tight co-design of algorithmic abstractions and hardware-aware GPU execution kernels. The framework rests on three main pillars:
- vDiT Sparsity Scheme Representation (vDiT-SSR): A unified specification interface that bridges static, semi-static, and dynamic sparse attention. It allows users to define diverse 3D blocking candidates (spatial, temporal, or mixed) and formalizes dynamic mask generation using mathematical "Summarizer" and "Estimator" expressions.
- Runtime Scheme Generation: To select the best blocking pattern per attention head and timestep without heavy overhead, SPADE introduces an online metric called the Sum of Intra-block Cosine Similarities (SICS). SICS measures how tightly token embeddings cluster within a 3D block, allowing the engine to quickly pick the most representative structure.
- Head-wise Sparse Attention Executor: A highly optimized GPU execution engine. It fuses layout transformations, token summarization, and intra-block estimation into a single CUDA kernel to minimize global memory traffic. Furthermore, it groups attention heads with identical sparsity patterns to maximize hardware utilization and leverages NVIDIA Hopper architecture features (like Tensor Memory Accelerator and warp-group MMA) to accelerate block-sparse attention.
Datasets
The authors evaluated SPADE across several state-of-the-art open-source vDiT models:
- Hunyuan-Video-T2V (13B)
- Wan 2.1 (T2V/I2V-14B)
- Wan 2.2 (T2V/I2V-14B)
Testing included both Text-to-Video (T2V) and Image-to-Video (I2V) tasks at 720p resolution. Evaluation prompts and image-video pairs were drawn from the VBench-2.0 benchmark suite to measure perceptual quality, alongside standard fidelity metrics like SSIM, PSNR, and LPIPS.
Key Insights and Ideas
- Exploiting Spatio-Temporal Continuity: Video tokens possess strong continuity across frames and space. Capitalizing on this allows SPADE to partition tokens into 3D blocks that align with the underlying video structure rather than treating them as a generic 1D sequence.
- SICS as a Cheap Proxy: Instead of calculating expensive full attention matrices to find sparse masks, computing the cosine similarity within blocks (SICS) serves as an excellent proxy for block importance. SPADE reduces this calculation from an expensive $O(BS^2 \cdot d_{head})$ operation to a lightweight $O(BS \cdot d_{head})$ online pass.
- Separating Policy from Mechanism: By defining a clean abstraction layer (vDiT-SSR), the system can dynamically adjust the sparsity ratio based on the diffusion timestep or layer depth, exploiting the fact that early denoising steps require denser attention than later steps.
Key Results
- Superior Sparsity: SPADE achieves the highest sparsity among compared methods, safely pruning 82.32% to 85.21% of attention computation.
- Wall-Clock Speedups: Tested on an NVIDIA H800 GPU, SPADE accelerates the attention mechanism by $2.26\times$ to $3.44\times$, translating to an end-to-end model speedup of $1.32\times$ to $1.49\times$.
- SPADE-Turbo: A more aggressive variant pushes end-to-end speedups up to $1.80\times$ by introducing sparsity right from the very first denoising step.
- Quality Preservation: Despite the high sparsity, SPADE maintains or even slightly improves video quality metrics (VBench scores remain stable around 0.76–0.81, matching full dense attention).
Limitations and Future Work
While SPADE delivers impressive wall-clock speedups, its ultra-fast variant (SPADE-Turbo) introduces a controlled quality trade-off (lower PSNR/SSIM) because it skips the initial dense denoising phase typically required by diffusion models. The authors note that future work could explore more granular, automated policy functions to dynamically balance this quality-speed trade-off without manual tuning of step thresholds.
Summary updated