Taming Cross-Domain Representation Variance in Federated Prototype Learning with Heterogeneous Data Domains

Lei Wang, Jieming Bian, Letian Zhang, Chen Chen, Jie Xu

Abstract

Federated learning (FL) allows collaborative machine learning training without sharing private data. While most FL methods assume identical data domains across clients, real-world scenarios often involve heterogeneous data domains. Federated Prototype Learning (FedPL) addresses this issue, using mean feature vectors as prototypes to enhance model generalization. However, existing FedPL methods create the same number of prototypes for each client, leading to cross-domain performance gaps and disparities for clients with varied data distributions. To mitigate cross-domain feature representation variance, we introduce FedPLVM, which establishes variance-aware dual-level prototypes clustering and employs a novel $\alpha$-sparsity prototype loss. The dual-level prototypes clustering strategy creates local clustered prototypes based on private data features, then performs global prototypes clustering to reduce communication complexity and preserve local data privacy. The $\alpha$-sparsity prototype loss aligns samples from underrepresented domains, enhancing intra-class similarity and reducing inter-class similarity. Evaluations on Digit-5, Office-10, and DomainNet datasets demonstrate our method's superiority over existing approaches.

Introduction

Standard Federated Learning (FL) research frequently focuses on "label skew," where clients possess varying quantities of specific classes. However, a more pervasive challenge in real-world applications is domain heterogeneity, or "feature skew." In these scenarios, while clients may share the same labels, the underlying data distribution differs significantly. For instance, one client might train on clean, black-and-white MNIST digits, while another uses Street View House Numbers (SVHN), which contain complex backgrounds and varying lighting conditions.

Existing Federated Prototype Learning (FedPL) methods typically represent a class as a single average feature vector (a prototype). This "vanilla" approach often fails to capture the complex variance inherent in "hard" domains like SVHN. Consequently, global models tend to excel at simple tasks while struggling with difficult ones, essentially ignoring the rich structural information hidden within the variance of complex data. To address this, we propose FedPLVM (Federated Prototype Learning with Variance Mitigation).

Methodology

FedPLVM introduces two primary innovations designed to capture and utilize domain-specific variance rather than smoothing it over.

1. Dual-Level Prototype Clustering

Instead of a single mean vector per class, FedPLVM employs a hierarchical clustering approach:

  • Local Level: Clients utilize a parameter-free clustering algorithm (FINCH) to generate multiple local prototypes. This allows the model to capture the scattered distribution and nuances of complex, high-variance domains.
  • Global Level: To maintain communication efficiency and protect privacy, the server performs a second round of clustering on the collected local prototypes. This produces a refined set of global clustered prototypes which are then distributed back to clients.

2. $\alpha$-Sparsity Prototype Loss

To further improve the separation between classes, we designed a novel loss function inspired by InfoNCE. This function introduces a sparsity factor ($\alpha$) by raising the cosine similarity to a power between 0 and 1. Because this function is concave, it more aggressively "repels" prototypes of different classes, creating greater separation (sparsity) in the feature space. Additionally, an intra-class similarity correction term ensures that while different classes are pushed apart, samples within the same class remain tightly grouped.

Experimental Evaluation

We evaluated FedPLVM against state-of-the-art baselines (including FedAvg, FedProto, and FPL) across three major benchmarks:

  • Digit-5: MNIST, SVHN, USPS, Synth, and MNIST-M.
  • Office-10: Amazon, Caltech, DSLR, and Webcam.
  • DomainNet: A 10-class subset across Clipart, Infograph, Painting, Quickdraw, Real, and Sketch.

Key Results

FedPLVM consistently outperformed existing methods across all datasets:

  • Digit-5: Achieved an average accuracy of 69.25%, representing a +9.88% improvement over the baseline.
  • Office-10: Reached 60.65% accuracy, outperforming the next best method by over 1.5%.
  • DomainNet: Demonstrated a +7.03% improvement in average accuracy.

Notably, the most significant gains were observed in "hard" domains. In the Digit-5 benchmark, accuracy for the SVHN domain jumped by over 5%, confirming that capturing variance allows the model to learn more robust decision boundaries for complex data.

Discussion and Future Work

The core insight of FedPLVM is that variance within a class is not merely noise—it is a signature of domain complexity. By utilizing dual-level clustering, the framework maintains a balance between representational richness and communication overhead.

However, the method faces challenges regarding noisy labels. Incorrectly labeled data can lead to prototype distortion, where clustered prototypes are pulled toward the features of the wrong class, or prototype ambiguity, which blurs the distinction between classes. Future research will focus on integrating label-cleansing techniques or uncertainty-aware clustering to make FedPLVM more resilient to real-world data imperfections.

Summary updated

Abstract

Federated learning (FL) allows collaborative machine learning training without sharing private data. While most FL methods assume identical data domains across clients, real-world scenarios often involve heterogeneous data domains. Federated Prototype Learning (FedPL) addresses this issue, using mean feature vectors as prototypes to enhance model generalization. However, existing FedPL methods create the same number of prototypes for each client, leading to cross-domain performance gaps and disparities for clients with varied data distributions. To mitigate cross-domain feature representation variance, we introduce FedPLVM, which establishes variance-aware dual-level prototypes clustering and employs a novel $\alpha$-sparsity prototype loss. The dual-level prototypes clustering strategy creates local clustered prototypes based on private data features, then performs global prototypes clustering to reduce communication complexity and preserve local data privacy. The $\alpha$-sparsity prototype loss aligns samples from underrepresented domains, enhancing intra-class similarity and reducing inter-class similarity. Evaluations on Digit-5, Office-10, and DomainNet datasets demonstrate our method's superiority over existing approaches.
BibTeX
@inproceedings{wang2024taming,
  author = {Lei Wang and Jieming Bian and Letian Zhang and Chen Chen and Jie Xu},
  title = {{Taming Cross-Domain Representation Variance in Federated Prototype Learning with Heterogeneous Data Domains}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2024},
  url = {https://openreview.net/forum?id=6SRPizFuaE},
}
Figure