Demographic-Aware Self-Supervised Anomaly Detection Pretraining for Equitable Rare Cardiac Diagnosis

arXiv cs.CV / 3/23/2026

💬 OpinionSignals & Early TrendsModels & Research

Key Points

  • The paper proposes a demographic-aware self-supervised anomaly detection framework for ECGs to improve detection of rare cardiac anomalies while ensuring equity across diverse populations.
  • In the first stage, self-supervised pretraining reconstructs masked ECG signals, models signal trends, and predicts patient attributes to learn robust representations without diagnostic labels.
  • In the second stage, the model is fine-tuned for multi-label ECG classification using asymmetric loss to handle long-tail abnormalities and it also provides anomaly score maps for localization with CPU-based deployment optimization.
  • Evaluations on a cohort of over one million ECGs show an AUROC of 94.7% for rare anomalies and a 73% reduction in the common-rare performance gap, with consistent accuracy across age and sex groups.

Abstract

Rare cardiac anomalies are difficult to detect from electrocardiograms (ECGs) due to their long-tailed distribution with extremely limited case counts and demographic disparities in diagnostic performance. These limitations contribute to delayed recognition and uneven quality of care, creating an urgent need for a generalizable framework that enhances sensitivity while ensuring equity across diverse populations. In this study, we developed an AI-assisted two-stage ECG framework integrating self-supervised anomaly detection with demographic-aware representation learning. The first stage performs self-supervised anomaly detection pretraining by reconstructing masked global and local ECG signals, modeling signal trends, and predicting patient attributes to learn robust ECG representations without diagnostic labels. The pretrained model is then fine-tuned for multi-label ECG classification using asymmetric loss to better handle long-tail cardiac abnormalities, and additionally produces anomaly score maps for localization, with CPU-based optimization enabling practical deployment. Evaluated on a longitudinal cohort of over one million clinical ECGs, our method achieves an AUROC of 94.7% for rare anomalies and reduces the common-rare performance gap by 73%, while maintaining consistent diagnostic accuracy across age and sex groups. In conclusion, the proposed equity-aware AI framework demonstrates strong clinical utility, interpretable anomaly localization, and scalable performance across multiple cohorts, highlighting its potential to mitigate diagnostic disparities and advance equitable anomaly detection in biomedical signals and digital health. Source code is available at https://github.com/MediaBrain-SJTU/Rare-ECG.