Unlocking the Potential of Federated Learning for Deeper Models

Haolin Wang, Xuefeng Liu, Jianwei Niu, Shaojie Tang, Jiaxing Shen · Submission to ICLR 2024 · Withdrawn

TL;DR

While centralized learning thrives with ultra-deep architectures, standard Federated Learning (FL) suffers a severe performance drop when scaled to deep networks—even on identically distributed (i.i.d.) data. The culprit is divergence accumulation: client gradient dissimilarities steadily compound backward through each layer during backpropagation. To counter this, the authors propose architectural and data-centric guidelines (such as widening networks, shrinking receptive fields, and increasing image resolution) that drastically shrink client divergence and narrow the gap between FL and centralized training.

What Problem Does This Paper Address?

Most federated learning research evaluates shallow, small-scale models with fewer than 10 layers. However, when researchers attempt to train standard deep architectures (like ResNet-101 or Vision Transformers) from scratch in an FL setting, performance degrades sharply compared to Centralized Learning (CL).

Surprisingly, this issue persists even in idealized, non-heterogeneous conditions where client data is independently and identically distributed (i.i.d.). While deeper networks should offer higher representational capacity, deep FL models converge more slowly, train unstably, and exhibit a widening accuracy gap relative to CL baselines.

Methods

  1. Formalizing Gradient Divergence:
    The authors define layer-wise divergence as the Euclidean distance between a client’s expected gradient and the global average gradient across clients, normalized by parameter dimension: $$\text{div}_t^L = \frac{1}{N} \sum_{i=1}^N \sqrt{\frac{\|\mathbb{E}_{x \in X_i}[\nabla_{\theta^L} \mathcal{L}] - \bar{\nabla}\theta_t^L\|_2^2}{d^L}}$$ Zero divergence occurs if and only if the FL optimization objective perfectly aligns with centralized learning.

  2. Theoretical Proof of Divergence Accumulation:
    By analyzing gradient propagation through adjacent layers under mild assumptions (gradient norm preservation and statistical independence), the authors prove that: $$\mathbb{E}[\|\epsilon_{i-1}\|^2] \ge \mathbb{E}[\|\epsilon_i\|^2]$$ During backpropagation, each preceding (shallower) layer inherits both the backpropagated divergence from deeper layers and adds new divergence from its own inputs. Deeper networks form longer chains, amplifying this accumulation.

  3. Mitigation Guidelines: Rather than designing complex new aggregation protocols, the authors show that standard architectural and data adjustments mitigate divergence:

  4. Wider Layers: Leverage the "lazy training" regime of overparameterized networks, where weights update more moderately and stably.

  5. Smaller Receptive Fields: Restrict neurons to local, low-level semantic features (e.g., edges, textures) that vary less across diverse images.
  6. Higher Input Resolution: Keeps receptive fields spatially localized relative to image size.
  7. Data Preprocessing & Augmentation: Random Resized Crop (RRC) and residual skip connections help reduce path lengths and input variability.

Datasets

The authors validate their theoretical and empirical findings across several vision benchmarks:

  • Tiny-ImageNet: 100,000 training images across 200 classes.
  • CIFAR-100: 50,000 training and 10,000 test images across 100 classes.
  • CIFAR-10: 50,000 training and 10,000 test images across 10 classes.
  • MNIST: Used with Gaussian noise perturbations and class-conditional inputs to visualize layer-wise divergence accumulation.

Key Insights and Ideas

  • It is depth, not parameter count, that degrades FL: Increasing parameter counts by widening layers actually improves FL performance and narrows the gap to CL, debunking the idea that deep FL fails merely due to local overfitting of large models.
  • Divergence accumulates from back to front: Earlier layers in deep networks suffer from the largest accumulated gradient variance across clients because they sit at the end of the backpropagation chain.
  • Local vs. global receptive fields matter: Architectures with localized attention or smaller convolutional kernels (e.g., Swin Transformer, $3\times3$ convolutions) substantially outperform architectures with global receptive fields (e.g., standard ViT with full self-attention, $7\times7$ convolutions) in FL.

Key Results

  • Shrinking Receptive Fields: Replacing the standard $7\times7$ stem convolution and removing MaxPooling in ResNet-101 boosted FL accuracy on Tiny-ImageNet from 23.6% to 47.3% (closing the gap to CL from 10.4% down to 1.3%).
  • Model Width: Increasing a 13-layer ResNet from $1\times$ to $3\times$ width increased FL accuracy on Tiny-ImageNet from 45.8% to 50.4%, while reducing divergence from 0.046 to 0.011 and narrowing the FL–CL gap from 5.1% to 4.1%.
  • Transformers (Swin vs. ViT): On Tiny-ImageNet, ViT experienced a 30.5% drop moving from CL to FL (0.340 $\to$ 0.236), whereas Swin (with local windowed attention) experienced only a 16.2% drop (0.389 $\to$ 0.326).
  • Image Resolution: Scaling input resolution on ResNet-101 from $64\times64$ to $192\times192$ improved FL accuracy on Tiny-ImageNet from 23.6% to 49.0%, reducing the CL-FL gap from 10.4% to 5.0%.

Limitations and Future Work

  • Evaluation Restricted to Vision Tasks: The theoretical insights and empirical tests are concentrated on CNNs and Vision Transformers on image classification tasks; their applicability to natural language processing or speech remains unexamined.
  • Predominantly I.I.D. Setup: The core analysis isolates depth effects by assuming i.i.d. client partitions; non-i.i.d. data skews—typical in real-world FL—will likely exacerbate divergence accumulation and warrant specialized aggregation rules.
  • Computational Trade-offs: Recommended strategies (e.g., widening models or increasing image resolution) increase local compute and memory footprints, which can constrain resource-limited edge devices.

Summary updated

BibTeX
@misc{wang2023unlocking,
  author = {Haolin Wang and Xuefeng Liu and Jianwei Niu and Shaojie Tang and Jiaxing Shen},
  title = {{Unlocking the Potential of Federated Learning for Deeper Models}},
  year = {2023},
  eprint = {2306.02701},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2306.02701},
}
Figure