arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2504.09844cs.DCcs.AI
收藏

MegaScale-Data: 为多源大规模基础模型训练扩展数据加载器

MegaScale-Data: Scaling Dataloader for Multisource Large Foundation Model Training

The University of Hong Kong(香港大学)
Juntao Zhao, Qi Lu, Wei Jia, Borui Wan, Lei Zuo, Junda Feng, Jianyu Jiang, Yangrui Chen, Shuaishuai Cao, Jialing He, Kaihua Jiang, Yuanzhe Hu, Shibiao Nong, Yan… 展开作者

Juntao Zhao, Qi Lu, Wei Jia, Borui Wan, Lei Zuo, Junda Feng, Jianyu Jiang, Yangrui Chen, Shuaishuai Cao, Jialing He, Kaihua Jiang, Yuanzhe Hu, Shibiao Nong, Yanghua Peng, Haibin Lin, Chuan Wu

AI总结:

本文提出MegaScale-Data,通过解耦数据预处理、集中化数据平面和多级自动分片机制,解决多源大规模基础模型训练中的数据加载瓶颈,提升训练效率并降低内存消耗。

摘要:

现代大规模基础模型(LFM)训练框架采用数据并行方式,每个加载器处理不相交的训练数据子集。当准备来自多个不同源的数据用于LFM训练时,会出现两个根本性挑战。首先,由于注意力运算符的二次计算复杂性,数据并行秩上的非均匀样本分布导致数据加载器之间的工作负载不平衡,影响训练效率。其次,支持多样化的数据源需要每个数据集的文件访问状态在并行加载器中被冗余复制,消耗大量内存。这还阻碍了动态数据混合(如课程学习)并导致混合并行中的冗余访问/内存开销。我们提出了MegaScale-Data,一种用于多源LFM训练的工业级分布式数据加载架构,具有三个关键创新:(1)通过角色特定的演员(源加载器/数据构造器)进行解耦数据预处理,消除源和并行冗余数据访问,确保多源可扩展性。(2)集中化和声明式的数据平面用于加载时的多源编排,如长-短上下文、多模态和课程学习。(3)针对异构预处理成本的多级自动分片和扩展机制用于源加载器。我们还贡献了在部署和容错中的设计和运行经验。MegaScale-Data实现了:(1)4.5倍的端到端训练吞吐量提升,以及(2)13.5倍的CPU内存使用减少。

英文摘要:

Modern frameworks for training large foundation models (LFMs) employ dataloaders in a data-parallel manner, with each loader processing a disjoint subset of training data. When preparing data for LFM training that originates from multiple, distinct sources, two fundamental challenges arise. First, due to the quadratic computational complexity of the attention operator, the non-uniform sample distribution over data-parallel ranks leads to significant workload imbalance among dataloaders, degrading the training efficiency. Second, supporting diverse data sources requires per-dataset file access states that are redundantly replicated across parallel loaders, consuming excessive memory. This also hinders dynamic data mixing (e.g., curriculum learning) and causes redundant access/memory overhead in hybrid parallelism. We present MegaScale-Data, an industrial-grade distributed data loading architecture for multisource LFMs training, with three key innovations: (1) Disaggregated data preprocessing via role-specific actors (Source Loaders/Data Constructors) to eliminate source and parallelism redundant data access and ensure multisource scalability. (2) Centralized and declarative data plane for load-time multisource orchestration, such as long-short context, multimodality, and curriculum learning. (3) Multi-level auto-partitioning and scaling mechanism for source loaders under heterogeneous preprocessing costs. We also contribute our designs and operational experience in deployment and fault tolerance. MegaScale-Data achieves up to: (1) 4.5x end-to-end training throughput improvement, and (2) 13.5x reduction in CPU memory usage.

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

↑