Federated Learning with Personalization Layers

Manoj Ghuhan Arivazhagan, Vinay Aggarwal, Aaditya Kumar Singh, Sunav ChoudharyarXiv 2019

Abstract

Federated Learning (FL) enables training models on decentralized data, but standard approaches like FedAvg often fail to account for the statistical heterogeneity of edge devices. This paper introduces FedPer, a method that splits deep neural networks into shared base layers and private personalization layers. By keeping the "head" of the model local, FedPer allows for individual user adaptation while benefiting from collective feature extraction. Experiments on non-IID CIFAR and real-world image aesthetics datasets show that FedPer significantly improves accuracy, convergence speed, and fairness compared to traditional FL methods.

Introduction: The Challenge of Heterogeneity

Standard Federated Learning (FL) aims to train a single global model across millions of edge devices without moving raw data. While effective for privacy, the standard FedAvg algorithm assumes a "one-size-fits-all" model is optimal. However, real-world data is often statistically heterogeneous. For instance, in subjective tasks like image aesthetics, user preferences vary wildly—what one user considers beautiful, another may find unappealing. Training a single global model on such diverse data often leads to a "mediocre average" that fails to satisfy any individual user.

The FedPer Method: Balancing Global and Local Knowledge

To address this, the authors propose FedPer (Federated Personalization). This approach treats a deep neural network as a two-part construction:

  1. Base Layers: The early layers of the network responsible for extracting general features (e.g., edges and textures). These are trained collaboratively and shared across the network.
  2. Personalization Layers: The final layers (the "head") that make specific decisions. These are kept strictly local to each device and are never shared with the server.
The FedPer architecture separates shared base layers from private personalization layers kept on individual devices.

In the FedPer workflow, the server distributes updated base layers to clients. Clients then combine these with their unique local personalization layers to train the full stack on local data. Only the updated base layers are returned to the server for aggregation, allowing the model to learn a shared feature language while maintaining user-specific decision logic.

Experimental Evaluation

The researchers evaluated FedPer against two distinct data types:

  • Non-IID CIFAR-10/100: Standard datasets partitioned so that each client only sees a small subset of classes, simulating extreme data imbalance.
  • FLICKR-AES: A real-world dataset of 40,000 photos rated by 210 users. This represents a true personalization task where subjective taste drives the labels.

Results and Discussion

FedPer demonstrated significant advantages over standard FedAvg across multiple metrics:

  • Superior Accuracy and Convergence: On non-IID CIFAR data, FedPer outperformed FedAvg in both the speed of convergence and final test accuracy.
  • Architecture Robustness: The benefits were consistent across different model architectures, including MobileNet-v1 and ResNet-34.
Comparison of FedPer and FedAvg accuracy across MobileNet-v1 and ResNet-34 architectures.
  • Fairness and Consistency: FedPer reduced the variance in accuracy across different clients. While standard FL often leaves some users with poor models, FedPer provides a more consistent experience by allowing local adaptation.
  • Handling Subjectivity: On the FLICKR-AES dataset, FedAvg performed no better than random guessing due to conflicting user preferences. FedPer, by contrast, achieved meaningful predictive power by isolating those preferences in the personalization layers.

Conclusion and Future Work

FedPer offers a pragmatic solution for federated systems where global averages are insufficient. By leveraging the crowd for feature extraction while respecting individual subjectivity, it paves the way for more intelligent, user-centric edge AI. Future research may explore automated heuristics for choosing the optimal number of personalization layers and extending the method to non-CNN architectures like Transformers.

Summary updated

BibTeX
@misc{arivazhagan2019federated,
  author = {Manoj Ghuhan Arivazhagan and Vinay Aggarwal and Aaditya Kumar Singh and Sunav Choudhary},
  title = {{Federated Learning with Personalization Layers}},
  year = {2019},
  eprint = {1912.00818},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1912.00818},
}
Figure