FedAPA: Federated Learning with Adaptive Prototype Aggregation Toward Heterogeneous Wi-Fi CSI-based Crowd Counting
Jingtao Guo, Yuyi Mao, Ivan Wang-Hei Ho
TL;DR
FedAPA tackles the challenge of distributed Wi-Fi CSI-based crowd counting under strong non-IID data and device heterogeneity by introducing adaptive prototype aggregation (APA), which personalizes knowledge sharing through similarity-weighted class prototypes rather than full model parameters. Prototypes p_i^c are exchanged, and the server constructs personalized prototypes q_i^c via cosine similarity with temperature τ, enabling per-client personalization while sharing compact information. Local training combines cross-entropy with prototype-based contrastive losses L_g and L_c, moderated by a warm-up schedule on λ to progressively emphasize representation learning, and a theoretical convergence analysis quantifies the impact of prototype similarity and warm-up on nonconvex optimization. Experiments across six real environments with multiple architectures demonstrate that FedAPA improves accuracy, F1, and MAE while dramatically reducing communication overhead versus baselines like FedAvg, CARING, and WiFederated, highlighting its practical impact for scalable, privacy-preserving Wi-Fi sensing in heterogeneous deployments.
Abstract
Wi-Fi channel state information (CSI)-based sensing provides a non-invasive, device-free approach for tasks such as human activity recognition and crowd counting, but large-scale deployment is hindered by the need for extensive site-specific training data. Federated learning (FL) offers a way to avoid raw data sharing but is challenged by heterogeneous sensing data and device resources. This paper proposes FedAPA, a collaborative Wi-Fi CSI-based sensing algorithm that uses adaptive prototype aggregation (APA) strategy to assign similarity-based weights to peer prototypes, enabling adaptive client contributions and yielding a personalized global prototype for each client instead of a fixed-weight aggregation. During local training, we adopt a hybrid objective that combines classification learning with representation contrastive learning to align local and global knowledge. We provide a convergence analysis of FedAPA and evaluate it in a real-world distributed Wi-Fi crowd counting scenario with six environments and up to 20 people. The results show that our method outperform multiple baselines in terms of accuracy, F1 score, mean absolute error (MAE), and communication overhead, with FedAPA achieving at least a 9.65% increase in accuracy, a 9% gain in F1 score, a 0.29 reduction in MAE, and a 95.94% reduction in communication overhead.
