Abstract
In the present scenario, Electrocardiogram (ECG) is an effective non-invasive clinical tool, which reveals the functionality and rhythm of the heart. The non-stationary nature of ECG signal, noise existence, and heartbeat abnormality makes it difficult for clinicians to diagnose arrhythmia. The most of the existing models concentrate only on classification accuracy. In this manuscript, an automated model is introduced that concentrates on arrhythmia type classification using ECG signals, and also focuses on computational complexity and time. After collecting the signals from the MIT-BIH database, the signal transformation and decomposition are performed by Multiscale Local Polynomial Transform (MLPT) and Ensemble Empirical Mode Decomposition (EEMD). The decomposed ECG signals are given to the feature extraction phase for extracting features. The feature extraction phase includes six techniques: standard deviation, zero crossing rate, mean curve length, Hjorth parameters, mean Teager energy, and log energy entropy. Next, the feature dimensionality reduction and arrhythmia classification are performed utilizing the improved Firefly Optimization Algorithm and autoencoder. The selection of optimal feature vectors by the improved Firefly Optimization Algorithm reduces the computational complexity to linear and consumes computational time of 18.23 seconds. The improved Firefly Optimization Algorithm and autoencoder model achieved 98.96% of accuracy in the arrhythmia type classification, which is higher than the comparative models.
Keywords
Introduction
Currently, cardiovascular disease is one of the leading causes of death among the non-transmissible and non-infectious diseases in the world [1]. In cardiovascular diseases, arrhythmia is an important group of diseases, where the arrhythmia diagnosis majorly depends on the electrocardiogram (ECG) signal [2, 3]. The ECG is an effective medical tool that records the process of cardiac recovery, excitability and transmission [4]. Additionally, the ECG signal significantly reflects the cell development mechanism, functional structure of the ventricle, myocardial cell damage, and functional structure of atrium [5, 6]. However, the recognition of irregular heartbeats from the ECG signal is a hard process for the automated diagnosis of cardiovascular diseases, because it is greatly affected by mental states and environmental factors [7]. In recent times, automated ECG signal diagnosis has become a hotspot research topic, due to the continuous growth of computer science technology [8, 9]. Several techniques used for ECG based arrhythmia classification, which are reported in the literature, such as, Non-stationary Decomposition Technique [10], Fast Compression Residual Convolutional Neural Network (CNN) [11], CNN [12], Support Vector Machine [13], Recurrent Neural Network [14], etc. The deep learning techniques are computationally costly and consumes more computational time, because enormous amount of data is required to attain efficient classification results [15, 16]. Therefore, a novel feature optimization and autoencoder model is implemented for effective arrhythmia type classification with limited computational time. The major contributions are specified below:
First, the raw ECG data is collected from the MIT-BIH database based on the Association for the Advancement of Medical Instrumentation (AAMI) standard. Then, the Multiscale Local Polynomial Transform (MLPT) and Ensemble Empirical Mode Decomposition (EEMD) techniques are carried out for signal transformation and decomposition. The temporal and the local spectral information are extracted from the raw ECG signal for better signal classification.
The feature extraction is performed using standard deviation, zero crossing rate, mean curve length, Hjorth parameters, mean Teager energy, and log energy entropy. Here, the hybrid feature extraction increases the explainability, speeds up the training process, and decreases the overfitting risk of the autoencoder model.
The dimension of the extracted feature values is reduced by implementing improved Firefly Optimization Algorithm. The dimensionality feature reduction decreases the system complexity and computational time. The developed improved Firefly Optimization Algorithm uses Lévy flight style intermittent scale-free search pattern that strengthens the exploitation and exploration in the local and global spaces.
The optimized feature vectors are fed as the input to the autoencoder for arrhythmia classification. The effectiveness of the improved Firefly Optimization Algorithm and autoencoder model is investigated by means of specificity, precision, sensitivity, and accuracy.
This article is arranged as follows: the papers related to the arrhythmia type classification are reviewed in Section 2. The feature optimization and autoencoder model’s theoretical explanation and the experimental outcomes are correspondingly represented in Sections 3 and 4. The conclusion of the feature optimization and autoencoder model is mentioned in Section 5.
Literature review
Extraction of features
Houssein et al. [17] integrated wavelets, Local Binary Patterns, morphological information, and Higher-Order Statistics for extracting feature vectors from the acquired ECG signals. Additionally, the Manta Ray Foraging Optimization technique and Support Vector Machine (SVM) were utilized for optimal feature selection and arrhythmia type classification. However, the SVM classifier was inappropriate for multiclass arrhythmia type classification, which was a major issue in this literature. Atal and Singh [18] initially utilized interval features and Gabor wavelet for extracting features from the ECG signals and further, the extracted features were given to the arrhythmia classification module: Bat rider optimization algorithm with deep CNN model. As depicted in the resulting phase, the computational complexity of the developed model was higher related to the traditional classification techniques. Anwar et al. [19] integrated RR interval, Teager energy operator, and Independent Component Analysis for extracting feature vectors from the acquired ECG signals. Hence, the obtained features were fed to the neural network for ECG arrhythmia type classification. The developed model achieved better classification accuracy by performing three-fold cross-validations. As mentioned earlier, the neural network models were computationally costly, while training the imbalanced databases.
Liu et al. [20] integrated two dimensional graph Fourier transform and Higher-Order Statistical techniques for feature extraction. In the classification section, the extracted discriminative feature vectors were given to the SVM for arrhythmia classification. As mentioned earlier, the SVM classifier was inappropriate for multi-class classification. Ramkumar et al. [21] initially used Discrete Wavelet Transform and Independent Component Analysis techniques for ECG signal pre-processing and dimensionality reduction. Further, the feature vectors: variance, minimum, and maximum coefficient value of the wavelets, in every desired level, were given to the Multi-Layer Perceptron for arrhythmia classification; however, the perceptron learned only simple problems. Jha and Kolekar [22] had integrated SVM and tunable Q-wavelet transform-based feature extraction techniques, for automated arrhythmia type classification. In this research field, the developed model outperformed numerous recent models. Additionally, Bhagyalakshmi et al. [23] utilized Gabor filters and multi-resolution wavelet technique for extracting textural and interval feature vectors from the raw ECG signals. The corresponding feature vectors were fed as the input to the genetic optimization based support vector neural network for arrhythmia classification, but it was computationally costly.
Classification
Huang et al. [24] firstly used the short-time Fourier transform technique for transforming the acquired ECG signals into time-frequency spectrograms, which were fed to the CNNs for ECG arrhythmia type classification. The statistical evaluation demonstrated that the developed model obtained higher mean accuracy on the MIT-BIH database than the traditional methods. However, the conventional 2D CNN model was computationally costly, because it required a high-end graphic processing unit system for data training. Singh et al. [25] introduced a Recurrent Neural Network to classify the arrhythmia beats. The statistical investigation showed that the Recurrent Neural Network model obtained significant results in binary classification, but suffered from the obstacle of vanishing gradient.
Yildirim et al. [26] utilized Long Short Term Memory (LSTM) network and deep coded features for effective arrhythmia classification, however, the LSTM network was prone to the overfitting issue. Savalia and Emamian [27] implemented a hybrid deep learning model: LSTM with Multi-Layer Perceptron for automatic arrhythmia classification on the MIT-BIH arrhythmia and PhysioBank databases. Correspondingly, Chen et al. [28] integrated LSTM and CNN for automated arrhythmia classification. The computational complexity was higher, while integrating two deep learning models. Refahi et al. [29] developed a least square twin SVM classifier for arrhythmia type classification. The experimental outcome showed that the developed classifier achieved a faster and precise arrhythmia diagnosis related to previous models. Yet, the developed classifier led to the issue of non-parallel hyperplane overlapping, the classification rate was decreased, while training an imbalanced/unstructured database.
Ihsanto et al. [30] integrated depth-wise separable convolution, batch normalization, and convolution layers for achieving better classification accuracy with limited computational cost. The three depth-wise separable CNNs were ensembled for final classification. Vishwanath et al. [31] integrated both support vector neural network and probabilistic principal component analysis for automated arrhythmia type classification. The experimental outcomes proved the success and efficiency of the presented model in raw ECG signals, but it suffered from the class overlap problem. Shaker et al. [32] implemented Generative Adversarial Networks for ECG classification.
Alarsan and Younes [33] integrated morphological, summits, and temporal features for extracting feature vectors from the ECG data. The obtained feature vectors were fed to the gradient boosted trees and random forest for arrhythmia classification. In real time prediction, the random forest classifier was ineffective and too slow in data training and testing. Yan and Zhang [34] used band-stop and median filter for pre-processing the ECG data acquired from the MIT-BIH database. The Denoised signals were fed to the Back Propagation-Neural Network for arrhythmia type classification, but it was computationally costly.
He et al. [35] introduced a new automatic arrhythmia classification model on the basis of Deep Neural Networks. Here, the bidirectional LSTM and residual convolutional modules were trained to extract feature vectors from raw ECG signals. The extracted feature-vectors were concatenated to do the arrhythmia classification; however, the developed model was computationally complex. Wang et al. [36] initially extracted 105 features from the pre-processed ECG signals and then, the arrhythmia classification was accomplished by using a two-layer classifier. Every layer comprises threshold criterion and two independent fully connected neural networks. The developed model’s performance was validated on the MIT-BIH database. Still, the developed model was expected to improve the computational time, while processing large imbalanced databases. To address the aforementioned issues, a novel feature optimization and autoencoder model is proposed in this article for an effective automated arrhythmia type classification.
Improved firefly optimization algorithm and autoencoder model
In the ECG based arrhythmia type classification, the proposed framework includes four steps named as (i) signal transformation and decomposition using MLPT and EEMD techniques, (ii) feature extraction by standard deviation, zero crossing rate, Hjorth parameters, mean Teager energy, log energy entropy, and mean curve length, (iii) feature optimization using improved Firefly Optimization Algorithm (IFOA), and (iv) arrhythmia type classification by autoencoder model. The flow diagram of the proposed framework is specified in Fig. 1.
Workflow of the proposed framework.
After collecting the ECG signals from the MIT-BIH database, the signal transformation and decomposition are accomplished by using MLPT and EEMD techniques. Initially, the MLPT technique is constructed based on the Laplacian Pyramid technique. The MLPT technique is numerically stable unlike other decimated wavelet transforms and its reconstruction is smooth while the transformation is employed on the time series with irregular time points. The higher degree of redundancy in the MLPT enables to perform effective smoothing, during data reconstruction. In addition, the MLPT technique can generate multi-scale decomposition for the function derivatives. The transformation can be extended towards adaptive and nonlinear data decompositions [37].
After signal transformation, the transformed ECG signals are decomposed utilizing EEMD technique, which decomposes the non-stationary ECG signals into an oscillatory mode: Intrinsic Mode Functions. The objective of EEMD technique is to identify the intrinsic oscillatory mode and decompose the data scale according to its time. The oscillatory mode generates zero crossing, which is eliminated in extreme conditions. In this manuscript, the EEMD technique is utilized for eliminating the signal oscillation by separating the local level features, because it creates the overlapping problem for the time scale components. The steps involved in the EEMD technique are determined below:
where
Sample electrocardiogram (ECG) signals.
After decomposing the ECG signals, the feature extraction is accomplished by using six techniques: standard deviation, zero crossing rate, mean curve length, Hjorth parameters, mean Teager energy, and log energy entropy. Initially, the non-linear dynamics of the ECG are characterized by the log energy entropy. The heart function behavior is successfully obtained from the non-linear dynamics of the ECG signal. In addition to this, the zero crossing rate counts the number of crossings around the mean value within a three second long moving average. The Hjorth parameters include three time domain features: complexity, mobility, and activity. The activity is determined as the standard deviation of the epoch, and the mobility is defined as the ratio of the activity of the epoch to the derivative activity of the epoch. Likewise, complexity defines the ratio of epoch activity to the epoch’s derivative mobility.
In addition to this, the mean curve length is determined as the linear distance between the successive points on the curve, and the mean Teager energy is a non-linear operator, which obtains energy signal based on the mechanical and physical considerations. Additionally, the Teager energy operator tracks the amplitude envelopes and instantaneous frequencies. The continuous form of Teager energy operator
where
The output of the Teager energy operator has effective energy fluctuation, because of its excellent time resolution. Finally, the standard deviation measures how far the ECG signals deviate from the mean value. The 32 features that were extracted, which are given to the improved Firefly Optimization Algorithm for feature optimization that helps in decreasing the system complexity and computational time.
The Firefly Optimization Algorithm (FOA) is a nature-inspired, metaheuristic and swarm intelligent algorithm, which is developed by mimicking the characteristic behaviors of the fireflies. In this algorithm, the total population of the fireflies represents the luminary flashing activity, which is a function used to communicate, attract the partners and give risk warning of the predators. As mentioned above, the FOA mimics the behavior of fireflies and the FOA majorly includes three rules for idealizing the firefly’s behavior. The brightness value of the fireflies is estimated using the land-scape of the objective functions. In addition, the fireflies are unisex, therefore, each firefly is attracted to the other regardless of sex. In addition, the firefly’s attractiveness is decided by the brightness value, in which the less brighter firefly flies against the brighter firefly. The attractiveness is directly proportional to the brightness value, and the attractiveness and brightness are reduced with the increase of distance. Based on absorptions and the inverse square law, the light intensity
where
where
where
The conventional FOA suffers from low exploitation and exploration in the local and global spaces. Therefore, the improved FOA is developed in this manuscript, and it utilizes Lévy flight style intermittent scale free search pattern for strengthening the exploitation and exploration in the local and global spaces and accelerating the convergence speed. However, the improved FOA employs randomization based on Lévy distribution instead of the uniform distribution, and in the improved FOA, the position is updated based on Eq. (8).
where
where
where
After feature optimization, the optimized discriminative active feature vectors are given as the input to the autoencoder model for classifying the heartbeat types. The autoencoder is an effective learning model that learns data representations by training the network for ignoring signal noise. In this scenario, the autoencoder includes neural layers for learning ECG signals from the MIT-BIH database. The Deep Neural Networks like autoencoder, are capable of evaluating the unknown features of an ECG signal, where it acts as a progressive feature-learning model. The autoencoder model comprises three layers, known as: input, output and hidden, where every layer has a specified number of neurons. The autoencoder model includes two main phases: encoding and decoding. In the encoding phase, the dimension of the optimized feature vectors is reduced before feeding them to the hidden layer. Then, the reduced feature vectors are decoded in the decoding phase for obtaining feature vectors
Architecture of autoencoder.
The encoding and decoding phases are mathematically specified in Eqs (12) and (13).
where
In this article, the implemented improved FOA and autoencoder model is simulated by Matlab (2020a) tool on the system with 64GB random access memory, Intel
List of heartbeat types according to the AAMI standard
List of heartbeat types according to the AAMI standard
Best training performance of autoencoder model.
In this manuscript, four performance measures: specificity, precision, sensitivity, and accuracy are used to analyze the classification performance. These performance measures are determined using four concepts, which are called as: False Negative (FN), False Positive (FP), True Positive (TP) and True Negative (TN). In the arrhythmia type classification, accuracy directly reflects the feature optimization and autoencoder model’s performance, which is mathematically represented in Eq. (14). In addition, precision is represented as the ratio between total positive samples to the total samples precisely classified as positive, and it is defined in Eq. (15).
In addition, the sensitivity represents sharply classified true positives, and the specificity indicates sharply classified true negatives, which are mathematically denoted in Eqs (16) and (17).
In this section, the feature optimization and autoencoder model’s performance is investigated on the MIT-BIH database. In this scenario, the performance analysis is done by utilizing the classifiers: random forest, autoencoder, Multi-SVM (MSVM), CNN and K-Nearest Neighbor (KNN), and feature optimizers: Firefly Optimization Algorithm (FOA), Artificial Bee Colony (ABC), improved FOA (IFOA), and Particle Swarm Optimizer (PSO). The simulation results of the classifiers and feature optimizers without AAMI standard are represented in Tables 2 and 3. The MIT-BIH database without AAMI standard includes 17 classes in which balanced nine classes are considered for experimental analysis. By inspecting Table 2, the combination: improved FOA based feature selection with autoencoder classifier achieved better arrhythmia classification with 98.48% of sensitivity, 98.4% of accuracy, 96.23% of precision, and 97.77% of specificity. The obtained simulation outcomes are higher compared to the traditional classifiers. The comparison results of the classifiers without AAMI standard is graphically depicted in Fig. 5.
Simulation results of the classifiers without AAMI standard
Simulation results of the classifiers without AAMI standard
The simulation results of the feature optimizers on the MIT-BIH database without AAMI standard is specified in Table 3. As mentioned earlier, the combination: improved FOA with autoencoder has achieved maximum arrhythmia type classification compared to existing optimizers like FOA, ABC, and PSO. The assumed parameters of PSO are: social factor
Simulation results of the feature optimizers without AAMI standard
Comparison results of the classifiers without AAMI standard.
Comparison results of the feature optimizers without AAMI standard.
In this section, the simulation results of the classifiers with and without feature optimization, on the MIT-BIH database, are stated in Table 4, and this time the AAMI standard is considered for the results. By investigating Table 4, the improved FOA and autoencoder model achieved 97.14% of precision, 98.88% of sensitivity, 98.96% of accuracy, and 99.69% of specificity. Related to the comparative classifiers, the autoencoder model superiorly learns the linear and non-linear transformation with multiple layers and nonlinear activation function. With sparsity constraints and effective dimensionality, the autoencoder learns data projection superiorly than other comparative classifiers. The comparison results of the classifiers with AAMI standard, are specified in Fig. 7.
Simulation results of the classifiers with AAMI standard
Simulation results of the classifiers with AAMI standard
As stated in Table 5, the combination: improved FOA with autoencoder has obtained maximum results in the ECG based arrhythmia type classification. The comparative optimizers generally suffer from low exploitation and exploration in the local and global spaces. To overcome the above stated issue, the improved FOA uses Lévy flight style intermittent scale free search pattern for accelerating the convergence speed and strengthening the exploitation in local space. The simulation results of the feature optimizers with AAMI standard is depicted in Fig. 8.
Simulation results of the feature optimizers with AAMI standard
Comparison results of the classifiers with AAMI standard.
In this research manuscript, a statistical test: Z-test is performed on the collected database that achieved a
Simulation results of improved FOA and autoencoder model with the K-fold cross validations
Comparison results of the feature optimizers with AAMI standard.
Comparison results of improved FOA and autoencoder model with the K-fold cross validations.
The primary objective of this study is to use a classification model for predicting onset of Arrhythmia disease in cognitively normal and abnormal subjects. This experiment involves performing ablation study in the context of machine learning. By investigating Tables 2 and 4, the experiments conducted with ablation study demonstrated the effectiveness of the improved FOA in the arrhythmia type classification. The incorporation of improved FOA with autoencoder improved from 1% to almost 7% of classification accuracy with limited computational time. The Lévy flight style intermittent scale-free search pattern strengthens the exploitation and exploration ability of FOA in the local and global spaces to achieve a better solution to the optimization problem.
The comparative result of the improved FOA and autoencoder model and the existing models is stated in Table 7. Houssein et al. [17] used Higher-Order Statistics, morphological information, Local Binary Patterns, and wavelets for extracting feature vectors from the ECG signals. The multi-dimensional feature vectors were dimensionally reduced utilizing Manta Ray Foraging Optimization and then fed to the SVM classifier for arrhythmia type classification. The presented model achieved 98.26% of accuracy and 97.43% of sensitivity on the MIT-BIH database. Atal and Singh [18] initially performed feature extraction by utilizing Gabor wavelet and interval features. Next, the Bat rider optimization algorithm with deep CNN model was implemented for arrhythmia classification. As mentioned in the resulting segment, the presented model achieved 93.19% of accuracy and 93.98% of sensitivity on the MIT-BIH database. Bhagyalakshmi et al. [23] integrated Gabor filters and multi-resolution wavelets for feature extraction and the obtained feature vectors were given to the genetic optimization-based support vector neural network, for arrhythmia type classification. The simulation results showed that the developed model attained 96.96% of accuracy and 99% of sensitivity on the MIT-BIH database. Shaker et al. [32] developed Generative Adversarial Networks for ECG classification, and the implemented Generative Adversarial Networks (GANs) model obtained 98% of accuracy and 97.70% sensitivity on the MIT-BIH database. However, in this current research study, the proposed improved FOA and autoencoder model attained higher classification results compared to these existing models on the MIT-BIH database in light of sensitivity and accuracy.
Comparative result of the improved FOA and autoencoder model and the existing models
Comparative result of the improved FOA and autoencoder model and the existing models
In this study, the feature optimization is a crucial phase for effective arrhythmia type classification. The extracted mean curve length, log energy entropy, mean Teager energy, Hjorth parameters, zero cross rate, and standard deviation features are high dimensional that generally leads to overfitting problem, which is effectively resolved by implementing improved FOA. The respective dimensionally reduced feature vectors or optimized feature vectors are given to the autoencoder model for arrhythmia type classification. In this study, the efficacy of the improved FOA and autoencoder model is denoted in the Tables 2–7. Due to the selection of optimal feature vectors, the computational complexity of the proposed improved FOA and autoencoder model is linear
Computational time of improved FOA and the comparative optimization techniques
Computational time of improved FOA and the comparative optimization techniques
In this manuscript, the improved FOA based feature selection and autoencoder model is implemented for effective arrhythmia type classification. The implemented feature optimization and autoencoder model includes four major steps: (i) signal transformation and decomposition, (ii) feature extraction, (iii) feature dimensionality reduction and (iv) classification. The ECG signal acquired from the MIT-BIH database is transformed and decomposed utilizing MLPT and EEMD techniques. Next, standard deviation, zero crossing rate, mean curve length, Hjorth parameters, mean Teager energy, and log energy entropy are employed for feature extraction. Further, the multi-dimensional feature values are optimized by introducing improved FOA, which helps in improving the system complexity and computational time. Lastly, the optimized feature values are given as the input to the autoencoder model for arrhythmia type classification such as fusion beat, unknown beat, ventricular ectopic beat, normal beat, and supraventricular ectopic beat. The complexity of the developed model is linear and the computational time is 18.23 seconds, which is better related to the prior models. The undertaken four performance measures confirm the effectiveness of the improved FOA and autoencoder model in the arrhythmia type classification. The experimental evaluation showed that the improved FOA and autoencoder has obtained 98.96% of accuracy, 98.88% of sensitivity, 99.69% of specificity and 97.14% of precision in the arrhythmia type classification which are superior than the existing models. In future work, a hybrid metaheuristics based optimizer can be combined with the proposed model to further enhance arrhythmia type classification.
Funding
This research received no external funding.
Data availability
The datasets generated during and/or analysed during the current study are available in the [MIT-BIH Arrhythmia Database] repository, [https://physionet.org/content/mitdb/1.0.0/].
Footnotes
Conflict of interest
The authors declare that they have no conflict of interest.
Author’s Bios
