1. Introduction
Sleep is a fundamental biological process and a cornerstone of human health. The regulation of sleep–wake cycles affects cognitive performance, metabolic balance, neuroplasticity, and immune function, while chronic sleep disturbances are associated with cardiometabolic disorders, neurodegenerative diseases, reduced life expectancy, and diminished quality of life. Despite its clinical relevance, large-scale sleep monitoring remains largely confined to specialized laboratories or short-term diagnostic protocols, limiting early detection and longitudinal assessment of sleep disorders.
The clinical gold standard for sleep assessment is overnight polysomnography (PSG), which involves the simultaneous acquisition of multiple biosignals—including electroencephalography (EEG), electrooculography (EOG), and electromyography (EMG)—followed by manual scoring according to standardized guidelines. Although PSG provides high diagnostic accuracy, it is costly, labor-intensive, and poorly scalable. It requires controlled environments, trained personnel, and substantial post-processing effort, making continuous or population-level monitoring impractical. Public datasets such as ISRUC-Sleep [
1] partially mitigate these limitations by enabling reproducible algorithmic evaluation; however, most existing studies rely on centralized training paradigms that assume unrestricted access to pooled raw data. Recent advances in deep learning have substantially improved automatic sleep-stage classification. End-to-end architectures based on convolutional, recurrent, and attention-based models can learn discriminative spectral–temporal representations directly from raw PSG signals, achieving strong performance on benchmark datasets [
2,
3]. These developments support the vision of continuous sleep monitoring outside clinical laboratories, potentially enabling preventive and personalized care. However, centralized training raises critical concerns regarding privacy, data sovereignty, and compliance with regulatory frameworks such as the General Data Protection Regulation (GDPR), especially when dealing with sensitive physiological data. Federated learning (FL) has emerged as a promising alternative to centralized model training. In FL, data remain at their source, while model parameters are exchanged and aggregated by a coordinating server [
4]. This paradigm is particularly attractive for healthcare systems, where data are naturally distributed across institutions, devices, and individuals, and where ethical and legal constraints often prohibit raw-data sharing [
5,
6]. Despite its conceptual appeal, the application of FL to physiological time-series analysis remains challenging. Unlike many benchmark tasks, biomedical signals are strongly non-independent and non-identically distributed (non-IID): inter-subject variability, sensor characteristics, pathological conditions, and sleep micro-architecture introduce systematic heterogeneity that violates the assumptions underlying naive federated optimization. Sleep-stage classification exemplifies this challenge. Each subject exhibits idiosyncratic sleep dynamics, distinct spectral signatures, and highly variable proportions of stages such as N1 and REM. As a consequence, local updates computed during federated training may point toward incompatible optima, and simple parameter averaging can amplify majority patterns while suppressing clinically relevant minority stages. Without mechanisms to account for heterogeneity, federated models risk instability and performance collapse. In this work, we investigate the feasibility of federated deep learning for automatic sleep-stage classification under realistic subject-level non-IID conditions. We adopt a strict one subject = one client configuration using the ISRUC-Sleep dataset, which comprises three clinically distinct subgroups (Subgroup I: 77 subjects; Subgroup II: 27 subjects; Subgroup III: 10 subjects). This setting reflects plausible deployment scenarios in digital health ecosystems, where individual patients, hospitals, or home-monitoring devices act as autonomous learning nodes, while cloud infrastructures provide orchestration and aggregation. Importantly, raw PSG data never leave the local client. The objective of this study is not to maximize classification accuracy through complex architectures or extensive tuning. Rather, it aims to provide a controlled and reproducible assessment of federated learning behavior in the presence of strong physiological heterogeneity. Specifically, we seek to: (i) quantify the degradation of standard aggregation strategies under subject-level non-IID data, (ii) characterize failure modes such as majority-class domination and loss of minority stages, and (iii) evaluate whether normalization-preserving federation (FedBN) offers a principled mitigation without relying on raw-data pooling or personalization.
The contributions of this work are threefold. First, we define a reproducible subject-level preprocessing and partitioning pipeline suitable for federated sleep analysis. Second, we compare a lightweight 1D-CNN trained under four regimes—centralized, FedAvg, FedProx, and FedBN—using identical architectures and optimization settings, thereby isolating the impact of federation strategies. Third, we analyze performance at both the global and client level, highlighting stability, fairness, and collapse patterns that are invisible to aggregate metrics alone. Together, these contributions position the manuscript as a methodological reference for evaluating federated learning in privacy-preserving sleep analytics.
The remainder of the paper is organized as follows.
Section 2 reviews related work on sleep-stage classification and federated learning in healthcare.
Section 3 describes the dataset, model architecture, and federated setup.
Section 4 details the experimental protocol.
Section 5 presents the results, and
Section 6 discusses implications and limitations.
Section 7 concludes the paper.
2. Related Work
Research on automatic sleep-stage classification has advanced significantly over the last decade, driven by the availability of public polysomnography (PSG) datasets and rapid progress in deep learning. Early approaches relied on handcrafted spectral features combined with traditional classifiers, whereas more recent models adopt end-to-end learning strategies that operate directly on raw physiological signals. Convolutional and recurrent architectures have proven particularly effective in capturing the spectral and temporal characteristics of sleep macro-architecture.
Representative examples include DeepSleepNet [
2], which combines convolutional layers with bidirectional recurrent modules to model both local patterns and long-range temporal dependencies in EEG signals. Similarly, Chambon et al. [
3] proposed a multimodal convolutional architecture that jointly processes EEG, EOG, and EMG channels, achieving robust performance without manual feature engineering. Subsequent works extended these ideas by explicitly modeling temporal context across multiple epochs. Sequence-based models such as SeqSleepNet [
7], as well as attention-driven architectures such as AttnSleep [
8] and Transformer-based approaches [
9], demonstrated that long-range temporal dependencies are particularly important for discriminating minority and transitional stages such as N1 and REM.
Despite their strong performance, most sleep-staging models are trained in fully centralized settings, assuming that raw PSG data from multiple subjects or institutions can be pooled into a single repository. In real-world healthcare environments, this assumption is often unrealistic. Clinical data are intrinsically distributed across hospitals, laboratories, and personal devices, and their sharing is constrained by privacy regulations, ethical considerations, and data-governance policies. As a result, centralized training paradigms may not reflect deployment conditions in digital health systems.
Federated learning (FL) was introduced to address these limitations by enabling collaborative model training without transferring raw data [
4]. In the FL paradigm, clients perform local optimization on private data and share only model parameters with a coordinating server. FL has been successfully applied in several healthcare domains, particularly in medical imaging, where multi-institutional collaborations can achieve near-centralized performance under sufficiently homogeneous data distributions [
5,
6]. However, the effectiveness of FL critically depends on the statistical properties of client data. Biomedical time-series data, and PSG signals in particular, pose severe challenges for federated optimization. Physiological signals are strongly non-independent and non-identically distributed (non-IID): inter-subject variability, sensor placement, recording conditions, and pathological factors introduce systematic heterogeneity. Li et al. [
10] formalized the impact of such heterogeneity, showing that inconsistent local objectives can lead to client drift and unstable convergence. Karimireddy et al. [
11] and Reddi et al. [
12] further demonstrated that naive aggregation strategies such as FedAvg may converge to suboptimal or degenerate solutions even on balanced benchmarks, unless corrective mechanisms are introduced.
Only a limited number of studies have explored federated or decentralized learning for sleep-stage classification. Anido-Alonso and Alvarez-Estevez [
13] proposed decentralized privacy-preserving deep learning approaches to improve inter-database generalization, highlighting the feasibility of distributed sleep-staging pipelines. More recently, Ma et al. [
14] introduced a federated semi-supervised framework for sleep staging, while Salanitro et al. [
15] investigated the transition from manual to automated sleep scoring using FL. These works confirm the relevance of FL for sleep analytics, but they also indicate sensitivity to data heterogeneity and stage imbalance.
Beyond optimization-level solutions, several federated learning methods explicitly address feature-distribution heterogeneity. FedBN [
16] preserves batch-normalization statistics locally while aggregating the remaining parameters, showing improved stability under non-IID feature distributions. Other approaches introduce personalization layers or meta-learning strategies [
17,
18], acknowledging that a single fully shared model may be insufficient in heterogeneous populations. These methods suggest that partial decoupling between global and client-specific components can mitigate the adverse effects of non-IID data.
Recent federated learning literature has further emphasized these issues in applied information systems. Surveys and empirical studies highlight that physiological heterogeneity, rather than data scarcity, is the dominant obstacle to stable federated convergence in healthcare [
19,
20]. Consistently, several MDPI publications from 2024 to 2025 address heterogeneity-aware and privacy-preserving FL deployments. Lin and Wen [
21] propose edge federated optimization strategies tailored to heterogeneous data distributions. Deshmukh et al. [
22] analyze FL in IoT-enabled digital infrastructures, focusing on privacy and governance constraints. Personalization mechanisms are explored by Ye et al. [
23], while Lin et al. [
24] apply federated learning to multimodal physiological analysis for sleep-disordered breathing. Elshenawy et al. [
25] provide a recent comparative evaluation of FL variants in a multi-class clinical classification task. In contrast to most existing work, this study adopts a strict one subject = one client configuration, which reflects realistic sleep-monitoring deployments but exacerbates physiological non-IIDness. Moreover, we maintain full architectural and optimization parity between centralized and federated experiments. This design isolates the effect of federated aggregation strategies, allowing us to attribute performance degradation to data heterogeneity rather than to model capacity or training asymmetries. As shown in
Section 5, naive aggregation methods are insufficient under these conditions, while normalization-preserving federation (FedBN) provides minimal yet effective mitigation.
3. Materials and Methods
3.1. Dataset Description and Clinical Subgroups
We use the ISRUC-Sleep database, which contains overnight polysomnography (PSG) recordings acquired from three clinically distinct cohorts [
1]. ISRUC-Sleep consists of 100 subjects in Subgroup I, 30 in Subgroup II, and 8 in Subgroup III, as reported in the original publication. However, only 77/27/10 subjects provide complete PSG+manual scoring records suitable for supervised training. We use these 114 subjects in all experiments. Missing or incomplete records were excluded only if epoch labels or PSG channels were unavailable. The dataset comprises a total of 114 subjects, partitioned into the following subgroups:
Subgroup 1 (n = 77): subjects without major diagnosed sleep disorders, used in several sleep classification studies as a de facto “healthy” or low-pathology reference.
Subgroup 2 (n = 27): patients presenting moderate sleep disturbances or comorbidities such as airflow limitation or fragmented EEG architecture.
Subgroup 3 (n = 10): subjects with severe pathological sleep profiles, characterized by markedly reduced REM and irregular stage transitions.
The three subgroups exhibit highly divergent stage distributions. In particular, Subgroup 2 and Subgroup 3 display significant REM under-representation and larger fluctuations in N1 duration, increasing the non-IID nature of subject-level data. These properties are not treated as noise but as clinically relevant signal sources. We intentionally restrict the centralized baseline to Subgroup I to avoid uncontrolled cross-subgroup harmonization that would artificially improve performance.
3.2. Data Preprocessing
For each subject, three PSG channels were extracted: EEG (Fpz–Cz), horizontal EOG, and chin EMG. Signals were resampled to 100 Hz and segmented into 30 s non-overlapping epochs following AASM scoring codes. Epochs that were labeled as movement or undefined were discarded. Stage labels were consolidated into the five canonical classes: Wake (W), N1, N2, N3, and REM. Each subject’s channels were normalized using per-subject
z-score statistics to preserve local physiological amplitude baselines:
where
are the mean and standard deviation computed over all epochs of subject
s.
To avoid data leakage across clients, subjects were split at the participant level, not at the epoch level. We used a subject-level partition of 70/15/15% for training, validation, and testing. No subject appeared in more than one split.
3.3. Federated Learning Setup
Each ISRUC subject is treated as a single federated client (one subject = one client). Only model parameters are exchanged; no raw PSG data leave the local node. Synchronization proceeds in communication rounds. In each round, K clients are sampled without replacement, perform one local training epoch, and return model parameters. The server aggregates parameters according to the selected federation algorithm.
We evaluate three federated strategies:
- 1.
FedAvg [
4]: weighted average of local model parameters using client data size.
- 2.
FedProx [
10]: adds a proximal term to local losses to limit update drift.
- 3.
FedBN [
16]: aggregates all model parameters except batch normalization statistics, which remain client-specific.
FedAvg is the canonical baseline and aggregates client models by a sample-size weighted average; it assumes that local objectives are sufficiently aligned, which is often violated under subject-level physiological non-IIDness. FedProx modifies the local objective by adding a proximal term that penalizes deviation from the current global model, thereby reducing client drift when local updates point in inconsistent directions; it is therefore a stability-oriented extension of FedAvg under heterogeneous clients. FedBN targets feature-distribution heterogeneity by keeping batch-normalization statistics local to each client, while aggregating the remaining parameters; this decouples subject-specific feature scaling (client-local) from the shared classifier (global), and is particularly suitable when covariate shift dominates.
Federated Training Loop (Algorithmic Specification)
For clarity, the subject-level FL procedure used in this study can be summarized as follows. At server round t, a subset of clients (subjects) is sampled uniformly without replacement. Each client performs one local epoch of optimization starting from the current global model parameters. The server then aggregates client updates into a new global model according to the federation strategy: (i) FedAvg averages parameters weighted by the number of local samples; (ii) FedProx optimizes a proximal-regularized local objective to reduce client drift; (iii) FedBN aggregates all parameters except batch-normalization statistics, which are kept local to each client. This design isolates the effect of aggregation and normalization under strong physiological non-IIDness.
Table 1 summarizes the subject-level federated learning procedure adopted in this study, highlighting the separation between local physiological processing and global parameter aggregation.
This setup explicitly accommodates subject-specific physiological variability while maintaining a unified global classifier.
3.4. Model Architecture and Hyperparameters
All settings share the same model architecture: a compact 1D–CNN composed of two convolutional blocks (kernel size = 7, ReLU activation, max pooling), followed by a fully connected layer and a softmax classifier over the five sleep stages. We deliberately avoid architecture changes to isolate the effect of the federation scheme.
Training used an Adam optimizer (), a batch size of 32, and local epochs of 1 per round. Federated experiments were run for 50 rounds, with sampled clients per round. Centralized training used a batch size of 64 and early stopping based on validation loss.
4. Experimental Setup
Federated experiments include the entire spectrum of ISRUC-Sleep subjects, ranging from regular sleep architecture to pathological cases. Each individual becomes a distinct client, preserving physiological variability as an intrinsic property of the training signal rather than homogenizing it at preprocessing time.
Figure 1 provides a schematic overview of the complete study pipeline, from subject-level data preprocessing to federated training and evaluation.
Figure 1 summarizes the end-to-end pipeline and explicitly distinguishes centralized and federated regimes. All PSG recordings undergo the same subject-level preprocessing (channel selection, 30 s epoching, and per-subject
z-score normalization) to prevent cross-subject information leakage through shared normalization statistics.
In the centralized baseline, only Subgroup I subjects are used for training/validation/ testing to provide a controlled reference cohort. In the federated setting, each subject is treated as an independent client. At each communication round t, the server broadcasts the current global model to a subset of sampled clients . Each selected client performs exactly one local training epoch using its own epochs and labels, and returns updated parameters (or equivalently a parameter delta) to the server. The server then aggregates client contributions according to the selected federation strategy (FedAvg, FedProx, or FedBN) to obtain .
Finally, evaluation is performed both globally (accuracy, macro-F1, confusion matrices) and at the client level (distribution of per-client accuracies), which is critical to quantify stability and fairness under subject-level physiological heterogeneity.
4.1. Hardware and Software Environment
All experiments were conducted on a local workstation equipped with a modern multi-core CPU and a single GPU. The training framework was implemented in Python 3.10 using PyTorch 1.13 for deep learning components and the Flower framework for federated orchestration. The latter provides client–server abstractions closely aligned with FL protocols and does not modify learning dynamics, allowing reproducible aggregation logic. No distributed cluster or multi-node deployment was used to avoid confounding hardware effects.
Although federated learning is commonly associated with mobile or wearable devices, the objective of this study is not to evaluate client-side inference latency or energy consumption. Instead, we focus on statistical performance and optimization behavior under non-IID partitioning. Edge constraints are reflected in architectural choices (lightweight 1D-CNN) rather than in direct measurement of resource consumption.
4.2. Training–Validation–Testing Protocol
For the centralized baseline, subjects from ISRUC-Sleep Subgroup I were split at the identity level (approximately 70% training, 15% validation, 15% testing). No subject appears across more than one split. This avoids artificially inflated performance due to intra-subject correlations and reflects deployment settings in which models are trained on a population and evaluated on unseen individuals. It is worth emphasizing that the centralized baseline is trained exclusively on Subgroup I, which exhibits relatively regular sleep architecture, whereas all federated learning experiments involve subjects from all three ISRUC-Sleep subgroups, thereby exposing the model to substantially higher physiological and distributional heterogeneity.
Within each subject, PSG recordings were segmented into non-overlapping 30 s epochs, resampled to 100 Hz, normalized through the per-subject z-score, and labeled according to the five-class taxonomy (W, N1, N2, N3, REM). Movement and unknown stages were discarded. The resulting dataset exhibits natural class imbalance, with N1 and REM under-represented. We intentionally refrained from oversampling or synthetic augmentation to avoid influencing federated dynamics: balancing techniques at the global level represent a form of cross-client knowledge sharing. For the centralized baseline, training was performed on a cohort characterized by stable stage proportions and regular sleep architecture. This setting provides a controlled environment widely used in prior sleep-scoring studies, ensuring that the model can learn canonical N2–N3 transitions and REM–N1 boundaries without cross-client heterogeneity. The resulting metrics represent an upper bound achievable when the model has access to clean population-level statistics.
4.3. Federated Training Protocol
In the federated setting, each subject corresponds to a distinct client, mirroring how home-monitoring devices, clinical repositories or institutional nodes would contribute in a distributed digital infrastructure. Local training uses the same architecture and loss functions as the centralized baseline, performed for exactly one local epoch per round with a batch size of 32. Only model weights and the number of local samples are transmitted to the server. No gradients, intermediate activations or raw PSG data leave the client.
Federated Averaging (FedAvg) is applied without proximal terms. Clients are sampled uniformly, with 10 subjects selected per communication round and 50 total rounds performed. No client prioritization, drift control, or clustering mechanisms are introduced. This configuration intentionally reflects a “first-generation” FL deployment and reveals the consequences of applying naive distributed optimization to highly non-IID biosignals.
Several alternative designs were considered and deliberately excluded. Learning multiple local epochs per round improves client fitting but exacerbates drift under heterogeneous datasets, potentially accelerating model collapse. Similarly, performing partial weight updates, applying adaptive server optimizers, or grouping subjects by diagnosis or spectral similarity would introduce implicit cross-client knowledge sharing and hide the contribution of non-IID distributions. Since the goal of this investigation is
not to optimize but to understand failure modes, these stabilization mechanisms are reserved for future work (
Section 6).
4.4. Performance Evaluation
We evaluate performance by assessing the following metrics at both the global and client level:
- 1.
Global accuracy and macro-F1, measuring model effectiveness across all stages.
- 2.
Per-stage F1, quantifying class-specific stability with emphasis on N1 and REM.
- 3.
Confusion matrices, revealing systematic misclassification patterns and degeneration modes.
- 4.
Client accuracy distributions, capturing fairness and cross-subject performance variability.
The last metric is crucial for healthcare: a model that performs well on average while repeatedly failing on specific patients is unsafe and unsuitable for clinical deployment. By analyzing the spread of client-level accuracies, we detect structural biases in training dynamics that cannot be inferred from global metrics alone. Unlike many federated studies, no notion of “macro-aggregation” is applied to client metrics. Each patient-level outcome is treated as an independent unit of analysis, reflecting the contextual responsibility of AI systems deployed in medical or public-health environments.
Given the subject-level non-IID setting and the deterministic nature of federated aggregation, classical statistical hypothesis testing across models is not straightforward. Instead of relying on p-values computed under independence assumptions, we focus on distributional analyses, including per-client accuracy distributions and confusion matrices. These metrics better reflect stability, fairness, and failure modes in federated biomedical systems, where patient-level performance is critical.
5. Results
5.1. Centralized Baseline
The centralized 1D–CNN serves as a reference point for assessing the intrinsic complexity of the sleep-staging task. When trained on pooled data, the model converges reliably, achieving an accuracy of and a macro-F1 score of on the held-out subject set. Per-class performance indicates a well-structured separation of sleep macro-architecture: F1 (Wake) = , F1 (N1) = , F1 (N2) = , F1 (N3) = , and F1 (REM) = .
The corresponding confusion matrix (
Figure 2) shows clear discrimination of Wake and deep sleep (N3), with bounded confusion among lighter stages, particularly between N1, N2, and REM. Although higher accuracies have been reported using complex sequence-based or transformer architectures, the performance achieved here should be interpreted in relation to the adopted modeling assumptions. The proposed 1D–CNN operates at single-epoch granularity, without recurrent connections, attention mechanisms, or explicit temporal-context aggregation across consecutive epochs. Under these constraints, an accuracy close to
and a macro-F1 above
are consistent with prior lightweight CNN-based approaches.
Importantly, the centralized baseline is not intended to represent a state-of-the-art sleep-staging system. Rather, it establishes a controlled architectural upper bound, demonstrating that the chosen model is sufficiently expressive when inter-subject heterogeneity is minimized. This ensures that the performance degradation observed under federated regimes cannot be attributed to insufficient model capacity.
5.2. Federated Learning with FedAvg
When the same architecture is trained under federated constraints, with one subject per client, performance deteriorates substantially. FedAvg reaches a final accuracy of and a macro-F1 score of . Minority stages are almost entirely suppressed: F1 (N1) = , F1 (REM) = , and F1 (N3) = .
The confusion matrix in
Figure 3 reveals an almost complete collapse toward dominant macro-states, primarily N2 and N3. While the centralized model captures transient dynamics and stage transitions, FedAvg effectively degenerates into a majority-class classifier. This behavior is also reflected in client-level outcomes: per-client accuracies exhibit high variance, with no consistent convergence trend across subjects.
Crucially, this degradation should not be interpreted as an implementation artifact. Rather, it reflects well-documented instability of naive parameter averaging under extreme subject-level non-IID conditions, where local optima are misaligned and global aggregation amplifies dominant patterns at the expense of minority sleep stages.
5.3. FedProx Stabilization
FedProx introduces a proximal regularization term to limit excessive client drift during local optimization. This yields a modest improvement over FedAvg: final accuracy increases to , while macro-F1 reaches . Deep sleep discrimination partially recovers, with F1 (N3) rising to . However, F1 (N1) remains at zero, and REM detection is still negligible (F1 (REM) = ).
The confusion matrix in
Figure 4 shows reduced extreme collapse compared to FedAvg, but stage boundaries remain poorly defined. Client-level accuracy distributions continue to display wide variability, indicating that FedProx primarily acts as a stabilization mechanism rather than a solution to physiological heterogeneity.
5.4. FedBN and Normalization Preservation
FedBN produces a qualitatively different outcome. By keeping batch-normalization statistics local to each client while aggregating the remaining parameters, the model preserves subject-specific physiological baselines and learns a shared classifier. This results in the strongest federated performance: accuracy = and macro-F1 = .
The per-class metrics improve accordingly (F1 (N1) = , F1 (N3) = ), and Wake detection is substantially more stable. REM remains challenging (F1 (REM) = ), reflecting both biological under-representation and the absence of temporal modeling.
The confusion matrix in
Figure 5 shows restored structure in N2 and N3 predictions, with reduced systematic collapse of REM into N2 relative to FedAvg and FedProx. Client-level performance further highlights this effect: as shown in
Figure 6, several clients exceed
accuracy, with one reaching
. This indicates that local normalization statistics encode critical subject-level priors that are not transferable across clients.
Despite these improvements, REM staging remains largely unresolved under all federated regimes. This limitation is consistent with prior findings showing that REM discrimination benefits from long-range temporal modeling across multiple epochs, as implemented in sequence-based and attention-driven architectures [
2,
7,
8,
9].
5.5. Comparison Across Training Regimes
Figure 7 highlights the contrasting convergence behaviors of FedAvg and FedBN. FedAvg fails to achieve stable convergence and oscillates around low accuracy values, while FedBN exhibits a consistent upward trend across communication rounds, reaching the highest final accuracy. FedProx, although not shown explicitly in the figure, converges to an intermediate and largely flat accuracy level (approximately 0.15), as confirmed by the final evaluation metrics reported in
Table 2. Together,
Figure 6 and
Figure 7 illustrate complementary aspects of federated learning behavior:
Figure 6 emphasizes client-level variability and fairness, while
Figure 7 focuses on global convergence dynamics across communication rounds.
Table 2 summarizes the final performance metrics across all training regimes. Overall, FedBN significantly mitigates catastrophic collapse and restores meaningful stage boundaries, without requiring architectural changes or explicit personalization.
6. Discussion
The experimental evidence collected across centralized and federated configurations provides a detailed perspective on how distributional heterogeneity affects the learning dynamics of sleep-stage classification models. In the centralized setting, the 1D–CNN converges to stable performance metrics (accuracy ), confirming that the architecture is expressive enough to capture temporal and frequency patterns from PSG signals when trained on a unified dataset. However, when the same model is deployed under federated constraints, performance degradation becomes immediately evident. This deterioration is not primarily an architectural limitation, but a systemic effect arising from extreme non-IID distributions at the subject level.
From a clinical perspective, the centralized accuracy reported in this study should not be interpreted as sufficient for diagnostic deployment. Clinical-grade sleep staging systems typically rely on richer temporal modeling, expert-calibrated post-processing, and extensive cross-dataset validation. In this work, the centralized model serves a methodological purpose: it establishes that a compact CNN can learn meaningful sleep representations when inter-subject variability is suppressed. The subsequent federated experiments intentionally remove this assumption, revealing how performance degrades when realistic physiological heterogeneity is preserved.
Sleep physiology is intrinsically heterogeneous and strongly dependent on individual micro-architectures. Factors such as age, chronotype, respiratory instability, medication exposure, and pathological conditions modulate the morphology of EEG and EMG traces. In the ISRUC-Sleep dataset, this heterogeneity manifests as follows: (i) covariate shift—differences in amplitude, noise and artifact prevalence across subjects; (ii) label shift—uneven distribution of sleep stages, including the frequent under-representation of REM or N1 in specific individuals. A third contributing factor is the limited temporal context of the adopted lightweight 1D-CNN, which operates at single-epoch granularity. REM staging often depends on transition dynamics and multi-epoch patterns; under FL, such information is further fragmented across clients and exacerbated by label scarcity. Therefore, low REM performance under federated regimes is consistent with a combined effect of label under-representation and insufficient temporal modeling. This motivates future extensions with sequence-level encoders (e.g., attention modules) and/or subject-level personalization.
Classical federated algorithms, such as FedAvg, implicitly assume that global aggregation preserves generalizable representations across clients. Under biomedical conditions, this assumption is structurally violated. Local optimizers tend to overfit to each subject’s dominant class distribution, and when parameters are averaged globally, minority stages collapse into majority ones.
This phenomenon is clearly visible in the confusion matrix of FedAvg: the model tends to predict N2 or N3 even when the true label is REM or N1, effectively discarding subtle neurophysiological transitions. FedProx partially mitigates this divergence by penalizing excessively sharp local parameter updates, resulting in a moderate gain in test accuracy. However, it does not address the core mismatch: clients attempt to force a shared representation over fundamentally different physiological domains. The resulting model prioritizes coarse sleep macro-states while failing to express finer structure.
A substantially different behavior emerges with FedBN. By decoupling batch normalization statistics and allowing each client to maintain its local normalization parameters, FedBN reframes the learning problem: feature statistics are personal, while classification weights remain global. The gains are significant: overall accuracy rises to , with visible improvements in N2 and N3 detection. Unlike FedAvg and FedProx, FedBN avoids universal collapse toward dominant classes and preserves client-level variability in a controlled form. Several clients achieve accuracy above , and some approach , despite severe label imbalance. This emergent stability suggests that local normalization acts as a proxy for subject-specific physiological priors, capturing individual spectral baselines that are not transferable across the federation.
The contrast between the centralized and federated regimes should not be interpreted as a model capacity limitation. The centralized cohort reflects a laboratory-like scenario in which spectral transitions are well-formed, whereas the federated setup captures real deployment conditions where sleep architecture is irregular and often clinically altered. These distributions cannot be homogenized without compromising the representativeness of the population.
From an Information Systems viewpoint, this observation has broader implications. Federated biomedical infrastructures are not simply distributed computational pipelines: they are socio-technical ecosystems where privacy, local governance, and population-level analytics must coexist. Unlike standard computer vision or NLP tasks, biomedical signals are not merely noisy instances of a shared statistical manifold. In sleep scoring, variance is a core part of the information structure. Federated learning must therefore mediate heterogeneity, not eliminate it. FedBN demonstrates that meaningful mediation is possible without exposing raw PSG data and without undermining client-side privacy guarantees. Such properties align well with real healthcare architectures, including multi-center sleep laboratories, telemedicine services, and national digitization programs, where sovereignty of clinical data is non-negotiable.
7. Conclusions
This study provides a realistic evaluation of federated deep learning methods for automatic sleep-stage classification, using ISRUC-Sleep as a representative benchmark. While the centralized baseline confirms the effectiveness of lightweight 1D–CNN architectures, naive federated aggregation methods such as FedAvg suffer a substantial loss in predictive performance under non-IID subject-level distributions. FedProx partially improves stability, yet fails to solve the structural mismatch between global aggregation and subject-specific physiological variability. Conversely, FedBN introduces a minimal but crucial relaxation of this assumption: it preserves local normalization statistics, allowing clients to retain their physiological baselines while still contributing to a shared model.
The empirical gains of FedBN do not arise from architectural complexity, but from a more faithful interpretation of the sleep domain. Sleep micro-architecture cannot be reduced to a single universal template. Instead, sleep-stage transitions emerge through individualized spectral expressions that vary across subjects, devices, and episodes. By respecting this variability, FedBN achieves stronger generalization without compromising privacy.
From an applied perspective, these findings highlight a practical pathway for integrating federated models into healthcare information systems. Local PSG recordings remain on-site, and only model weights are exchanged, which aligns with the regulatory constraints of modern digital health ecosystems. Importantly, this approach does not require personalization servers, patient identity tracking, or cross-client data pooling. It scales naturally to hospital networks, wearable monitoring, and national data infrastructures such as those promoted within European digitalization initiatives.
Future research should extend these results along three directions. First, longitudinal evaluations are needed to understand how federated models behave under temporal drift, medication changes, or disease progression. Second, multi-modal architectures that combine EEG, EOG, and EMG may benefit from local normalization even more strongly than single-channel models. Third, clinical deployment requires robustness to connectivity loss, partial participation, and heterogeneous edge hardware. Addressing these aspects is fundamental to transforming federated learning from a research paradigm into a viable foundation for distributed sleep analytics.
In summary, effective federated learning in biomedicine does not rely on enforcing homogeneity across clients. It relies on learning to accommodate physiological diversity. FedBN provides a concrete demonstration of this principle, and represents a promising direction for privacy-preserving sleep analysis within edge–cloud healthcare systems.