AdaFed: Fair Federated Learning via Adaptive Common Descent Direction

Shayan Mohajer Hamidi, En-Hui Yang · DOI

Introduction

Federated Learning (FL) has emerged as a transformative paradigm for training machine learning models across decentralized edge devices while preserving data privacy. However, a significant challenge persists: data heterogeneity. Because client data is often non-IID (not identically and independently distributed), a global model that minimizes average loss may perform exceptionally well for the majority but fail significantly for minority groups. This discrepancy leads to "unfair" models where performance variance across the network is high.

AdaFed addresses this challenge by reframing Federated Learning as a Multi-objective Minimization (MoM) problem. By introducing a computationally efficient, closed-form solution for finding a common descent direction, AdaFed ensures that model updates prioritize clients with the highest errors without sacrificing overall accuracy or convergence speed.

The Challenge of Fairness in Federated Learning

In standard FL frameworks like FedAvg, the central server aggregates local updates by simply averaging gradients. While efficient, this approach assumes that the average direction is beneficial for all participants. In reality, a gradient update that helps the "average" client might actually increase the error for a client with a unique data distribution.

Existing attempts to solve this—often categorized as "Fair FL"—frequently rely on complex optimization loops or re-weighting schemes that are computationally expensive or difficult to scale to massive neural networks. The goal is to reach a Pareto-stationary solution: a state where no single client's performance can be improved without degrading another's, while specifically biasing the trajectory toward those currently suffering from the highest loss.

The AdaFed Methodology

AdaFed introduces a two-phase server-side update mechanism designed to find an optimal "Common Descent Direction" (CDD). Unlike previous methods that require iterative quadratic programming, AdaFed utilizes a mathematical shortcut that makes it highly efficient.

1. Orthogonalization and Adaptive Scaling

When the server receives gradients from participating clients, it does not immediately average them. Instead, it applies a modified Gram-Schmidt process to transform the client gradients into a set of mutually orthogonal vectors.

Crucially, these vectors are scaled by the clients' current loss values, denoted as $|f_k|^\gamma$. The hyperparameter $\gamma$ acts as a fairness controller; by increasing $\gamma$, the system "amplifies" the influence of clients experiencing high error rates, ensuring the global update is heavily influenced by the struggling nodes.

2. Closed-Form Weighting

By first orthogonalizing the gradients, the authors simplify the complex multi-objective optimization problem into a linear one. AdaFed calculates the final update direction using a closed-form mathematical formula. This direction is guaranteed to satisfy two critical conditions:

  • Universal Descent: The update is a descent direction for every client (i.e., everyone’s loss is expected to decrease).
  • Fairness Bias: Clients with higher losses see their errors decrease at a faster rate than those with lower losses.

Experimental Evaluation

The authors evaluated AdaFed across seven diverse benchmarks, covering vision, language, and real-world noisy data:

  • Vision Benchmarks: CIFAR-10, CIFAR-100, Fashion MNIST, CINIC-10, and TinyImageNet.
  • Extreme Heterogeneity: A skewed version of FEMNIST was used to simulate harsh non-IID conditions.
  • Language Modeling: The Shakespeare dataset, utilizing LSTMs for next-character prediction.
  • Robustness to Noise: The Clothing1M dataset, which contains significant label noise, was used to test AdaFed’s compatibility with noise-reduction techniques like FedCorr.

Key Insights and Results

Superior Fairness and Accuracy

AdaFed consistently achieved the lowest standard deviation of accuracy across clients compared to state-of-the-art methods. On CIFAR-10, it reduced the standard deviation to 3.01 (compared to 3.54 for FedAvg). More impressively, it significantly boosted the performance of the "Worst 5%" of clients—from an accuracy of 19.84% under FedAvg to 31.12% under AdaFed.

Unlike many fairness-oriented algorithms that trade off global accuracy to help the minority, AdaFed often improved both. On CIFAR-100, it achieved an average accuracy of 31.42%, outperforming all benchmarks.

Accelerated Convergence

A surprising finding was that prioritizing the worst-performing clients actually improved the global model's convergence speed. On the CIFAR-10 dataset, AdaFed reached a 40% average accuracy threshold in just 400 rounds, whereas standard FedAvg required 900 rounds to reach the same milestone.

Computational Efficiency

Because AdaFed relies on a closed-form solution rather than an internal optimization loop, its computational overhead is negligible. This makes it a practical drop-in replacement for existing FL pipelines, even when training large-scale models.

Conclusion and Future Work

AdaFed demonstrates that fairness in Federated Learning does not have to come at the cost of efficiency or global performance. By leveraging orthogonalization and adaptive scaling, the algorithm provides a robust framework for handling data heterogeneity.

Future research may focus on optimizing the selection of the $\gamma$ hyperparameter and exploring how AdaFed’s common descent direction can be integrated with communication-compression techniques to further reduce the bandwidth requirements of decentralized training.

Summary updated

BibTeX
@article{hamidi2024adafed,
  author = {Shayan Mohajer Hamidi and En-Hui Yang},
  title = {{AdaFed: Fair Federated Learning via Adaptive Common Descent Direction}},
  journal = {Trans. Mach. Learn. Res.},
  year = {2024},
  url = {https://openreview.net/forum?id=IsPabotfzf},
}
Figure