Internet of Things-Enabled Deep Learning Framework for Automated Detection and Classification of Cardiac Arrhythmia Using ECG Signals

Internet of Things-Enabled Deep Learning Framework for Automated Detection and Classification of Cardiac Arrhythmia Using ECG Signals

Satheesh Pandian C.* Kalidass J. Murugesan M. Muthuvel L.

Department of Computer Science and Engineering, Government College of Engineering, Theni 625582, India

Department of Computer Science and Engineering, Government College of Engineering, Tiruchirappalli 620012, India

Department of CSE, M. Kumarasamy College of Engineering, Karur 639113, India

Department of Artificial Intelligence and Data Science, Dhaanish Ahmed Institute of Technology, Coimbatore 641105, India

Corresponding Author Email: 
c.satheeshpandian@gcebargur.ac.in
Page: 
767-774
|
DOI: 
https://doi.org/10.18280/ts.430217
Received: 
9 December 2025
|
Revised: 
7 March 2026
|
Accepted: 
20 March 2026
|
Available online: 
30 April 2026
| Citation

© 2026 The authors. This article is published by IIETA and is licensed under the CC BY 4.0 license (http://creativecommons.org/licenses/by/4.0/).

OPEN ACCESS

Abstract: 

Electrocardiography (ECG) is widely recognized as an affordable and effective method for examining the heart’s electrical signals and identifying abnormal rhythms, which can escalate into serious health risks when not detected early. To enable early recognition of such conditions, an automated arrhythmia-classification framework integrating ECG acquisition with Internet of Things (IoT) technology has been created. The system continuously gathers ECG data, performs signal cleaning and segmentation, and forwards the processed information to a central node for immediate assessment. In a previous phase of this research, deep-learning techniques were employed to efficiently preprocess and divide ECG recordings into meaningful segments. To further reduce the computational load of the classifier, an evolutionary search strategy—Flamingo Optimization Algorithm (FLO)—was introduced to optimize the hyperparameters of a hybrid deep neural architecture. This optimized IoT-driven solution overcomes key drawbacks of earlier models and enhances the reliability of remote cardiac surveillance. Performance assessment was conducted using the MIT-BIH Arrhythmia Database, employing widely accepted evaluation measures such as accuracy, sensitivity, specificity, and F1-score. The optimised model achieved an accuracy of 99.44%, sensitivity of 99.57%, and specificity of 99.61%. These performance levels surpass those reported in comparable studies, indicating the model’s enhanced reliability and its suitability for real-time and dependable arrhythmia detection.

Keywords: 

cardiac arrhythmias, Internet of Things, electrocardiography, deep learning, convolutional neural network, Massachusetts Institute of Technology–Beth Israel Hospital

1. Introduction

Cardiovascular diseases (CVDs) remain the leading cause of mortality worldwide. According to the World Health Organization, they account for nearly 31% of global deaths, with a majority occurring in middle-income countries [1]. The cardiovascular electrical system includes electrical, circulatory, and structural components, and disturbances in the electrical system often result in cardiac arrhythmias (CA)—irregular heartbeats caused by faulty electrical signaling. Since manual identification of CA is difficult and time-consuming, early and automated detection is essential for continuous heart monitoring.

CAs are typically classified into five beat types: Normal (N), Supraventricular (S), Ventricular ectopic (V), Fusion (F), and Unknown (Q) [2]. They can also be broadly divided into abnormal impulse formation and conduction disorders. Electrocardiography (ECG) is the most widely used technique for diagnosing arrhythmias, offering continuous, non-invasive monitoring of the heart’s electrical activity [3]. Its simplicity, low cost, and quick recording process make ECG more accessible than imaging techniques like CT or MRI. As a result, over 300 million ECGs are recorded annually, and this number continues to grow.

Due to the sudden and complex nature of arrhythmias, real-time monitoring has become critical. Automated diagnostic systems have emerged to assist clinicians by reducing workload and improving detection accuracy. With advancements in communication technologies and the growth of the Internet of Things (IoT), patient health data can now be monitored remotely through connected devices. IoT-enabled sensors capture ECG signals and transmit them for analysis, offering timely insights for patients in both urban and rural settings.

Effective arrhythmia classification requires proper feature selection, extraction, and classification. Deep learning (DL) methods have gained prominence because they can automatically learn high-level features from ECG signals without manual intervention. Recent optimization techniques further improve classifier performance by fine-tuning hyperparameters. Additionally, wearable clinical sensors have become valuable tools for real-time monitoring of heart activity and other vital signs, contributing to reduced mortality from cardiac conditions.

To address the limitations of existing CA detection systems, this work proposes an IoT-enabled DL framework integrating 1D-CNN-based ECG segmentation with an optimized Residual Convolutional–LSTM–CNN (RCLC) classification model. The proposed system aims to improve classification accuracy, reduce computational complexity, and enable real-time monitoring through efficient hyperparameter tuning using the Flamingo Optimization Algorithm (FLO).

1.1 Challenges

Many researchers aim to develop efficient CA detection through ECG using ML approaches. However, the real-time monitoring of CA and its classification with faster convergence and improved accuracy is still challenging. Some of the challenges are listed as follows:

  • An efficient optimization of DL hyperparameters leads to an improved diagnosis system.
  • The most critical challenge is accuracy
  • The home care systems should be trusted by medical professionals to detect abnormalities and detect in an accurate way.
  • The delays should be avoided for real-time monitoring, and improving the convergence is still a challenge.

1.2 Previous studies

The work described in this paper is stated in (iii) of the conducted research. The remaining stages (i) and (ii) are described in the earlier developed research of us [4].

  1. The focus of this stage is to design a model for preprocessing, and a classifier has been developed for efficient CA detection using beat ECG signals. The success rate of efficient preprocessing and classification models has been experimented with, which has obtained superior performance.
  2. The focus of this stage is to develop a DL-based segmentation model for utilizing both rhythm and beat ECG signals and classifying them. The success rate of segmentation of both ECG rhythm and signal features is experimented with under five databases, which produce more efficient and accurate results than state-of-the-art approaches.
  3. This stage focuses on enhancing the previous research to reduce the network complexity and training time with the implementation of an optimization algorithm and support real-time monitoring through IoT. The success rate of an effective classification system with optimization in an IoT environment will be experimented on the MIT-BIH database.

1.3 Major contribution of this paper

  • To develop an efficient prediction of CAs disease. Initially, the collected data from IoT is preprocessed.
  • The RCLC with the Flamingo optimization model predicts CA.
  • This automotive tuning of classification and detection of CA is performed with less time and faster convergence.

1.4 Organization of this paper

The structure of this paper is organized as follows: Section 2 presents the existing literature on CA detection and diagnosis. Section 3 outlines the data pre-processing steps and the development of the proposed DL model. Section 4 provides the experimental results along with comparative performance analysis. Finally, Section 5 summarizes the key contributions of the study and highlights potential directions for future research.

2. Related Work

Research on CA detection has significantly advanced with the integration of DL and intelligent optimization strategies. A recent study proposed a DCNN model combined with Flamingo Optimization and IoT-enabled monitoring to support clinicians in CA diagnosis [5]. The ECG signals were preprocessed using a scalar transformation and normalization approach to suppress noise, and the model achieved an accuracy of 98.42% on the MIT-BIH dataset. An ECG telemetry framework was also introduced to efficiently capture heart-rate signals using representative features, ultimately lowering computational overhead during analysis [6].

Deep neural network (DNN) architectures have been explored to address the limitations of conventional ECG classification techniques, demonstrating improvements in accuracy, sensitivity, and specificity [7]. Another line of work adopted a two-stage strategy for arrhythmia detection consisting of QRS complex identification followed by rhythm classification [8]. In this approach, feature extraction is integrated directly into the classification mechanism, eliminating the need for elaborate preprocessing. To further reduce computational complexity while enhancing performance, variations such as all-convolutional networks, ensemble-based models, and batch normalization techniques have been employed.

A deep genetic ensemble classifier was introduced in the previous study, utilising 744 ECG signal segments from 29 subjects recorded in the MIT-BIH database. The proposed architecture integrates ensemble learning, DL, and evolutionary optimisation within a novel three-layer structure. The model achieved an accuracy of 99.37%, a sensitivity of 94.62%, and a specificity of 99.66%, and classified 17 CA types in approximately 0.8736 seconds.

Additionally, a 1D CNN-based arrhythmia detection approach using the MIT-BIH database was discussed in the study [9]. In this study, heartbeat segments were extracted by isolating the R-peak to preserve essential features such as the P wave, T wave, and QRS complex. The CNN architecture was evaluated under different configurations of filters, activation functions, and depth, demonstrating superior performance in identifying four major arrhythmia classes and achieving an accuracy of 0.99.

The trained hybrid CNN with the BiLSTM model to classify the CA five classes using the MIT BIH database [10]. The obtained accuracy was 0.98, with 0.91 sensitivity and specificity as 0.91. Various ML approaches, including Logistic trees, Naïve Bayes, and random forest to classify the CA from 23 recordings and classify CA into 11 classes [11]. Among the ML approaches, RF secured an improved accuracy of 0.97. A CNN and BiLSTM model developed to classify five ECG CA with the recognized accuracy of 0.96 [12]. An ECG signal descriptor using 1D binary pattern, wavelet, morphological data, and higher order statistical data for the feature extraction process [13]. To select the features and classification, a hybrid model called Manta Ray foraging optimization with SVM is developed that automatically determines the features of LBP, HOS, magnitude, and wavelet values. The SVM parameters are optimized using Manta ray optimization, which classifies the four abnormal and one normal heartbeat. An accuracy 98.26% DNN based CA detection was developed that extracts the high-level features, which avoids the manual feature design, and it helps the CA classification with improved accuracy than other traditional approaches [14].

3. Proposed System Model and Materials

The selection of 1D-CNN for ECG signal segmentation is motivated by its ability to effectively capture local temporal patterns in one-dimensional biomedical signals. Furthermore, the RCLC architecture is employed for classification as it combines convolutional layers for spatial feature extraction with LSTM units for temporal sequence learning. This hybrid design enhances the model’s capability to accurately classify complex arrhythmia patterns. This section discusses the IoT model for CA diagnosis and the methods used for this purpose.

3.1 Internet of Things model

The IoT system is illustrated in Figure 1. The network is represented as MnM_nMn, where nnn denotes the number of IoT nodes communicating within the frequency range f1f_1f1 to f2f_2f2. Each node is assigned a unique identifier, which facilitates the formation of clusters. These clusters forward their collected data to designated cluster heads, represented as CzC_zCz, with zzz ranging from 1 to hhh, where hhh is the total number of cluster heads. The cluster heads subsequently transmit the aggregated data to the base station (BS).

Figure 1. Architecture of the Internet of Things model

3.2 Proposed system model

Figure 2 presents the overall framework of the proposed system. ECG signals are initially acquired from IoT-enabled monitoring devices and transmitted to the BS. The data stored at the BS undergoes preprocessing using a 1D-CNN–based feature refinement module. The preprocessed signals are subsequently classified through the optimised DL model to determine whether a patient exhibits signs of CA. This architecture ensures timely and accurate diagnostic support. The classification model is further enhanced using FLO, which contributes to improved accuracy, faster convergence, and reduced computational time.

Figure 2. Internet of Things based cardiac arrhythmia detection system

3.3 Dataset description

This study employs the MIT-BIH Arrhythmia Database, which contains approximately 4,000 annotated ECG segments obtained from patients in a controlled clinical laboratory environment. Each ECG recording spans roughly 30 minutes and captures a wide range of cardiac rhythm disorders, including complex ventricular and supra-ventricular arrhythmia's, junctional rhythms, and various conduction abnormalities. These annotations are derived from rhythm patterns and QRS complex morphology.

The database includes recordings from 47 subjects, comprising both male and female participants aged 22 years and older. Each record consists of two-channel ECG data acquired using standard clinical electrodes at the BIH Arrhythmia Laboratory. The dataset is publicly accessible through the PhysioNet repository, facilitating reproducible research and performance bench-marking. Although the MIT-BIH Arrhythmia dataset is widely used as a benchmark for ECG classification tasks, its relatively limited size may affect the generalizability of the model. Future work will focus on validating the proposed approach using larger and real-time clinical datasets.

3.4 Preprocessing (background)

In the preprocessing phase, the ECG signals undergo several stages based on methodologies established in our earlier research. First, Z-score normalization is applied to minimise variations across samples and accelerate the training process. Subsequently, continuous wavelet transform (CWT) is used to generate scalogram representations, converting 1D ECG signals into 2D time–frequency images for improved feature extraction. The raw signals are filtered using a combination of high-pass and low-pass filters to suppress noise and enhance relevant cardiac patterns [4]. The extracted wavelet coefficients effectively reduce background interference.

Special emphasis is placed on detecting the QRS complex, the most prominent ECG waveform representing ventricular depolarization, and providing critical insights into cardiac function. The CNN model used for preprocessing consists of convolutional layers, pooling layers, and fully connected layers, as depicted in Figure 3.

Figure 3. 1D-CNN based segmentation

Figure 4. Residual Convolutional–LSTM–CNN based cardiac arrhythmias classification

3.5 Classification using optimized deep learning

Building on our earlier work, the RCLC architecture is employed for cardiac arrhythmia classification. The RCLC framework integrates three complementary components—Residual Attention-based CNN, LSTM, and standard CNN—to enhance hierarchical feature extraction and temporal pattern learning, as illustrated in Figure 3. For ECG beat classification, each heartbeat segment represented as a 252 × 1 time-sample vector is provided as input to the network, which subsequently generates predictions across 15 distinct ECG beat classes.

The divergence between the true class label and the predicted output is quantified through a cost function. To minimise this discrepancy, an optimisation algorithm iteratively adjusts the network parameters. Among various loss formulations used in neural network training, the cross-entropy loss remains the most widely adopted owing to its stability and effectiveness in multi-class classification tasks [4]. The cost function is expressed as:

$\begin{array}{r}\operatorname{cost}(C)=\frac{-1}{m} \sum_{k=1}^M\left(\left[z_k \times l_k\left(a_k\right)+(1\right.\right.  \left.\left.\left.-z_k\right) l_k\left(1-a_k\right)\right]\right)\end{array}$               (11)

3.4.1 Hyper-parameter optimization

The proposed hybrid deep-learning architecture, referred to as RCLC, is designed to be lightweight, significantly reducing the total number of trainable parameters without degrading performance. It converges more quickly than many traditional classifiers. Rather than relying on conventional gradient descent, an FLO is employed. Owing to its strong foraging behavior, global exploration ability, and capacity to search the entire parameter space, FLO is particularly well suited for fine-tuning the hyperparameters of the classifier [5]. By using FLO, the RCLC model is able to find a globally optimal set of hyperparameters — including weights, biases, and even aspects of the cost function — thereby ensuring efficient yet highly accurate arrhythmia classification. In this study, key hyperparameters such as learning rate, number of convolutional filters, hidden layer units, and batch size are optimized using the FLO. The optimization process searches within predefined ranges to identify the best parameter combination that maximizes classification performance while minimizing training time and computational cost.

3.6 Classification using optimized deep learning

The proposed RCLC architecture integrates three complementary components to improve ECG classification performance, illustrated in Figure 4.

First, a Residual CNN block extracts hierarchical spatial features from ECG signals using convolution layers with kernel sizes of 3 and 5, followed by batch normalization and ReLU activation. Residual skip connections improve gradient flow and prevent vanishing gradient problems.

Second, an LSTM layer with 128 hidden units captures temporal dependencies among sequential ECG heartbeat samples.

Finally, an additional CNN feature refinement layer is used before the fully connected classification layer, allowing the model to combine spatial feature extraction, temporal sequence modelling, and refined classification capability.

4. Experimental Results and Discussions

The IoT-enabled CA detection framework was evaluated using the Keras DL platform with TensorFlow as the backend. Prior to model training, the raw ECG signals were normalised to the range of 0 to 1 using the preprocessing utilities of the Scikit-learn library. To ensure robust performance assessment, a 10-fold cross-validation strategy was employed, wherein the dataset was partitioned into ten subsets, and each subset was sequentially used as the validation fold while the remaining folds were utilised for training. To avoid bias in performance evaluation, the MIT-BIH Arrhythmia dataset is evaluated using a 10-fold cross-validation strategy. The ECG segments are divided into ten equal subsets. In each iteration, nine subsets are used for training while the remaining subset is used for validation. This ensures that each sample appears once in the validation set and reduces overfitting risk.

4.1 Performance analysis of the developed model

The performance of the proposed optimized DL based CA detection system was evaluated using the confusion matrix, as shown in Figure 5. Based on the confusion matrix computed, the metrics are calculated. The analyzed results at varying numbers of epochs are illustrated in Figure 6.

The confusion matrix provides a detailed representation of classification performance by illustrating the correctly and incorrectly classified instances across different arrhythmia classes. It helps in identifying class-wise prediction accuracy and misclassification patterns.

Figure 5. Confusion matrix

(a)

(b)

(c)

Figure 6. Performance of the model with respect to accuracy, sensitivity, and specificity

4.2 Comparative analysis

The existing approaches, such as logistic regression [15], Deep CNN [16], DCNN-FLO [5], and 1DCNN-LSTM [17], are used for this comparison, and the results are illustrated in Figure 7. From this observation [18], it can be proved that the proposed model is superior and more efficient than other considered approaches for CA prediction.

The comparative analysis with respect to Receiver Operating Characteristic (ROC) is illustrated in Figure 8, which shows an improved ROC value of 0.95 compared to other approaches. This technique secured a reduced time for training the model compared to other approaches. Figure 9 shows that the training time also reduced.

Figure 7. Comparative analysis of cardiac arrhythmias prediction

Figure 8. ROC comparison

Figure 9. Training time comparison

In addition to accuracy, sensitivity, and specificity, the performance of the model is further evaluated using F1-score, ROC analysis, and confusion matrix. These metrics provide a more comprehensive evaluation of classification effectiveness, particularly in handling imbalanced datasets.

The ROC curve illustrates the trade-off between sensitivity and specificity across different threshold values. The proposed model achieves a higher area under the curve (AUC), indicating better discrimination capability compared to existing methods.

The training time comparison demonstrates that the proposed optimized model significantly reduces computational time due to efficient hyperparameter tuning using the FLO.

5. Conclusion

CA remains a critical health concern, claiming numerous lives due to delayed or inaccurate diagnosis. Early identification and timely clinical intervention are therefore essential to mitigate the severity of this condition. This study proposed an efficient CA detection framework that integrates an optimised DL model with IoT-enabled ECG acquisition to enhance diagnostic accuracy.

ECG signals collected from IoT-based sensor nodes were pre-processed, segmented, and subsequently classified using the RCLC model guided by the FLO-based optimisation strategy. By incorporating the bird-hunting mechanism, the FLO algorithm effectively fine-tuned the RCLC hyperparameters, thereby strengthening the overall predictive capability of the system. The proposed model demonstrated superior performance, achieving an accuracy of 99.4%, outperforming existing state-of-the-art methods.

Despite achieving high classification accuracy, the proposed model has certain limitations. It primarily relies on benchmark datasets, which may not fully represent real-world clinical scenarios. Additionally, there is a possibility of overfitting due to dataset size constraints. Therefore, further validation using real-time ECG data is necessary to ensure robustness and practical applicability.

The outcome of this work highlights the potential of combining IoT-driven data acquisition with advanced optimisation-assisted DL architectures to support clinicians in the early diagnosis of CA. Future extensions will focus on integrating real-time patient data to transform the system into a comprehensive smart healthcare platform for continuous CA monitoring and diagnosis.

Future work will focus on integrating real-time IoT-based ECG monitoring systems and evaluating the model on large-scale clinical datasets to enhance its applicability in real-world healthcare environments.

  References

[1] Wang, Y., Zhou, Y., Wang, H., Li, K., et al. (2025). Extracellular vesicles in vascular diseases: Pathological mechanisms and therapeutic application progress. Vessel Plus, 9: 21. https://doi.org/10.20517/2574-1209.2025.98 

[2] Das, M.K., Ari, S. (2014). ECG beats classification using mixture of features. International Scholarly Research Notices, 2014(1): 178436. https://doi.org/10.1155/2014/178436

[3] Hannun, A.Y., Rajpurkar, P., Haghpanahi, M., Tison, G.H., Bourn, C., Turakhia, M.P., Ng, A.Y. (2019). Cardiologist-level arrhythmia detection and classification in ambulatory electrocardiograms using a deep neural network. Nature Medicine, 25(1): 65-69. https://doi.org/10.1038/s41591-018-0268-3

[4] Pandian, C.S., Kalpana, A.M. (2023). HybDeepNet: ECG signal based cardiac arrhythmia diagnosis using a hybrid deep learning model. Information Technology and Control, 52(2): 416-432. https://doi.org/10.5755/j01.itc.52.2.33302

[5] Kumar, A., Kumar, M., Mahapatra, R.P., Bhattacharya, P., et al. (2023). Flamingo-optimization-based deep convolutional neural network for IoT-based arrhythmia classification. Sensors, 23(9): 4353. https://doi.org/10.3390/s23094353

[6] Devi, R.L., Kalaivani, V. (2020). Machine learning and IoT-based cardiac arrhythmia diagnosis using statistical and dynamic features of ECG: RL Devi, V. Kalaivani. The Journal of Supercomputing, 76(9): 6533-6544. https://doi.org/10.1007/s11227-019-02873-y

[7] Hammad, M., Iliyasu, A.M., Subasi, A., Ho, E.S., Abd El-Latif, A.A. (2020). A multitier deep learning model for arrhythmia detection. IEEE Transactions on Instrumentation and Measurement, 70: 1-9. https://doi.org/10.1109/TIM.2020.3033072

[8] Ihsanto, E., Ramli, K., Sudiana, D., Gunawan, T.S. (2020). An efficient algorithm for cardiac arrhythmia classification using ensemble of depthwise separable convolutional neural networks. Applied Sciences, 10(2): 483. https://doi.org/10.3390/app10020483

[9] Ahmed, A.A., Ali, W., Abdullah, T.A., Malebary, S.J. (2023). Classifying cardiac arrhythmia from ECG signal using 1D CNN deep learning model. Mathematics, 11(3): 562. https://doi.org/10.3390/math11030562

[10] Hassan, S.U., Mohd Zahid, M.S., Abdullah, T.A., Husain, K. (2022). Classification of cardiac arrhythmia using a convolutional neural network and bi-directional long short-term memory. Digital Health, 8: 20552076221102766. https://doi.org/10.1177/20552076221102766

[11] Latif, G., Al Anezi, F.Y., Zikria, M., Alghazo, J. (2020). EEG-ECG signals classification for arrhythmia detection using decision trees. In 2020 Fourth International Conference on Inventive Systems and Control (ICISC), Tamil Nadu, India, pp. 192-196. https://doi.org/10.1109/ICISC47916.2020.9171084

[12] Xu, X., Jeong, S., Li, J. (2020). Interpretation of electrocardiogram (ECG) rhythm by combined CNN and BiLSTM. IEEE Access, 8: 125380-125388. https://doi.org/10.1109/ACCESS.2020.3006707

[13] Houssein, E.H., Ibrahim, I.E., Neggaz, N., Hassaballah, M., Wazery, Y.M. (2021). An efficient ECG arrhythmia classification method based on Manta ray foraging optimization. Expert Systems with Applications, 181: 115131. https://doi.org/10.1016/j.eswa.2021.115131

[14] Khan, A.H., Hussain, M., Malik, M.K. (2021). Arrhythmia classification techniques using deep neural network. Complexity, 2021(1): 9919588. https://doi.org/10.1155/2021/9919588

[15] Connelly, L. (2020). Logistic regression. Medsurg Nursing, 29(5): 353-354.

[16] Dong, P., Zhang, H., Li, G.Y., Gaspar, I.S., NaderiAlizadeh, N. (2019). Deep CNN-based channel estimation for mmWave massive MIMO systems. IEEE Journal of Selected Topics in Signal Processing, 13(5): 989-1000. https://doi.org/10.1109/JSTSP.2019.2925975

[17] Luo, X., Yang, L., Cai, H., Tang, R., Chen, Y., Li, W. (2021). Multi-classification of arrhythmias using a HCRNet on imbalanced ECG datasets. Computer Methods and Programs in Biomedicine, 208: 106258. https://doi.org/10.1016/j.cmpb.2021.106258

[18] Jiao, J., Zhao, M., Lin, J., Ding, C. (2019). Classifier inconsistency-based domain adaptation network for partial transfer intelligent diagnosis. IEEE Transactions on Industrial Informatics, 16(9): 5965-5974. https://doi.org/10.1109/TII.2019.2956294