SDP4Bit: Toward 4-bit Communication Quantization in Sharded Data Parallelism for LLM Training

Jinda Jia, Cong Xie, Hanlin Lu, Daoce Wang, Hao Feng +6 more
10/20/2024
cs.LGcs.DC

No official code found. Best implementation: ByteDance-Seed/SDP4Bit (44 stars, Apache-2.0, last commit 2024-12-11). 1 more below.

Abstract

Recent years have witnessed a clear trend towards language models with an ever-increasing number of parameters, as well as the growing training overhead and memory usage. Distributed training, particularly through Sharded Data Parallelism (ShardedDP) which partitions optimizer states among workers, has emerged as a crucial technique to mitigate training time and memory usage. Yet, a major challenge in the scalability of ShardedDP is the intensive communication of weights and gradients. While compression techniques can alleviate this issue, they often result in worse accuracy. Driven by this limitation, we propose SDP4Bit (Toward 4Bit Communication Quantization in Sharded Data Parallelism for LLM Training), which effectively reduces the communication of weights and gradients to nearly 4 bits via two novel techniques: quantization on weight differences, and two-level gradient smooth quantization. Furthermore, SDP4Bit presents an algorithm-system co-design with runtime optimization to minimize the computation overhead of compression. In addition to the theoretical guarantees of convergence, we empirically evaluate the accuracy of SDP4Bit on the pre-training of GPT models with up to 6.7 billion parameters, and the results demonstrate a negligible impact on training loss. Furthermore, speed experiments show that SDP4Bit achieves up to 4.08$\times$ speedup in end-to-end throughput on a scale of 128 GPUs.

View on arXivView PDF

Code Implementations(2)

Apache-2.0

official implementation of paper SDP4Bit: Toward 4-bit Communication Quantization in Sharded Data Parallelism for LLM Training

448C, C++Nov 21, 20241 years agoApache-2.0
research
sg564/SDP4BitCommunity61%
Apache-2.0

This repository contains the code for our paper "SDP4Bit: Toward 4-bit Communication Quantization in Sharded Data Parallelism for LLM Training"

00C, C++Nov 27, 20241 years agoApache-2.0

Cite this paper

@article{jia2024sdpbit,
  title  = {SDP4Bit: Toward 4-bit Communication Quantization in Sharded Data Parallelism for LLM Training},
  author = {Jinda Jia and Cong Xie and Hanlin Lu and Daoce Wang and Hao Feng and Chengming Zhang and Baixi Sun and Haibin Lin and Zhi Zhang and Xin Liu and Dingwen Tao},
  year   = {2024},
  eprint = {2410.15526},
  archivePrefix = {arXiv},
  doi    = {10.48550/arXiv.2410.15526},
  url    = {http://arxiv.org/abs/2410.15526v2},
  journal = {NEURIPS 2024 2024}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2410.15526.svg)](https://codeofpaper.com/paper/2410.15526)

Discussion