Hierarchical Graph Representation Learning for ECG Classification with Cross-Dataset Generalization
In this research, we propose a graph-based approach to classify ECG signals. We model the ECG signal as a time-varying graph and examine its dynamics at two levels: intra-beat and inter-beat. The proposed framework employs a two-level graph representation of the ECG. At the intra-beat level, each beat is modeled as a graph in which the P, Q, R, S, and T waves serve as nodes, and temporal distance information is incorporated into the node feature vector. At the inter-beat level, the ECG signal is represented as a graph of beats. We investigated two node representations: learnable MLP embeddings derived from handcrafted features and reduced features obtained via PCA. Unlike conventional temporal GCNs, graph attention networks (GATs), and transformers, which predominantly rely on single-level representations of ECG signals, the proposed approach builds hierarchical graph structures directly from ECG signals. The dual model was trained on 1024 ECG segments from the PTB Diagnostic ECG Database (PTBDB) and tested on 398 ECG segments from the MIT-BIH Arrhythmia Database to evaluate its performance. The results indicate that the best-performing configuration, which employs PCA-reduced node features, outperforms the other configurations tested. The model achieves a mean accuracy of 97.67% and a mean F1-score of 97.18% over five runs.
Authors
- Basela Hasan
- Eman Omar (ORCID: https://orcid.org/0009-0003-3828-6040)
- Eman Alsaidi
Institutions
- Hashemite University (JO)
- Al-Balqa Applied University (JO)
- Arab Open University (JO)
Publication Details
- Journal
- Computers
- Published
- 2026-08-21
- DOI
- https://doi.org/10.3390/computers15080546
- Primary Topic
- ECG Monitoring and Analysis
- Type
- article
- Field-Weighted Citation Impact
- 0.00