Introduction
Deep learning has revolutionized the analysis of biosignals such as electroencephalograms (EEG) and electrocardiograms (ECG). However, two significant challenges hinder the widespread deployment of these models: the difficulty of defining meaningful data augmentations for complex time-series and the inconsistency of sensor configurations across different clinical studies. This paper introduces Contrastive Random Lead Coding (CRLC), a novel self-supervised learning (SSL) framework designed to create "channel-agnostic" models that can seamlessly adapt to varying electrode setups.
Problem Statement
Traditional contrastive learning relies on artificial augmentations (e.g., cropping, flipping) to create multiple "views" of the same data point. For physiological signals, it is often unclear which augmentations preserve the underlying biological meaning. Furthermore, most state-of-the-art models are architecturaly locked to a fixed number of input channels. A model trained on a standard 12-lead ECG setup typically cannot be used on a 3-lead wearable device without significant data loss or inefficient zero-padding.
Methodology
Channel-Agnostic Architecture
The authors propose a flexible backbone consisting of a shared convolutional encoder ($H_\theta$) applied to each channel independently. The resulting representations ($h^c$) are then processed by a Message Passing Neural Network (MPNN). By treating each channel as a node in a fully connected graph and using permutation-invariant aggregation, the model remains functional regardless of the number of input channels.
Contrastive Random Lead Coding (CRLC)
The core innovation, CRLC, leverages the inherent multi-view nature of biosignals. Since different sensors (leads) record the same underlying physiological source from different spatial locations, subsets of channels can serve as natural positive pairs. In the CRLC framework, a single time window is split into two random subsets of channels. The model is then trained to recognize that these different sets of leads represent the same physiological event.
Experimental Results
The study evaluated CRLC on both synthetic data and real-world datasets for sleep staging (EEG) and cardiac diagnosis (ECG):
- EEG Superiority: On the SleepEDFx dataset, CRLC achieved 73.0% accuracy, significantly outperforming the state-of-the-art BENDR model (62.6%).
- Generalization: A model pretrained on only 6 EEG channels successfully scaled to a 20-channel dataset, reaching 81.1% accuracy without architectural changes.
- Efficiency: The MPNN-based model is highly parameter-efficient, utilizing approximately 59,000 parameters, compared to the millions of parameters found in transformer-based reference models.
Conclusion
Contrastive Random Lead Coding provides a robust and efficient solution for self-supervised learning in biosignals. By treating channels as natural views, CRLC bypasses the need for artificial augmentations and enables the development of truly channel-agnostic models. Future work will explore incorporating spatial information into the MPNN graph to further enhance performance by accounting for the physical proximity of sensors.
Summary updated