arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 1910.02054cs.LGcs.DCstat.ML
收藏

ZeRO:训练三参数模型的记忆优化

ZeRO: Memory Optimizations Toward Training Trillion Parameter Models

Microsoft(微软)

Samyam Rajbhandari, Jeff Rasley, Olatunji Ruwase, Yuxiong He

摘要:

大型深度学习模型提供了显着的准确性增益,但训练数十亿到数万亿的参数是具有挑战性的。现有的解决方案,如数据和模型并行表现出基本的限制,以适应这些模型到有限的设备存储器,同时获得计算,通信和开发效率。我们开发了一种新的解决方案,零冗余优化器(ZeRO),以优化内存,大大提高训练速度,同时增加可以有效训练的模型大小。ZeRO消除了数据和模型并行训练中的内存冗余,同时保持低通信量和高计算粒度,使我们能够以持续的高效率与设备数量成比例地扩展模型大小。我们对内存需求和通信量的分析表明:ZeRO有潜力使用当今的硬件扩展到超过1 Trillion参数。我们实现并评估了ZeRO:它在400个GPU上以超线性加速比训练了超过100 B参数的大型模型,实现了15 Petaflops的吞吐量。这意味着模型大小增加了8倍,可实现的性能比最先进的技术提高了10倍。在可用性方面,ZeRO可以训练多达13 B参数的大型模型(例如,大于Megatron GPT 8.3 B和T5 11 B),而不需要科学家难以应用的模型并行。最后但并非最不重要的是,研究人员利用ZeRO的系统突破创建了世界上最大的语言模型(Turing-NLG,17 B参数),其精度破纪录。

英文摘要:

Large deep learning models offer significant accuracy gains, but training billions to trillions of parameters is challenging. Existing solutions such as data and model parallelisms exhibit fundamental limitations to fit these models into limited device memory, while obtaining computation, communication and development efficiency. We develop a novel solution, Zero Redundancy Optimizer (ZeRO), to optimize memory, vastly improving training speed while increasing the model size that can be efficiently trained. ZeRO eliminates memory redundancies in data- and model-parallel training while retaining low communication volume and high computational granularity, allowing us to scale the model size proportional to the number of devices with sustained high efficiency. Our analysis on memory requirements and communication volume demonstrates: ZeRO has the potential to scale beyond 1 Trillion parameters using today's hardware. We implement and evaluate ZeRO: it trains large models of over 100B parameter with super-linear speedup on 400 GPUs, achieving throughput of 15 Petaflops. This represents an 8x increase in model size and 10x increase in achievable performance over state-of-the-art. In terms of usability, ZeRO can train large models of up to 13B parameters (e.g., larger than Megatron GPT 8.3B and T5 11B) without requiring model parallelism which is harder for scientists to apply. Last but not the least, researchers have used the system breakthroughs of ZeRO to create the world's largest language model (Turing-NLG, 17B parameters) with record breaking accuracy.

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

↑