Introduction
Federated Learning (FL) typically relies on a central server to aggregate model updates from decentralized clients. While the standard FedAvg algorithm is widely used, it often results in unfairness where the global model performs well for some clients but poorly for others. This discrepancy often stems from "gradient conflicts"—situations where one client's model update opposes another's, particularly when magnitude differences are large.
The Federated Fair Averaging (FedFV) algorithm addresses this by identifying and mitigating these conflicts. By iteratively projecting conflicting gradients and maintaining a gradient history for unselected clients, FedFV achieves a more equitable accuracy distribution and faster convergence than traditional averaging methods.
The Problem: Gradient Conflicts and Magnitude Bias
The authors identify two primary types of conflicts that lead to unfairness in FL systems:
- Internal Conflicts: A client with a large gradient magnitude (often due to more data) can dominate the average, effectively erasing the updates of "quieter" clients if their directions oppose.
- External Conflicts: Since only a subset of clients is selected per round, the global update might conflict with the needs of unselected clients, causing the model to "forget" their specific data distributions.
Methods: Conflict-Aware Aggregation
FedFV moves beyond simple averaging to a conflict-aware strategy. The server uses cosine similarity to detect conflicts where the dot product of two gradients is negative ($g_i \cdot g_j < 0$).
To resolve these, FedFV projects the gradient of one client onto the normal plane of another, neutralizing the harmful component of the update. Crucially, clients are sorted by training loss; gradients from "stronger" clients (lower loss) are projected to avoid conflicting with "struggling" clients (higher loss). This prioritizes the "underdog" to ensure the model improves where it is weakest. To handle external conflicts, the server maintains a Gradient History (GH) to estimate the needs of unselected clients using their most recent updates.
Experimental Evaluation
The algorithm was evaluated on three standard computer vision benchmarks, modified to simulate the Non-IID nature of real-world federated data:
- CIFAR-10: Highly skewed data distributions via class-based sharding.
- Fashion MNIST: Testing fairness across different clothing categories.
- MNIST: Evaluated using a Convolutional Neural Network (CNN) setup.
Key Results and Performance
FedFV was compared against several state-of-the-art fair FL methods, including AFL, q-FedAvg, and FedMGDA+.
- Superior Fairness: On CIFAR-10, FedFV achieved the lowest variance in accuracy across clients while maintaining the highest mean accuracy (~50.4% vs. FedAvg’s ~46.8%).
- Protecting the "Worst 5%": In CIFAR-10 experiments, the bottom tier of clients saw their accuracy jump to 32.2%, compared to just 19.8% with standard FedAvg.
- Efficiency: FedFV converged significantly faster than competing fairness algorithms like q-FedAvg, which often require many more communication rounds to reach stability.
Conclusion and Future Work
FedFV reframes fairness in FL as a geometric problem of resolving directional interference. By prioritizing struggling clients through loss-based projection and maintaining a memory of unselected clients, it provides a robust framework for equitable federated training. While the method introduces some computational overhead and hyperparameter sensitivity, it offers a significant step forward in balancing performance and fairness. Future work will look into a more complete theoretical analysis of mitigating complex external conflicts.
Summary updated