TransECG-SSL: Hybrid Self-Supervised Representation Learning for ECG Arrhythmia Classification

Ahtisham Ayyub, Fasih Haider, Muhammad Rehan Usman, Saturnino Luz, Christos Politis +1 more
10/26/2026
cs.LG
transformer-attentioncontrastive-ssl

No confident code implementation found for this paper.

Abstract

Cross-dataset generalisation remains a major challenge for automated electrocardiogram (ECG) arrhythmia classification because of differences in patient populations, acquisition protocols, annotation practices, and class distributions. Learning representations that remain informative across independent datasets could reduce reliance on dataset-specific labelled data.

Show full abstract

We propose TransECG-SSL, a self-supervised framework for transferable heartbeat representation learning from unlabelled ECG data. A Transformer encoder is pretrained using a hybrid objective combining masked signal reconstruction and contrastive learning, then frozen and evaluated by linear probing under patient-disjoint evaluation. Experiments across three public ECG databases and seven source--target settings show that Hybrid SSL consistently outperforms randomly initialised Transformers and achieves higher balanced accuracy than architecture-matched source-supervised pretraining. Reconstruction-only SSL remains competitive with Hybrid SSL, whereas contrastive-only pretraining performs substantially worse, highlighting the importance of masked reconstruction for transferability. Cross-dataset transfer nevertheless reduces balanced accuracy relative to target-specific self-supervised pretraining, while minority arrhythmia classes remain challenging under severe class imbalance. These findings demonstrate the potential of label-efficient self-supervised learning for cross-dataset ECG representation transfer while highlighting persistent limitations from domain shift and class imbalance.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{ayyub2026transecgssl,
  title  = {TransECG-SSL: Hybrid Self-Supervised Representation Learning for ECG Arrhythmia Classification},
  author = {Ahtisham Ayyub and Fasih Haider and Muhammad Rehan Usman and Saturnino Luz and Christos Politis and Muhammad Arslan Usman},
  year   = {2026},
  eprint = {2610.35378},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2610.35378v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2610.35378.svg)](https://codeofpaper.com/paper/2610.35378)

Discussion