PipeFusion: 基于扩散变换器推理的片级流水线并行
PipeFusion: Patch-level Pipeline Parallelism for Diffusion Transformers Inference
AI总结:
PipeFusion通过片级流水线并行方法,提高扩散变换器推理的效率和性能,适用于大模型如Flux.1。
摘要:
本文提出了PipeFusion,一种创新的并行方法,旨在解决使用扩散变换器(DiTs)模型生成高分辨率图像时的高延迟问题。PipeFusion将图像划分为多个块,并将模型层分布在多个GPU上。它采用片级流水线并行策略,以高效地协调通信和计算。通过利用连续扩散步骤之间输入的高相似性,PipeFusion重用一步旧的特征图,为当前流水线步骤提供上下文。这种方法相比现有的DiTs推理并行方法,包括张量并行、序列并行和DistriFusion,显著降低了通信成本。通过在设备间分布参数,PipeFusion提高了内存效率,适合大型DiTs如Flux.1。实验结果表明,PipeFusion在8×L40 PCIe GPU上实现了Pixart、Stable-Diffusion 3和Flux.1模型的最先进性能。我们的源代码可在https://github.com/xdit-project/xDiT上获得。
英文摘要:
This paper presents PipeFusion, an innovative parallel methodology to tackle the high latency issues associated with generating high-resolution images using diffusion transformers (DiTs) models. PipeFusion partitions images into patches and the model layers across multiple GPUs. It employs a patch-level pipeline parallel strategy to orchestrate communication and computation efficiently. By capitalizing on the high similarity between inputs from successive diffusion steps, PipeFusion reuses one-step stale feature maps to provide context for the current pipeline step. This approach notably reduces communication costs compared to existing DiTs inference parallelism, including tensor parallel, sequence parallel and DistriFusion. PipeFusion enhances memory efficiency through parameter distribution across devices, ideal for large DiTs like Flux.1. Experimental results demonstrate that PipeFusion achieves state-of-the-art performance on 8$\times$L40 PCIe GPUs for Pixart, Stable-Diffusion 3, and Flux.1 models. Our source code is available at https://github.com/xdit-project/xDiT.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。