Table of Contents
Fetching ...

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.

FedAPA: Federated Learning with Adaptive Prototype Aggregation Toward Heterogeneous Wi-Fi CSI-based Crowd Counting

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.

Paper Structure

This paper contains 42 sections, 8 theorems, 113 equations, 8 figures, 5 tables, 2 algorithms.

Key Result

Theorem 1

Let Assumptions ass:A1 to ass:A5 hold. For any client $i$ and any $t$, with step size $0<\eta\le 1/L_t$, we have

Figures (8)

  • Figure 1: Illustration of two different environment layout for Wi-Fi CSI-based crowd counting data collection.
  • Figure 2: Overview of the proposed framework. Bottom: Clients with varying computational resources capture CSI data in distinct environments (e.g., Meeting Room, Office) and extract local prototypes from CSI data. Top: The Parameter Server aggregates uploads via Adapted Prototype Aggregation (APA) to form personalized sets $\mathbf{Q}$. Training: Clients optimize backbones $w^\theta$ and classifiers $w^h$ using the returned global $\mathbf{P}$ and personalized $\mathbf{Q}$ sets via a hybrid loss.
  • Figure 3: The encoder $w_i^{\theta}$ extracts features $\mathbf{r}_i$ from CSI input $\mathbf{h}$ for classification by $w_i^h$. The training objective integrates cross-entropy with contrastive alignment against prototype sets $\mathbf{Q}_i$ and $\mathbf{P}$, modulated by a warm-up coefficient $\lambda$ that progressively emphasizes representation learning after classification stabilizes.
  • Figure 4: Data distribution of six distinct environments.
  • Figure 5: The convergence behavior of different methods in heterogeneous data.
  • ...and 3 more figures

Theorems & Definitions (13)

  • Theorem 1: One-round deviation for an arbitrary client
  • Theorem 2: $\varepsilon$-stationarity after warm-up
  • Lemma 1: One-step descent with fixed prototypes
  • proof
  • Corollary 1: $S$-step descent within a round
  • Lemma 2: Prototype movement
  • proof
  • Lemma 3: Loss change due to prototype refresh
  • proof
  • Theorem 1: One-round deviation for an arbitrary client
  • ...and 3 more