CoRe-ECG: Advancing Self-Supervised Representation Learning for 12-Lead ECG via Contrastive and Reconstructive Synergy

Zehao Qin, Xiaojian Lin, Ping Zhang, Hongliang Wu, Xinkang Wang, Guangling Liu, Bo Chen, Wenming Yang, Guijin WangarXiv 2026

TL;DR

CoRe-ECG introduces a unified self-supervised learning framework for 12-lead ECGs that harmonizes contrastive (global semantic) and reconstructive (local structural) pretraining. By incorporating domain-specific frequency augmentations and a novel spatio-temporal masking strategy, it prevents models from exploiting trivial data shortcuts and achieves state-of-the-art performance on downstream cardiac classification tasks.

What Problem Does This Paper Address?

Electrocardiograms (ECGs) are the gold standard for non-invasive cardiac disease diagnosis. However, training robust deep learning models for automated ECG interpretation is bottlenecked by severe label scarcity; annotating ECGs requires specialized, costly expertise from cardiologists.

While self-supervised learning (SSL) offers a way to utilize massive unlabeled datasets, existing methods typically split into two isolated camps: contrastive learning (which aligns global views of data) and reconstructive learning (which masks and recovers local signal patches). Using either approach in isolation limits the diversity of the supervisory signal. Furthermore, directly applying generic time-series SSL methods to ECGs introduces severe flaws:

  1. Physiological Distortion: Naive time-domain augmentations (like cropping or shuffling) can disrupt intrinsic cardiac rhythms and distort clinically meaningful waveform patterns.
  2. Architectural Shortcuts: Standard random masking fails in multi-lead ECGs because of strong inter-lead correlations governed by physical laws (e.g., Einthoven’s Law, where Lead I + Lead III = Lead II). Models can easily "cheat" the reconstruction task using simple linear combinations of visible leads without learning actual physiological features.

Methods

The authors propose CoRe-ECG, a unified pretraining paradigm consisting of two parallel branches: a Contrastive Branch and a Reconstructive Branch.

Conceptual comparison of Contrastive, Reconstructive, and CoRe Learning paradigms.

To overcome the unique challenges of ECG signals, the framework introduces two key components:

  • Spatio-Temporal Dual Masking (STDM): To break inter-lead linear dependencies, STDM hierarchically alternates between a full temporal mask (forcing the model to rely on long-range temporal context) and a partial mask with lead drop (stochastically dropping candidate leads to force cross-lead, non-linear reconstruction).
  • Frequency Dynamic Augmentation (FDA): Instead of distorting waveforms in the time domain, FDA applies a Fast Fourier Transform (FFT) and utilizes a learnable weight matrix to map frequency importance. It protects critical diagnostic bands (typically 0.65–40 Hz) from perturbation while adaptively injecting noise into less informative frequencies before transforming the signal back via inverse FFT (iFFT).

During pretraining, a student encoder processes the masked patches to perform local waveform reconstruction, while a momentum-updated teacher encoder processes the fully augmented FDA view to provide a global semantic target. The entire architecture is optimized end-to-end using a combined loss function ($L = \alpha \cdot L_{rec} + \beta \cdot L_{con}$).

Figure 2: Overview of the CoRe-ECG architecture, which consists of two parallel branches: the Contrastive

Datasets

  • Pretraining: MIMIC-IV-ECG, a massive public dataset containing approximately 800,000 12-lead ECG recordings from nearly 160,000 patients.
  • Downstream Evaluation:
    • PTB-XL: 21,837 12-lead records across 5 diagnostic classes.
  • ICBEB2018: Over 6,000 12-lead records across 9 diagnostic classes.
  • Ningbo: 34,905 multi-label ECG recordings spanning 25 categories.

Key Insights and Ideas

  • The Synergy Principle: Global semantic alignment and local structural recovery mutually reinforce each other. Injecting instance-level discriminative signals directly into the reconstruction process guides finer local waveform recovery.
  • Masking Must Account for Physics: Random masking is insufficient for multi-lead physical sensors. By explicitly designing a masking strategy (STDM) that counters known physical relationships like Einthoven's law, the model is forced to learn genuine electrophysiological features rather than simple linear interpolation.
  • Adaptive Frequency Perturbation: Not all frequencies in a biological signal are created equal. Protecting high-energy, diagnostically relevant frequency bands while diversifying background noise profiles yields highly robust and transferable representations.

Key Results

CoRe-ECG consistently outperformed competitive self-supervised baselines (such as MoCo v3, MTAE, and ST-MEM) across all evaluated datasets:

  • Classification Performance: On the PTB-XL dataset, CoRe-ECG achieved an F1-score of 69.5% and an AUROC of 94.2%, marking a 6.1% F1 improvement over the reconstructive baseline ST-MEM.
  • Data Efficiency: In data-scarce scenarios, fine-tuning CoRe-ECG on just 50% of the training data yielded results comparable to or exceeding baseline models trained on 100% of the data. Even at an extreme 5% data ratio, it maintained a competitive 88.1% AUROC on PTB-XL.
  • Robustness to Lead Reduction: When evaluated on reduced lead configurations (simulating wearable devices), CoRe-ECG limited performance drops significantly. In a single-lead setup (Lead I), it still retained substantial discriminative capability, achieving an AUROC of 82.4% on PTB-XL and 88.7% on Ningbo.

Limitations and Future Work

Not discussed in the paper.

Summary updated

BibTeX
@misc{qin2026core,
  author = {Zehao Qin and Xiaojian Lin and Ping Zhang and Hongliang Wu and Xinkang Wang and Guangling Liu and Bo Chen and Wenming Yang and Guijin Wang},
  title = {{CoRe-ECG: Advancing Self-Supervised Representation Learning for 12-Lead ECG via Contrastive and Reconstructive Synergy}},
  year = {2026},
  eprint = {2604.11359},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2604.11359},
}
Figure