Skip to main page content
U.S. flag

An official website of the United States government

Dot gov

The .gov means it’s official.
Federal government websites often end in .gov or .mil. Before sharing sensitive information, make sure you’re on a federal government site.

Https

The site is secure.
The https:// ensures that you are connecting to the official website and that any information you provide is encrypted and transmitted securely.

Access keys NCBI Homepage MyNCBI Homepage Main Content Main Navigation
[Preprint]. 2025 Mar 5:2025.03.02.25322575.
doi: 10.1101/2025.03.02.25322575.

Foundation models for generalizable electrocardiogram interpretation: comparison of supervised and self-supervised electrocardiogram foundation models

Affiliations

Foundation models for generalizable electrocardiogram interpretation: comparison of supervised and self-supervised electrocardiogram foundation models

Alexis Nolin-Lapalme et al. medRxiv. .

Abstract

Background: The 12-lead electrocardiogram (ECG) remains a cornerstone of cardiac diagnostics, yet existing artificial intelligence (AI) solutions for automated interpretation often lack generalizability, remain closed-source, and are primarily trained using supervised learning, limiting their adaptability across diverse clinical settings. To address these challenges, we developed and compared two open-source foundational ECG models: DeepECG-SSL, a self-supervised learning model, and DeepECG-SL, a supervised learning model.

Methods: Both models were trained on over 1 million ECGs using a standardized preprocessing pipeline and automated free-text extraction from ECG reports to predict 77 cardiac conditions. DeepECG-SSL was pretrained using self-supervised contrastive learning and masked lead modeling. The models were evaluated on six multilingual private healthcare systems and four public datasets for ECG interpretation across 77 diagnostic categories. Fairness analyses assessed disparities in performance across age and sex groups, while also investigating fairness and resource utilization.

Results: DeepECG-SSL achieved AUROCs of 0.990 (95%CI 0.990, 0.990) on internal dataset, 0.981 (95%CI 0.981, 0.981) on external public datasets, and 0.983 (95%CI 0.983, 0.983) on external private datasets, while DeepECG-SL demonstrated AUROCs of 0.992 (95%CI 0.992, 0.992), 0.980 (95%CI 0.980, 0.980) and 0.983 (95%CI 0.983, 0.983) respectively. Fairness analyses revealed minimal disparities (true positive rate & false positive rate difference<0.010) across age and sex groups. Digital biomarker prediction (Long QT syndrome (LQTS) classification, 5-year atrial fibrillation prediction and left ventricular ejection fraction (LVEF) classification) with limited labeled data, DeepECG-SSL outperformed DeepECG-SL in predicting 5-year atrial fibrillation risk (N=132,050; AUROC 0.742 vs. 0.720; Δ=0.022; P<0.001), identifying reduced LVEF ≤40% (N=25,252; 0.928 vs. 0.900; Δ=0.028; P<0.001), and classifying LQTS syndrome subtypes (N=127; 0.931 vs. 0.853; Δ=0.078; P=0.026).

Conclusion: By releasing model weights, preprocessing tools, and validation code, we aim to support robust, data-efficient AI diagnostics across diverse clinical environments. This study establishes self-supervised learning as a promising paradigm for ECG analysis, particularly in settings with limited annotated data, enhancing accessibility, generalizability, and fairness in AI-driven cardiac diagnostics.

Keywords: Artificial intelligence; Electrocardiogram; Fairness; Foundation model; Generalizability; Privacy.

PubMed Disclaimer

Figures

Figure 1.
Figure 1.. An overview of DeepECG-SL and DeepECG-SSL performances.
We report overall AUROC and P-value computed using the DeLong Test. A Overall AUROC of ECG interpretation across all datasets. B AUROC of ECG interpretation categories on MHI-ds, EPD and EHC. C. AUROC of ECG interpretation categories on MHI-ds, EPD and EHC.D AUROC of digital biomarkers across datasets. iAF5 is at ECG level Abbreviations: CSH (Cedars Sinai Hospital Dataset), CLSA (Canadian Longitudinal Study on Aging Dataset), ECG (Electrocardiogram), EHC (External Health Centers Dataset), EPD (External Public Dataset), JGH (Jewish General Hospital Dataset), LQTS (Long QT Syndrome), LVEF (Left Ventricular Ejection Fraction), MGH (Massachusetts General Hospital Dataset), MHI (Montreal Heart Institute Dataset), MIMIC-IV (Medical Information Mart for Intensive Care IV Dataset), NYP (New York-Presbyterian Hospital Dataset), PTB (Physikalisch-Technische Bundesanstalt Dataset), UKB (UK Biobank Dataset), UCSF (University of California San Francisco Medical Center Dataset), UW (University of Washington Medical Center), CHUM (Centre hospitalier de l’Université de Montréal), and WCR (Wave2Vec + Contrastive Multi-segment Coding + Random Lead Masking).

References

    1. Holst H., Ohlsson M., Peterson C. & Edenbrandt L. A confident decision support system for interpreting electrocardiograms. Clin. Physiol. 19, 410–418 (1999). - PubMed
    1. Martínez-Sellés M. & Marina-Breysse M. Current and Future Use of Artificial Intelligence in Electrocardiography. JCDD 10, 175 (2023). - PMC - PubMed
    1. Hannun A. Y. et al. Cardiologist-level arrhythmia detection and classification in ambulatory electrocardiograms using a deep neural network. Nat Med 25, 65–69 (2019). - PMC - PubMed
    1. Yao X. et al. Artificial intelligence–enabled electrocardiograms for identification of patients with low ejection fraction: a pragmatic, randomized clinical trial. Nat Med 27, 815–819 (2021). - PubMed
    1. Aras M. A. et al. Electrocardiogram Detection of Pulmonary Hypertension Using Deep Learning. J. Card. Fail. 29, 1017–1028 (2023). - PMC - PubMed

Publication types

LinkOut - more resources