arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2603.07685cs.DCcs.CLcs.LG
收藏

基于Megatron核心的混合专家模型可扩展训练

Scalable Training of Mixture-of-Experts Models with Megatron Core

NVIDIA
Zijie Yan, Hongxiao Bai, Xin Yao, Dennis Liu, Tong Liu, Hongbin Liu, Pingtian Li, Evan Wu, Shiqing Fan, Li Tao, Robin Zhang, Yuzhong Wang, Shifang Xu, Jack Chan… 展开作者

Zijie Yan, Hongxiao Bai, Xin Yao, Dennis Liu, Tong Liu, Hongbin Liu, Pingtian Li, Evan Wu, Shiqing Fan, Li Tao, Robin Zhang, Yuzhong Wang, Shifang Xu, Jack Chang, Xuwen Chen, Kunlun Li, Yan Bai, Gao Deng, Nan Zheng, Vijay Anand Korthikanti, Abhinav Khattar, Ethan He, Soham Govande, Sangkug Lym, Zhongbo Zhu, Qi Zhang, Haochen Yuan, Xiaowei Ren, Deyu Fu, Tailai Ma, Shunkang Zhang, Jiang Shao, Ray Wang, Vasudevan Rengasamy, Rachit Garg, Santosh Bhavani, Xipeng Li, Chandler Zhou, David Wu, Yingcan Wei, Ashwath Aithal, Michael Andersch, Mohammad Shoeybi, Jiajie Yao, June Yang

AI总结:

基于Megatron核心,提出集成优化方案以提升混合专家模型的可扩展性与性能,支持大规模参数训练。

摘要:

在混合专家(MoE)模型训练中,扩展性带来了密集模型中不存在的系统挑战。由于每个token只激活专家子集,这种稀疏性使总参数数量能够比每token计算速度更快增长,从而在内存、通信和计算之间产生耦合约束。优化一个维度往往会使压力转移到另一个维度,需要在全系统栈上进行协同设计。我们通过涵盖内存(细粒度重计算、卸载等)、通信(优化调度器、重叠等)和计算(分组GEMM、融合、CUDA图等)的集成优化来解决这些挑战。该框架还提供了平行折叠以实现灵活的多维并行,支持低精度训练(FP8和NVFP4),并实现了高效的长上下文训练。在NVIDIA GB300和GB200上,它实现了DeepSeek-V3-685B的1233/1048 TFLOPS/GPU和Qwen3-235B的974/919 TFLOPS/GPU。作为高性能、可扩展且生产就绪的开源解决方案,它已被用于学术界和工业界,用于在多达数千个GPU的集群上训练从十亿到万亿参数的MoE模型。本报告解释了这些技术的工作原理、权衡及其在系统层面的交互,为使用Megatron Core扩展MoE模型提供实用指导。

英文摘要:

Scaling Mixture-of-Experts (MoE) training introduces systems challenges absent in dense models. Because each token activates only a subset of experts, this sparsity allows total parameters to grow much faster than per-token computation, creating coupled constraints across memory, communication, and computation. Optimizing one dimension often shifts pressure to another, demanding co-design across the full system stack. We address these challenges for MoE training through integrated optimizations spanning memory (fine-grained recomputation, offloading, etc.), communication (optimized dispatchers, overlapping, etc.), and computation (Grouped GEMM, fusions, CUDA Graphs, etc.). The framework also provides Parallel Folding for flexible multi-dimensional parallelism, low-precision training support for FP8 and NVFP4, and efficient long-context training. On NVIDIA GB300 and GB200, it achieves 1,233/1,048 TFLOPS/GPU for DeepSeek-V3-685B and 974/919 TFLOPS/GPU for Qwen3-235B. As a performant, scalable, and production-ready open-source solution, it has been used across academia and industry for training MoE models ranging from billions to trillions of parameters on clusters scaling up to thousands of GPUs. This report explains how these techniques work, their trade-offs, and their interactions at the systems level, providing practical guidance for scaling MoE models with Megatron Core.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑