STL-SGD: Speeding Up Local SGD with Stagewise Communication Period

Shuheng Shen, Yifei Cheng, Jingchang Liu, Linli Xu

Introduction

In the era of large-scale distributed machine learning, communication overhead remains a primary bottleneck. Standard Synchronous SGD (SyncSGD) requires frequent synchronization between clients and a central server, often leading to significant delays. While Local SGD (or FedAvg) addresses this by allowing clients to perform multiple local updates before communicating, finding the optimal communication frequency ($k$) is challenging. A fixed $k$ often forces a trade-off between communication efficiency and model accuracy.

This paper introduces STL-SGD (Stagewise Local SGD), a novel optimization framework that adaptively increases the communication period as the learning rate decays. By linking the synchronization frequency to the training progress, STL-SGD achieves state-of-the-art communication complexity while maintaining the essential linear speedup property for distributed scaling.

The STL-SGD Framework

The core innovation of STL-SGD is its stagewise adaptive scheme. The authors identify a fundamental inverse relationship: as the learning rate ($\eta$) decreases, the model becomes more stable, allowing for a larger communication period ($k$) without causing excessive model drift. Specifically, they propose that $k$ should scale as $O(1/\eta N)$.

Two variants are proposed to handle different optimization landscapes:

  1. STL-SGD$^{sc}$ (Strongly Convex): Designed for problems like logistic regression. In each stage, the learning rate is halved, the number of iterations is doubled, and the communication period $k$ is increased (doubled for IID data, or increased by $\sqrt{2}$ for Non-IID data).
  2. STL-SGD$^{nc}$ (Non-Convex): Tailored for deep neural networks. To ensure stability during aggressive communication reduction, this version employs proximal regularization at each stage, effectively keeping the model close to the stage's starting point to mimic convex behavior.

Theoretical Breakthroughs

STL-SGD breaks through previous theoretical floors for adaptive Local SGD. While prior methods were limited to a communication complexity of $O(N^{1/3} T^{1/3})$, STL-SGD achieves a complexity as low as $O(N \log T)$ for strongly convex IID problems. Crucially, it preserves the "linear speedup" property, meaning that increasing the number of clients ($N$) continues to reduce the total number of iterations required to reach a target error.

Empirical Performance

The researchers evaluated STL-SGD against SyncSGD and standard Local SGD across convex (a9a, MNIST) and non-convex (CIFAR-10 with ResNet18/VGG16) benchmarks in both IID and Non-IID settings.

Performance comparison on convex problems (a9a and MNIST) under IID and Non-IID settings.

In convex scenarios, the speedups were dramatic. On the a9a dataset (IID), STL-SGD reached the target error 1650x faster than SyncSGD and nearly 3x faster than standard Local SGD in terms of communication rounds. Similar trends were observed in the MNIST experiments, where STL-SGD consistently required fewer rounds to achieve lower objective gaps.

Deep Learning and Non-IID Data

The advantages of STL-SGD extend to complex deep learning tasks. When training ResNet18 on CIFAR-10 (Non-IID), STL-SGD reached 99% training accuracy in just 434 rounds, compared to 755 rounds for standard Local SGD and a staggering 7644 rounds for SyncSGD.

Training loss vs. communication rounds for ResNet18 on CIFAR-10 (Non-IID).

As shown in the figure above, both variants of STL-SGD$^{nc}$ significantly outperform the baselines, demonstrating that the stagewise communication period is highly effective even in challenging non-convex and heterogeneous data environments.

Conclusion and Future Work

STL-SGD represents a significant step forward in distributed optimization by mathematically grounding the communication period in the learning rate's decay. While the method shows massive speedups, future work could explore its sensitivity to hyperparameters like initial stage lengths and its integration with variance reduction techniques (e.g., SCAFFOLD) to further enhance robustness in extreme Non-IID scenarios. Additionally, extending the theory to support partial client participation would make it even more applicable to large-scale Federated Learning environments.

Summary updated

BibTeX
@inproceedings{shen2021stl,
  author = {Shuheng Shen and Yifei Cheng and Jingchang Liu and Linli Xu},
  title = {{STL-SGD: Speeding Up Local SGD with Stagewise Communication Period}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2021},
  doi = {10.1609/aaai.v35i11.17153},
}
Figure