On Biased Compression for Distributed Learning

Aleksandr Beznosikov, Samuel Horváth, Peter Richtárik, Mher Safaryan

TL;DR

While biased gradient compressors like Top-$k$ sparsification consistently outperform unbiased methods in practical distributed training, they historically lacked rigorous theoretical foundations and can catastrophically diverge in multi-node setups. This paper introduces a unified theoretical framework classifying biased compressors, establishes the first linear convergence rates for distributed SGD using error feedback with general biased operators, and reveals mathematically and empirically why biased compression preserves significantly more gradient information.

What Problem Does This Paper Address?

In large-scale distributed machine learning, exchanging high-dimensional gradient vectors across workers creates severe communication bottlenecks. Communication compression addresses this by reducing message sizes before transmission.

Most existing theory has focused on unbiased compressors (e.g., Rand-$k$) because their mathematical analysis is simpler. In practice, however, practitioners prefer biased compressors (e.g., Top-$k$ sparsification or deterministic rounding), which empirically provide superior convergence. Before this work, theoretical understanding of biased operators was sparse:

  1. No unified classification of biased compression operators existed.
  2. It was unproven mathematically why and by how much biased methods outperform unbiased counterparts.
  3. In distributed settings ($n > 1$), naively applying biased compression causes gradient descent to diverge exponentially or freeze completely.

Methods

  • Three Operator Classes ($\mathbb{B}^1, \mathbb{B}^2, \mathbb{B}^3$): The authors formalize three parametric definitions of biased compressors. While functionally equivalent up to scaling, the contractive class $\mathbb{B}^3(\delta)$—where $\mathbb{E}[\|\mathcal{C}(x) - x\|_2^2] \le (1 - 1/\delta)\|x\|_2^2$—and inner-product class $\mathbb{B}^2(\gamma, \beta)$ provide tighter iteration complexity bounds than $\mathbb{B}^1(\alpha, \beta)$.
  • Compressed GD Analysis: For single-worker smooth, strongly convex objectives, the authors prove that compressed gradient descent converges linearly at rate $\mathcal{O}\left(\delta \frac{L}{\mu} \log \frac{1}{\epsilon}\right)$.
  • Distributed Error-Feedback SGD: To prevent multi-node divergence, the authors combine biased compression with an error-feedback (EF) memory mechanism (Algorithm 1). Local compression errors are tracked and reintroduced in subsequent steps, enabling provable ergodic convergence across three stepsize/weighting schedules.
  • New Compressors: They introduce several novel operators, including biased random sparsification, adaptive random sparsification, general biased rounding, and a hybrid combining Top-$k$ with exponential/natural dithering.

Datasets

  • Synthetic: Random quadratic problems generated with varying condition numbers ($\kappa \in \{10, 100, 1000\}$).
  • Tabular / Benchmarks: LIBSVM mushrooms (logistic regression), scikit-learn Boston housing, and Diabetes datasets (linear regression).
  • Vision: CIFAR-10 distributed across 4 nodes training ResNet-18, GoogLeNet, VGG-11, and VGG-19.
  • NLP Pre-training & Evaluation: Pre-training ALBERT-large (18M parameters) with the LAMB optimizer on a combined corpus of BookCorpus and English Wikipedia, evaluated across downstream GLUE benchmark tasks (CoLA, MNLI, MRPC, QNLI, QQP, RTE, SST-2, STS-B).

Key Insights and Ideas

  • Why Top-$k$ Beats Rand-$k$: Using order statistics, the authors show that when coordinate magnitudes are not identical, Top-$k$ extracts vastly more "gradient energy." For uniformly distributed coordinates, Top-$k$ has roughly $(1 - k/d)^2$ times lower variance than Rand-$k$. For standard exponential distributions, the expected energy retained by Top-$1$ grows as $\mathcal{O}(\log^2 d)$, compared to a constant $\mathcal{O}(1)$ for Rand-$1$.
  • The Peril of Naive Distributed Biased Compression: Without error feedback, coordinate disagreements cause the aggregate average $\frac{1}{n}\sum_{i=1}^n \mathcal{C}(\nabla f_i(x^k))$ to diverge exponentially (e.g., scaling iterates by $(1 + \frac{11\eta}{6})^k$) or get stuck indefinitely at $x^0 = 0$.
  • First Distributed Linear Convergence: Under over-parameterization ($D = 0$) and full local gradients ($C = 0$), distributed SGD with error feedback matches the single-node linear rate $\mathcal{O}\left(\delta \frac{L}{\mu} \log \frac{1}{\epsilon}\right)$.
  • Synergistic Composition: Combining Top-$k$ sparsification with natural dithering achieves the lowest contractive compression parameter $\delta \ge 1$ among tested compressors, drastically reducing bitrates with virtually zero degradation in convergence.

Key Results

  • Gradient Information Retention: On i.i.d. Gaussian gradients, Top-3 and Top-5 sparsifiers preserve $3\times$ to $40\times$ more energy in expectation than random sparsification, with the advantage expanding alongside vector dimension $d$. On real gradient distributions from logistic and quadratic regression, Top-5 retains $3\times$ to $5\times$ more energy.
  • Variance vs. Bitrate: Top-$k$ achieves an exponentially smaller normalized variance ($\approx 0.86^{b/d}$) compared to the linear decline ($1 - \frac{b/d}{32}$) of Rand-$k$ as the average bits per coordinate $b/d$ varies.
  • Large-Scale Transformer Training: When pre-training ALBERT-large, Power compression ($r=8$) paired with error feedback reduced the average communication round duration from $9.62 \pm 0.03$s (uncompressed baseline) and $4.05 \pm 0.05$s (natural compression) down to $1.04 \pm 0.04$s—roughly a $9\times$ speedup—while achieving competitive average downstream GLUE scores (e.g., 88.2 on QNLI vs. 87.9 baseline; 88.0 on SST-2 vs. 85.1 baseline).

Limitations and Future Work

  • Convexity Assumptions: The formal linear and sublinear rates are derived under $L$-smoothness and $\mu$-strong convexity assumptions. While deep neural network experiments validate practical performance, formal non-convex convergence proofs are not established in this work.
  • Exact Linear Convergence Restrictions: Exact linear convergence in the distributed setting requires zero gradient variance at the optimum ($D = 0$, over-parameterization) and exact worker gradients ($C = 0$). In stochastic, non-overparameterized settings, the method converges to a noise-dominated neighborhood or requires decaying stepsizes.

Summary updated

BibTeX
@article{beznosikov2023biased,
  author = {Aleksandr Beznosikov and Samuel Horváth and Peter Richtárik and Mher Safaryan},
  title = {{On Biased Compression for Distributed Learning}},
  journal = {J. Mach. Learn. Res.},
  year = {2023},
  url = {https://openreview.net/forum?id=EEpZ1WN3ZS},
}
Figure