ECG-FM: An Open Electrocardiogram Foundation Model
About
Conventional task-specific electrocardiogram (ECG) analysis models require large annotated datasets to train. Foundation models mitigate this burden by leveraging self-supervised pretraining; however, the scarcity of open-weight ECG foundation models hinders adoption and cross-study comparability. We present ECG-FM, an open foundation model for ECG analysis, and conduct a study using a dataset of 1.5 million ECGs. ECG-FM is a transformer-based model pretrained using a hybrid contrastive and generative self-supervised learning approach. Our downstream tasks include predicting reduced left ventricular ejection fraction (LVEF) and ECG interpretation labels, where we release a benchmark task on the MIMIC-IV-ECG dataset. We affirm that ECG-FM is robust, label-efficient, and functionally discriminative by showcasing data scaling experiments, performing a latent space analysis, and generating saliency maps. ECG-FM markedly outperforms task-specific models in the small-to-medium-scale data regime and demonstrates cross-dataset generalizability, achieving high AUROC on many clinically salient labels such as atrial fibrillation (0.996) and LVEF<=40% (0.929). We release our code, model weights, and benchmark task at https://github.com/bowang-lab/ECG-FM/.
Related benchmarks
| Task | Dataset | Result | Rank | |
|---|---|---|---|---|
| ECG Classification | PTBXL Super | Macro AUC85.9 | 136 | |
| ECG Classification | CSN | Macro AUC88.7 | 51 | |
| ECG Classification | CPSC 2018 | AUC94.7 | 32 | |
| ECG Classification | PTB-XL | AUROC83.87 | 26 | |
| ECG Classification | CPSC | AUC0.9055 | 24 | |
| ECG Classification | PTB-XL Form | AUC78.19 | 17 | |
| LVEF < 40% prediction | MIMIC All (test) | Balanced Accuracy70.7 | 13 | |
| Age Estimation | ECG (test) | MAE13.49 | 12 | |
| ECHO-related classification | MUSIC (test) | LVEF < 40% Classification64.8 | 12 | |
| RR Interval Estimation | ECG (test) | MAE (ms)147.3 | 12 |