Manuscript Offprint

arXiv:2610.30075

From Classifier Heads to Encoder Prototypes: Personalized Federated Learning with Head-Derived Clustering

Amirardalan Dehghanpour, Arian Noori, Ehsan Tanghatari, Naimeh Omidvar, Hamid R. Rabiee

Abstract

Personalized federated learning must decide which clients should share representations. We introduce HDC-FL (Head-Derived Clustering for Personalized Federated Learning), which reads that decision off a signal shared-encoder training already produces: the client-specific classifier heads. At periodic refresh rounds the server projects the cached heads into a normalized low-rank descriptor space, groups the descriptors, builds one encoder prototype per group from the cached client encoders, and returns to each client a soft mixture of those prototypes paired with its own unchanged head. Client-specific heads are never averaged or distributed to other clients; the shared-encoder trajectory is left intact; and no second optimization trajectory, additional local objective, or post-training fine-tuning stage is required. Across 11 CIFAR-10 and CIFAR-100 configurations covering label-subset, Dirichlet and rotation heterogeneity with ResNet-18 and MobileNetV2 encoders, HDC-FL is competitive with the strongest personalized and clustered baselines in macro-averaged mean accuracy and attains the numerically highest macro-averaged worst-client and bottom-20% accuracy among the evaluated methods. The tail results distinguish methods that look similar when only their means are compared. A controlled donor-swap diagnostic further finds positive donor-ranking associations between head similarity and encoder compatibility in all three settings tested, most clearly under covariate shift.

1 Introduction

Federated learning (FL) trains a model from decentralized data without transferring clients' raw examples to a central server (McMahan et al., 2017; Konečný et al., 2016). In practice, however, client data are rarely independent and identically distributed. Clients may observe different label frequencies, subsets of classes, acquisition devices, or environmental conditions (Kairouz et al., 2021; Zhao et al., 2018; Hsu et al., 2019; Li et al., 2020). A model that performs well for the population average can therefore serve some clients poorly. This failure is easily obscured when models are evaluated solely by mean accuracy, which can mask severe degradation for the worst-performing clients. Personalization has also been studied as a route to more uniform performance across clients (Li et al., 2021a). Personalized FL must consequently be judged not only by average performance, but also by how well it serves the clients that benefit least from uniform collaboration.

∗^{*}Contributed equally.

Personalized FL addresses this problem by allowing selected model components to vary across clients. A common decomposition shares an encoder while retaining a private classifier head for each client (Arivazhagan et al., 2019; Collins et al., 2021; Oh et al., 2022). Although the private head adapts the decision boundary to local data, every client still relies on the same representation. This can be limiting under non-IID data: clients with different label support or acquisition conditions may require different features even when their classifiers are trained independently. Personalizing the encoder can reduce this form of negative transfer, but only if the server can determine which clients should share representation information.

Existing clustered and similarity-based methods attempt to infer such relationships, but their affinity signals may vary with individual local updates, require additional client computation or communication, or impose a hard assignment to one group. The central challenge is to obtain a stable client-relatedness signal from information already produced during training and to use it for graded representation sharing without maintaining separate optimization trajectories for different groups.

We use the geometry of client-specific classifier heads for this purpose. All client-specific heads operate on features produced along the same shared-encoder trajectory and use the same class ordering. The rows of a linear head can therefore be interpreted as client-specific class directions in a common feature space. Under label-subset skew, their arrangement reflects which class distinctions are supported by a client's data. Under covariate shift, such as image rotation, the label frequencies may remain similar while the class directions move because clients use the shared features differently. Head geometry thus provides a model-side description of the local prediction problem without requiring an additional data summary or local objective.

We introduce Head-Derived Clustering for Personalized Federated Learning (HDC-FL). At periodic refresh rounds, the server projects cached classifier heads into a normalized low-rank space and groups clients using the resulting descriptors. It then constructs prototype encoders from cached client encoders and gives each client a soft mixture of those prototypes. The personalized encoder is paired with the client's unchanged private head and is used for evaluation or deployment; it is not fed back into later federated updates. HDC-FL therefore personalizes representations while retaining one shared-encoder training trajectory. It neither averages client-specific heads nor requires a second local training stage or independently optimized cluster models.

We evaluate HDC-FL on CIFAR-10 and CIFAR-100 across 11 configurations covering label-subset, Dirichlet, and rotation heterogeneity with ResNet-18 and MobileNetV2 encoders. HDC-FL remains competitive with the strongest evaluated personalized and clustered baselines in macro-averaged mean accuracy, while providing consistently strong worst-client and bottom-20% accuracy. The tail results distinguish methods that appear similar when only their means are compared.

Our contributions are threefold:

  • We identify classifier-head geometry as a client-relatedness signal for representation personalization and explain how it can reflect both label and covariate heterogeneity.

  • We develop HDC-FL, which converts low-rank head descriptors into soft mixtures of encoder prototypes without averaging client-specific heads, changing the local objective, or maintaining multiple training trajectories.

  • We evaluate average and poorly served clients separately using mean, worst-client, and bottom-20% accuracy across 11 settings. This evaluation reveals failures hidden by mean accuracy and shows that HDC-FL combines competitive average performance with consistently strong client-level tails.

References (24)