Efficient Large-Scale Language Model Training on GPU Clusters Using Megatron-LM

By D. Narayanan, Mohammad Shoeybi, Jared Casper, Patrick LeGresley, M. Patwary, Vijay Anand Korthikanti, Dmitri Vainbrand, Prethvi Kashinkunti, Julie Bernauer, Bryan Catanzaro and 2 more. 2021

1,287 citations recorded by the source corpus.

Large language models have led to state-of-the-art accuracies across several tasks. However, training these models efficiently is challenging because: a) GPU memory capacity is limited, making it impossible to fit large models on even a multi-GPU server, and b) the number of compute operations required can result in unrealistically long training times. Consequently, new methods of model parallelism such as tensor and pipeline parallelism have been proposed. Unfortunately, naive usage of these methods leads to scaling issues at thousands of GPUs. In this paper, we show how tensor, pipeline, and data parallelism can be composed to scale to thousands of GPUs. We propose a novel interleaved pipelining schedule that can improve throughput by 10+% with memory footprint comparable to existing approaches. Our approach allows us to perform training iterations on a model with 1 trillion parameters at 502 petaFLOP/s on 3072 GPUs (per-GPU throughput of 52% of theoretical peak).

Subfields: Artificial Intelligence, Computer Vision and Pattern Recognition, Large Language Models, Efficiency & Compression

How researchers see this paper

The researchers whose trusted networks rank it highest, strongest advocate first. Every researcher gets a different order.

In Artificial Intelligence

  1. Luke S. Zettlemoyer
  2. Mohit Bansal
  3. Jianfeng Gao
  4. Percy Liang
  5. Graham Neubig
  6. Quoc V. Le
  7. Yejin Choi
  8. Noah A. Smith

In Computer Vision and Pattern Recognition

  1. Luc Van Gool
  2. Dacheng Tao
  3. Trevor Darrell
  4. Ming-Hsuan Yang
  5. Xiaogang Wang
  6. Jitendra Malik
  7. Andrew Zisserman
  8. Quoc V. Le

In Large Language Models

  1. Luke S. Zettlemoyer
  2. Furu Wei
  3. Jianfeng Gao
  4. Yi Tay
  5. Hinrich Schütze
  6. Yejin Choi
  7. Li Dong
  8. Percy Liang

In Efficiency & Compression

  1. Yuxiong He
  2. Alexander M. Rush
  3. Minjia Zhang
  4. Dan Alistarh
  5. Samyam Rajbhandari
  6. Joseph Dean
  7. Yi Tay
  8. Mohammad Shoeybi

Citations in the corpus