通过流水线与模块解耦,加速视频生成扩散模型推理。
PipeDiT: Accelerating Diffusion Transformers in Video Generation with Task Pipelining and Model Decoupling
- 采用流水线算法并行计算潜在变量与通信,降低延迟。
- 分离扩散与VAE模块至不同显卡组,减少内存占用。
- 显卡组内注意力协同处理,进一步提升生成速度。
视频生成技术快速发展,基于扩散变换器(DiT)的模型表现卓越,但实际部署常受推理速度慢、内存消耗高的限制。本文提出名为PipeDiT的新流水线框架,包含三项创新:首先设计序列并行流水线算法(PipeSP),实现潜在变量生成与多GPU通信的流水线化,降低推理延迟;其次提出DeDiVAE,将扩散模块与变分自编码器(VAE)模块解耦至两组GPU,支持流水线执行以减少内存开销与延迟;第三,为更高效利用VAE组显卡资源,提出注意力协同处理(Aco)方法,进一步缩短整体生成时间。我们将PipeDiT集成至OpenSoraPlan与HunyuanVideo两个领先开源视频生成框架,在双8卡系统上进行大量实验。结果表明,在多种常见分辨率与步长配置下,相较OpenSoraPlan与HunyuanVideo,PipeDiT实现1.06x至4.02x的速度提升。
原文摘要 · Abstract (English)
Video generation has been advancing rapidly, and diffusion transformer (DiT) based models have demonstrated remark- able capabilities. However, their practical deployment is of- ten hindered by slow inference speeds and high memory con- sumption. In this paper, we propose a novel pipelining frame- work named PipeDiT to accelerate video generation, which is equipped with three main innovations. First, we design a pipelining algorithm (PipeSP) for sequence parallelism (SP) to enable the computation of latent generation and commu- nication among multiple GPUs to be pipelined, thus reduc- ing inference latency. Second, we propose DeDiVAE to de- couple the diffusion module and the variational autoencoder (VAE) module into two GPU groups, whose executions can also be pipelined to reduce memory consumption and infer- ence latency. Third, to better utilize the GPU resources in the VAE group, we propose an attention co-processing (Aco) method to further reduce the overall video generation latency. We integrate our PipeDiT into both OpenSoraPlan and Hun- yuanVideo, two state-of-the-art open-source video generation frameworks, and conduct extensive experiments on two 8- GPU systems. Experimental results show that, under many common resolution and timestep configurations, our PipeDiT achieves 1.06x to 4.02x speedups over OpenSoraPlan and HunyuanVideo.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。