Related Experiment Video
Updated: Jul 3, 2025

Estimating Bilateral Atrial Function by Cardiovascular Magnetic Resonance Feature Tracking in Patients with Paroxysmal Atrial Fibrillation
Published on: July 20, 2022
A Q-transform-based deep learning model for the classification of atrial fibrillation types
B Dhananjay1, R Pradeep Kumar2, Bala Chakravarthy Neelapu1
1Department of Biotechnology and Medical Engineering, National Institute of Technology Rourkela, Rourkela, Odisha, 769008, India.
Insights
This study developed an AI model to accurately classify Atrial Fibrillation (AF) subtypes from ECG images. The custom 2D CNN achieved high accuracy in distinguishing Non-AF, Paroxysmal AF, and Persistent AF, aiding clinical decisions.
Area of Science:
- Cardiology
- Artificial Intelligence
- Medical Imaging
Background:
- Atrial Fibrillation (AF) is a growing global health concern, necessitating improved diagnostic tools for its subtypes.
- Accurate classification of AF subtypes is crucial for effective clinical management and personalized treatment strategies.
- Current diagnostic methods struggle with precise differentiation between AF subtypes.
Purpose of the Study:
- To develop and evaluate a custom 2D Convolutional Neural Network (CNN) model for automatic classification of Non-Atrial Fibrillation (Non-AF), Paroxysmal Atrial Fibrillation (PAF), and Persistent Atrial Fibrillation (PsAF) from ECG images.
- To assess the model's performance in differentiating these AF subtypes using key accuracy metrics.
- To explore the potential of AI in enhancing the diagnosis and management of AF.
Main Methods:
- ECG signals were transformed into time-frequency representations using Constant Q-Transform (CQT), generating a large dataset of images.
- A custom six-layer 2D CNN model was developed for image classification.
- Data augmentation techniques were employed to address class imbalance, followed by training, validation, and testing with a 0.7:0.15:0.15 ratio.
Main Results:
- The proposed 2D CNN model achieved high performance across all metrics: 0.98 accuracy, 0.98 precision, 0.98 sensitivity, 0.97 specificity, and 0.98 F1-score.
- The model demonstrated a strong ability to differentiate between Non-AF, PAF, and PsAF rhythms from ECG-derived images.
- The dataset comprised over 150,000 images, with training, validation, and testing sets carefully partitioned.
Conclusions:
- The developed AI model shows significant potential for accurately classifying AF subtypes from ECG images.
- This technology can assist physicians in reducing misdiagnosis and tailoring personalized treatment plans for AF patients.
- The findings highlight the efficacy of deep learning in advancing cardiac arrhythmia diagnostics.
Abstract:
According to the World Health Organization (WHO), Atrial Fibrillation (AF) is emerging as a global epidemic, which has resulted in a need for techniques to accurately diagnose AF and its various subtypes. While the classification of cardiac arrhythmias with AF is common, distinguishing between AF subtypes is not. Accurate classification of AF subtypes is important for making better clinical decisions and for timely management of the disease. AI techniques are increasingly being considered for image classification and detection in various ailments, as they have shown promising results in improving diagnosis and treatment outcomes. This paper reports the development of a custom 2D Convolutional Neural Network (CNN) model with six layers to automatically differentiate Non-Atrial Fibrillation (Non-AF) rhythm from Paroxysmal Atrial Fibrillation (PAF) and Persistent Atrial Fibrillation (PsAF) rhythms from ECG images. ECG signals were obtained from a publicly available database and segmented into 10-second segments. Applying Constant Q-Transform (CQT) to the segmented ECG signals created a time-frequency depiction, yielding 98,966 images for Non-AF, 16,497 images for PAF, and 52,861 images for PsAF. Due to class imbalance in the PAF and PsAF classes, data augmentation techniques were utilized to increase the number of PAF and PsAF images to match the count of Non-AF images. The training, validation, and testing ratios were 0.7, 0.15, and 0.15, respectively. The training set consisted of 207,828 images, whereas the testing and validation set consisted of 44,538 images and 44,532 images, respectively. The proposed model achieved accuracy, precision, sensitivity, specificity, and F1 score values of 0.98, 0.98, 0.98, 0.97, and 0.98, respectively. This model has the potential to assist physicians in selecting personalized AF treatment and reducing misdiagnosis.

