Papers
Topics
Authors
Recent
Search
2000 character limit reached

ECG-Lens: Benchmarking ML & DL Models on PTB-XL Dataset

Published 17 Apr 2026 in cs.LG, cs.AI, cs.CE, cs.NE, and eess.SP | (2604.15822v1)

Abstract: Automated classification of electrocardiogram (ECG) signals is a useful tool for diagnosing and monitoring cardiovascular diseases. This study compares three traditional machine learning algorithms (Decision Tree Classifier, Random Forest Classifier, and Logistic Regression) and three deep learning models (Simple Convolutional Neural Network (CNN), Long Short-Term Memory (LSTM), and Complex CNN (ECGLens)) for the classification of ECG signals from the PTB-XL dataset, which contains 12-lead recordings from normal patients and patients with various cardiac conditions. The DL models were trained on raw ECG signals, allowing them to automatically extract discriminative features. Data augmentation using the Stationary Wavelet Transform (SWT) was applied to enhance model performance, increase the diversity of training samples, and preserve the essential characteristics of the ECG signals. The models were evaluated using multiple metrics, including accuracy, precision, recall, F1-score, and ROC-AUC. The ECG-Lens model achieved the highest performance, with 80% classification accuracy and a 90% ROC-AUC. These findings demonstrate that deep learning architectures, particularly complex CNNs substantially outperform traditional ML methods on raw 12-lead ECG data, and provide a practical benchmark for selecting automated ECG classification models and identifying directions for condition-specific model development.

Summary

  • The paper establishes the superiority of deep learning, particularly the ECG-Lens model, over traditional ML methods in automated ECG classification.
  • The study uses SWT-based data augmentation to mitigate class imbalance, ensuring robust generalization across varied ECG morphologies.
  • Evaluation on the PTB-XL dataset shows the ECG-Lens model achieving 80% accuracy and 90% ROC-AUC, setting a new performance benchmark.

Comparative Evaluation of Machine Learning and Deep Learning Architectures for ECG Classification on the PTB-XL Dataset

Introduction

Automated analysis of electrocardiograms (ECGs) is fundamental for clinical diagnostics and monitoring of cardiovascular disease. The paper "ECG-Lens: Benchmarking ML & DL Models on PTB-XL Dataset" (2604.15822) provides a comparative study of various traditional ML algorithms and deep learning (DL) models for multi-class ECG classification using the PTB-XL dataset. The research systematically benchmarks Decision Tree, Random Forest, Logistic Regression, Convolutional Neural Networks (CNN), Long Short-Term Memory (LSTM), and an enhanced complex CNN model (ECG-Lens) on 12-lead raw ECG recordings. The study leverages Stationary Wavelet Transform (SWT)-based data augmentation to address class imbalance and maximizes model generalization. This essay summarizes the methodology, comparative results, and broader implications of the findings.

Methodology

The experimental protocol involves a meticulous data engineering pipeline and diverse model implementations:

  • Dataset and Preprocessing: The PTB-XL database is parsed to extract five superclasses: Normal, Myocardial Infarction, ST/T Change, Conduction Disturbance, and Hypertrophy. The data consist of 10-second 12-lead recordings (1,000×121,000 \times 12 per sample), yielding 16,243 instances post-class selection. Stratified splitting into train, validation, and test sets enables robust model evaluation. Significant class imbalance is rectified by oversampling minority classes through SWT-based augmentation, which preserves signal morphology at different time-frequency resolutions.
  • Traditional ML Models: Three classifiers—Decision Tree, Random Forest, Logistic Regression—are trained on flattened ECG data (1×12,0001 \times 12{,}000 vectors).
  • Deep Learning Models:
    • Simple CNN: Baseline 1D convolutional structure with pooling, batch normalization, dropout, and dense layers.
    • LSTM: Recurrent units capturing temporal sequence dependencies, with batch normalization and dropout.
    • ECG-Lens: An advanced multi-layer CNN with extensive filter hierarchies, aggressive regularization (batch normalization after each convolution, dropout rate 0.4), and global average pooling before classification.
  • Evaluation Metrics: All models are assessed using multi-class accuracy, macro-averaged ROC-AUC, F1-score, precision, and recall, capturing both global and class-wise discrimination capacity.

Results and Comparative Analysis

Traditional Machine Learning Performance

  • Decision Tree: 52% accuracy, 22% F1-score, and 58% ROC-AUC. The model demonstrates susceptibility to overfitting, reflected in poor minority class discrimination.
  • Logistic Regression: 40% accuracy, 21% F1-score, and 50% ROC-AUC, indicating severe incapacity to fit complex, nonlinear ECG morphologies.
  • Random Forest: Highest among ML models with 54% accuracy, 23% F1-score, and 62% ROC-AUC. Ensemble learning partially manages nonlinear dependencies but is ultimately constrained on raw high-dimensional signals.

Deep Learning Performance

  • CNN: Achieves 71% accuracy, 69% F1-score, and 85% ROC-AUC—substantially outperforming traditional models, but suffering from notable inter-class confusion.
  • LSTM: Yields marginally better performance than CNN, with 73% accuracy, 72% F1-score, and 87% ROC-AUC, confirming the importance of sequence modeling for ECG analysis.
  • ECG-Lens: Delivers the best results: 80% accuracy, 78% F1-score, and 90% ROC-AUC. The architecture’s expressive filter depth, thorough regularization, and direct modeling on raw signals enable robust discrimination across all five classes. Comparative confusion matrix analysis shows consistent improvements over predecessors, particularly in minority classes.

Data Augmentation and Model Generalization

Application of SWT-based augmentation is instrumental in mitigating class imbalance and preventing overfitting. This ensures fairness in comparative benchmarking and enhances the reliability of the deep models under realistic class distributions.

Implications

The superior performance of deep learning approaches, and particularly the ECG-Lens architecture, highlights several critical implications:

  • Clinical Utility: The consistent outperformance of ECG-Lens over traditional ML and simpler DL models suggests that robust, high-capacity neural architectures are necessary for reliable automated ECG interpretation on heterogeneous large-scale datasets. This can directly translate into scalable diagnostic support in real-world clinical workflows, including in resource-limited settings.
  • Signal Representation: Training on raw 12-lead signals enables the network to learn task-adaptive representations unavailable through traditional feature engineering or one-dimensional lead aggregation, obviating hand-crafted preprocessing.
  • Model Selection and Benchmarking: The comprehensive benchmarking on PTB-XL sets a rigorous baseline for future algorithmic innovations in ECG classification. The explicit comparison across methodologies provides a reference point for researchers seeking to advance model accuracy, interpretability, or efficiency.
  • Future Research Directions: The results motivate further exploration of transformer-based and hybrid sequence-convolutional models, integration with multi-modal clinical signals, and targeted architectures for condition-specific ECG stratification. Additionally, addressing domain shift, label noise, and uncertainty estimation in clinical deployment will be necessary extensions.

Conclusion

This work establishes that deep neural architectures, when paired with appropriate data augmentation and regularization, decisively outperform traditional machine learning techniques in the multi-class classification of 12-lead raw ECG signals. The ECG-Lens model, in particular, provides a new performance benchmark on the PTB-XL dataset, achieving 80% accuracy and 90% ROC-AUC. These results reinforce the pivotal role of deep learning in next-generation ECG analysis systems, with significant practical and methodological consequences for clinical AI applications.

Paper to Video (Beta)

No one has generated a video about this paper yet.

Whiteboard

No one has generated a whiteboard explanation for this paper yet.

Open Problems

We haven't generated a list of open problems mentioned in this paper yet.

Collections

Sign up for free to add this paper to one or more collections.