Buffered Asynchronous SGD for Byzantine Learning

Yi-Rui Yang, Wu-Jun Li

TL;DR

This paper introduces Buffered Asynchronous Stochastic Gradient Descent (BASGD) and its momentum variant (BASGDm), the first asynchronous methods that can resist non-omniscient Byzantine attacks without requiring the server to store training data. These methods offer improved resilience and convergence in distributed learning settings prone to failures or malicious attacks, outperforming existing baselines.

What Problem Does This Paper Address?

Distributed machine learning, widely used in applications like federated learning and edge computing, typically assumes reliable network conditions and honest participants. However, real-world scenarios often involve communication failures, hardware issues, or even malicious actors (Byzantine workers) who can send arbitrary gradients. Traditional Byzantine-resilient methods are often synchronous, which is impractical for systems with heterogeneous or offline workers. Asynchronous methods are more suitable, but existing asynchronous Byzantine learning (ABL) methods either require the server to store training data (raising privacy concerns) or struggle to defend against sophisticated attacks. This paper addresses the need for asynchronous, data-private, and robust methods against a range of Byzantine attacks.

Methods

The core innovation is Buffered Asynchronous Stochastic Gradient Descent (BASGD). The server maintains $B$ buffers, and gradients from worker $s$ are stored in buffer $s \pmod B$. An update occurs only when all buffers are filled, making it semi-asynchronous from the server's perspective. This buffering mechanism allows the server to accumulate gradients and use robust aggregation functions (like median or trimmed-mean) to filter out potentially malicious inputs.

Key components include:

  • Buffering: $B$ buffers on the server to temporarily store gradients.
  • Aggregation Function: A function (e.g., median, trimmed-mean, geometric median, centered clipping) to combine gradients from buffers into a single update. These functions are designed to be "q-Byzantine Robust" (q-BR), meaning they can tolerate up to $q$ malicious gradients.
  • Mapping Table & Reassignment Interval ($\Delta$): A mechanism to reassign workers to buffers if a buffer becomes a "straggler" (i.e., no gradients are received for a certain time $\Delta$). This prevents slow workers from holding up the entire training process.

An improved variant, BASGD with Momentum (BASGDm), is also proposed. It incorporates local momentum at each worker, which has been shown to enhance Byzantine resilience in synchronous settings. BASGDm uses these local momentums for aggregation instead of raw gradients.

Datasets

The paper evaluates its methods on:

  • CIFAR-10: For image classification tasks using a ResNet-20 model.
  • WikiText-2: For natural language processing tasks using an LSTM network.

No new datasets were introduced.

Key Insights and Ideas

  • Buffering as a Bridge: BASGD effectively bridges the gap between synchronous and asynchronous Byzantine learning. By buffering gradients, it allows for robust aggregation similar to synchronous methods while maintaining the asynchronous nature required for heterogeneous systems.
  • Momentum for Enhanced Resilience: Incorporating local momentum (BASGDm) significantly boosts Byzantine resilience, especially against more sophisticated attacks. This highlights the importance of historical information in combating adversarial behavior.
  • Data Privacy Advantage: By not requiring the server to store training instances, BASGD offers a crucial advantage for privacy-sensitive applications like federated learning, unlike some prior ABL methods.
  • Trade-off in Buffer Size: The buffer size $B$ presents a trade-off: larger $B$ can improve resilience but might slow down the update frequency, while smaller $B$ might compromise robustness.
  • Reassignment Interval ($\Delta$) Tuning: The reassignment interval $\Delta$ is critical for performance. Too small a $\Delta$ leads to frequent buffer resets, hindering progress, while too large a $\Delta$ fails to address stragglers effectively.

Key Results

  • Non-Omniscient Attacks: BASGD (and BASGDm) significantly outperforms Kardam (a baseline ABL method) under Random Disturbance and Negative Gradient attacks, maintaining good performance where Kardam fails to converge.
  • Omniscient Attacks: BASGDm demonstrates strong resilience against 'Fall of Empires' (FoE) and 'A Little is Enough' (ALIE) attacks, outperforming other methods.
  • Convergence: Theoretical analysis shows that BASGD achieves convergence rates comparable to vanilla ASGD, with an additional variance term that is a trade-off for Byzantine resilience. BASGDm with momentum achieves even better theoretical guarantees, particularly in i.i.d. settings.
  • Empirical Performance: Experiments on image classification (CIFAR-10) and NLP (WikiText-2) confirm that BASGD and BASGDm achieve higher accuracy/lower perplexity than baselines under various attack scenarios.
  • Wall-Clock Time: BASGDm incurs a slightly larger time cost than ASGD but is generally faster than Kardam.

Limitations and Future Work

  • Non-i.i.d. Cases: The paper notes that using local momentum does not help reduce bias in non-i.i.d. (non-independent and identically distributed) settings. Enhancing Byzantine resilience for non-i.i.d. asynchronous settings remains an open challenge.
  • Constant Error Terms: Theoretical results for general non-i.i.d. cases in ABL methods often include constant error terms, and it's an open problem whether these can be removed.
  • Tuning $\Delta$: The performance of BASGDm is sensitive to the buffer reassignment interval $\Delta$, requiring careful tuning for optimal results.
  • Future Work: The authors suggest exploring how to enhance Byzantine resilience for non-i.i.d. cases in asynchronous settings.

Summary updated

BibTeX
@article{yang2023buffered,
  author = {Yi-Rui Yang and Wu-Jun Li},
  title = {{Buffered Asynchronous SGD for Byzantine Learning}},
  journal = {J. Mach. Learn. Res.},
  year = {2023},
}
Figure