Consensus Control for Decentralized Deep Learning

Lingjing Kong, Tao Lin, Anastasia Koloskova, Martin Jaggi, Sebastian U. Stich

Abstract

Decentralized deep learning often lags behind centralized training in terms of model quality. This research identifies consensus distance—the average difference between models across different nodes—as the "missing link" that explains this performance gap. By strategically controlling this distance, especially during a critical initial training phase, decentralized models can match or even outperform their centralized counterparts.

Introduction

In large-scale deep learning, centralized training (e.g., All-Reduce) is the standard. It ensures every worker node synchronizes its gradients to maintain an identical model. While this produces high-quality models, the communication overhead becomes a massive bottleneck as clusters grow.

Decentralized SGD (D-SGD) offers a faster alternative by allowing nodes to communicate only with immediate neighbors via gossip averaging. However, D-SGD often suffers from a "generalization gap," where the final model accuracy is lower than centralized baselines. This paper investigates the root cause of this gap and proposes a method to bridge it without sacrificing the speed benefits of decentralization.

The Role of Consensus Distance

The authors introduce Consensus Distance ($\Xi_t^2$) as the primary metric for understanding decentralized performance. It measures how much individual models on different nodes have drifted apart from the global average.

Evolution of the consensus distance $\Xi_t$ over training epochs, showing distinct phases corresponding to learning rate decays.

Key Methodological Contributions

  • Critical Consensus Distance (CCD): The authors prove theoretically that if consensus distance remains below a certain "critical" threshold, decentralized training converges as fast as centralized training.
  • Consensus Control: Instead of fixed communication, the authors propose adaptively increasing gossip steps to keep the consensus distance below the CCD.
  • Phase-wise Investigation: Training is divided into stages based on learning rate decays to isolate when decentralization impacts the model most significantly.
  • Efficient Estimator ($\Theta_t^2$): A low-overhead method for nodes to estimate global consensus distance using only local information and a single scalar average.

Experimental Results

The researchers evaluated their approach on standard benchmarks including CIFAR-10 (ResNet-20), ImageNet-32, and the Multi30k dataset for Neural Machine Translation.

Comparison of training loss, training accuracy, and test accuracy across centralized (All-Reduce) and various decentralized configurations.

Key Insights

  • The "Initial Phase" is Decisive: The first phase of training is the most critical. If consensus is poor early on, the model's trajectory is permanently damaged; the generalization gap cannot be "fixed" by increasing communication in later stages.
  • Closing the Gap: On CIFAR-10 with 32 workers on a ring topology, standard D-SGD achieved ~91.7% accuracy compared to 92.8% for centralized training. By applying consensus control only in the first phase, the researchers fully recovered the 92.8% accuracy.
  • Diversity as a Feature: Surprisingly, in middle training stages, a larger consensus distance (more model diversity) actually improved generalization. This "noise" acted as a form of regularization, similar to Stochastic Weight Averaging (SWA). In some ImageNet-32 experiments, controlled decentralized training even outperformed the centralized baseline (93.04% vs 92.82%).

Conclusion and Future Work

This work demonstrates that network topology is merely a proxy for consensus distance. By focusing on the latter, researchers can optimize decentralized training more effectively.

Future work remains to address Non-IID data scenarios (common in Federated Learning), where consensus control will likely be even more critical. Additionally, exploring the interaction between consensus control and other optimization techniques, such as learning rate warmups or large-batch optimizers (LAMB/LARS), provides a promising avenue for further scaling deep learning training.

Summary updated

BibTeX
@inproceedings{kong2021consensus,
  author = {Lingjing Kong and Tao Lin and Anastasia Koloskova and Martin Jaggi and Sebastian U. Stich},
  title = {{Consensus Control for Decentralized Deep Learning}},
  booktitle = {International Conference on Machine Learning},
  year = {2021},
  url = {https://openreview.net/forum?id=DwwicN1DDav},
}
Figure