Skip to main content
QUICK REVIEW

[Paper Review] SWARM Parallelism: Training Large Models Can Be Surprisingly Communication-Efficient

Max Ryabinin, Tim Dettmers|arXiv (Cornell University)|Jan 27, 2023
Advanced Neural Network ApplicationsComputer Science6 citations
TL;DR

SWARM parallelism is a decentralized, fault-tolerant model-parallel training algorithm designed for unreliable, heterogeneous, and low-bandwidth environments. It uses stochastically wired, dynamically rebalanced pipelines to reduce communication overhead, enabling training of billion-parameter Transformer models on preemptible T4 GPUs with under 200 Mb/s network bandwidth, achieving high throughput and cost efficiency through the square-cube law and 8-bit quantization.

ABSTRACT

Many deep learning applications benefit from using large models with billions of parameters. Training these models is notoriously expensive due to the need for specialized HPC clusters. In this work, we consider alternative setups for training large models: using cheap "preemptible" instances or pooling existing resources from multiple regions. We analyze the performance of existing model-parallel algorithms in these conditions and find configurations where training larger models becomes less communication-intensive. Based on these findings, we propose SWARM parallelism, a model-parallel training algorithm designed for poorly connected, heterogeneous and unreliable devices. SWARM creates temporary randomized pipelines between nodes that are rebalanced in case of failure. We empirically validate our findings and compare SWARM parallelism with existing large-scale training approaches. Finally, we combine our insights with compression strategies to train a large Transformer language model with 1B shared parameters (approximately 13B before sharing) on preemptible T4 GPUs with less than 200Mb/s network.

Motivation & Objective

  • To enable large-scale model training in cost-efficient, unreliable environments such as preemptible cloud instances or pooled heterogeneous resources.
  • To address the limitations of existing model-parallel algorithms in handling device failures, network instability, and heterogeneous hardware.
  • To reduce communication overhead in distributed training by exploiting the square-cube law, where larger models can become less communication-intensive per parameter.
  • To develop a decentralized, fault-tolerant training framework capable of scaling to billion-parameter models on low-bandwidth, unreliable devices.

Proposed method

  • SWARM parallelism uses randomized, temporary pipelines between nodes to enable fault tolerance and dynamic load balancing.
  • It periodically rebalances pipeline stages to adapt to varying device performance and network latency.
  • The algorithm is decentralized, avoiding reliance on a central coordinator, and prioritizes stable, low-latency peers for communication.
  • It integrates 8-bit blockwise quantization to halve activation communication size without significant accuracy loss.
  • It applies compression-aware architectures (e.g., maxout, bottleneck) to further reduce bandwidth requirements.
  • It leverages the square-cube law, where increased model size leads to reduced relative communication cost due to faster-growing computation vs. communication.

Experimental results

Research questions

  • RQ1Can training larger models reduce relative communication overhead in pipeline-parallel settings, defying conventional intuition?
  • RQ2How can model-parallel training be made robust to device failures and network unreliability in decentralized, heterogeneous environments?
  • RQ3To what extent can communication bandwidth be reduced without sacrificing training throughput or model quality?
  • RQ4Can SWARM parallelism achieve high training efficiency on low-cost, preemptible GPUs with sub-200 Mb/s network links?
  • RQ5How does the combination of SWARM, compression, and the square-cube law enable cost-effective training of billion-parameter models?

Key findings

  • SWARM parallelism enables training a 1B-parameter shared-parameter Transformer model on preemptible T4 GPUs with less than 200 Mb/s network bandwidth.
  • The algorithm achieves training throughput comparable to standard synchronous data-parallel training, with convergence curves matching within random seed variation.
  • Using 8-bit quantization reduces activation communication by a factor of two with minimal accuracy degradation.
  • The total cost of training the ALBERT-Large model on 32 preemptible T4 GPUs was $497.80, 64% lower than on reliable V100s.
  • The square-cube law enables larger models to be trained with lower relative communication cost, making low-bandwidth setups viable.
  • Compression-aware architectures (e.g., maxout) further reduce bandwidth needs, especially at higher compression ratios, without degrading in- or out-of-distribution performance.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.