Abstract
Diffusion Transformers (DiTs) have established a new state-of-the-art for high-quality video generation, yet their computational demands remain a significant barrier to real-time application. Sparse VideoGen2 (SVG2) is a training-free framework that accelerates video generation in DiTs by up to 2.30× while maintaining high visual fidelity. By introducing semantic-aware permutation, SVG2 clusters tokens based on their latent meaning rather than their spatial coordinates. This approach allows the model to group critical computations into dense blocks that align with modern GPU architectures, effectively bridging the gap between mathematical sparsity and hardware efficiency.
Introduction
Generating high-resolution video using Diffusion Transformers is a computationally intensive task. A standard five-second video can require nearly an hour of processing on high-end hardware, primarily due to the quadratic scaling of the attention mechanism. While it is well-understood that attention in these models is "sparse"—meaning only a subset of tokens significantly influences the final output—leveraging this sparsity for actual speedups has proven difficult.
Existing acceleration methods typically suffer from two primary flaws. First, they often group tokens based on physical proximity, which fails to account for semantic boundaries (e.g., adjacent pixels belonging to different objects). Second, sparse tokens are usually scattered across memory, requiring extensive "padding" to fit the dense block requirements of modern GPU tensor cores. This padding can waste up to 80% of theoretical computation savings. SVG2 addresses these challenges by reordering tokens to match the semantic structure of the video data.
Methodology
SVG2 is a training-free solution that can be integrated into existing large-scale models like HunyuanVideo or Wan 2.1. The framework relies on three core algorithmic innovations and a system-level co-design.
Semantic-Aware Permutation and Reordering
Rather than relying on spatial grids, SVG2 applies k-means clustering to the Query, Key, and Value activations. This process groups tokens by semantic similarity. Once clustered, the tokens are permuted (reordered) in memory so that similar tokens are contiguous. This "densification" allows the GPU to process important data blocks without the overhead of processing irrelevant, padded tokens.
Centroid-Based Top-p Selection
To determine which token clusters are essential for a given generation step, SVG2 estimates attention scores using cluster centers (centroids). It then employs a Top-p selection strategy, choosing clusters in descending order of importance until a cumulative probability threshold ($p$) is reached. This ensures that the most semantically relevant information is prioritized while maintaining a lean computational profile.
System-Algorithm Co-design
To minimize the overhead of the clustering process, SVG2 introduces a Centroid Cache. Recognizing that video frames do not change drastically between consecutive denoising steps, the system reuses cluster centers from previous steps, accelerating the k-means process by up to 76×. Furthermore, the authors developed custom GPU kernels designed to handle the dynamic block sizes generated by semantic clustering, achieving over 85% of theoretical hardware utilization.
Experimental Results
The researchers evaluated SVG2 using two leading video generation models: HunyuanVideo (13B parameters) and Wan 2.1 (14B parameters). Testing was conducted on the VBench and Penguin benchmarks for 720p Text-to-Video (T2V) and Image-to-Video (I2V) tasks.
- Speedup: SVG2 achieved an end-to-end speedup of 2.30× on HunyuanVideo and 1.89× on Wan 2.1 using a single NVIDIA H100 GPU.
- Quality: The method maintains high visual quality, reaching a Peak Signal-to-Noise Ratio (PSNR) of 30 for HunyuanVideo and 26 for Wan 2.1.
- Hardware Efficiency: Unlike previous sparse methods that struggle with hardware alignment, SVG2's custom kernels ensure that the mathematical sparsity translates directly into reduced wall-clock time.
Discussion and Limitations
The primary insight of SVG2 is that the latent space of a DiT inherently understands object semantics. By leveraging this understanding to organize data for the hardware, SVG2 reaches a new Pareto frontier for the quality-speed trade-off.
However, some limitations remain. The current implementation focuses on self-attention; the applicability of semantic-aware permutation to cross-attention (e.g., text-to-video alignment) remains an open question. Additionally, while the method is training-free, optimal performance requires tuning hyperparameters such as the number of clusters and the top-p threshold for different model architectures. At extreme levels of sparsity, some fine-grained details may still be lost, a common trade-off in all sparse attention frameworks.
Conclusion
SVG2 demonstrates that hardware-aware algorithmic design is essential for scaling video generation. By prioritizing semantic relevance and aligning data structures with GPU tensor cores, SVG2 provides a practical path toward more efficient, high-quality video synthesis without the need for costly model retraining.
Summary updated