A Hybrid GAN-Based DL Approach for the Automatic Detection of Shockable Rhythms in AED for Solving Imbalanced Data Problems
Abstract
:1. Introduction
- We proposed a generative model along with an external classifier to detect the shockable rhythms.
- We integrated WCGAN with the DL classifier to solve the low-sample class problem.
- We integrated WCGAN with the DL classifier in such a way that it trained the classifier together with the generation. Therefore, it eliminates the training overhead for the classifier.
- We improved shockable rhythms detection for an AED and a classification performance compared to the DL or combined DL and ML models.
2. Materials and Methods
2.1. EC–GAN
2.2. WCGAN–GP
2.3. The Proposed EC–WCGAN Method
2.4. Dataset
- The AHA fibrillation database (AHADB) [26], which includes 30 min ECG recordings from 10 patients.
- The Massachusetts Institute of Technology–Beth Israel Hospital (MIT–BIH) malignant ventricular ectopy database (VFDB) [27], which includes 22 half-hour ECG recordings of patients who experienced ventricular tachycardia, ventricular flutter, and ventricular fibrillation.
- The Creighton University (CU) ventricular tachyarrhythmia database (CUDB) [28], which includes 35 eight-minute ECG recordings of people who have undergone sustained ventricular tachycardia, ventricular flutter, and ventricular fibrillation episodes.
- Temporal features: to characterize the rhythm’s amplitude, slope, sample distribution, or heart rate.
- Spectral features: to quantify spectral concentration, normalized spectral moments, or relative power content in distinct frequency bands
- Time-frequency features: based on the wavelet analysis of the ECG.
- Complexity features: include the Hilbert transform, sample entropy, complexity measure, covariance, etc.
2.5. The Deep Learning Models with Adaptive Synthetics (ADASYN)
2.5.1. Deep Neural Network (DNN)
2.5.2. Convolution Neural Network (CNN)
2.5.3. Deep Convolution Neural Network (DCNN)
2.5.4. Long Short-Term Memory (LSTM)
2.5.5. Gated Recurrent Unit (GRU)
2.5.6. Recurrent Neural Network (RNN)
3. Results and Discussion
3.1. Plot-Based Responses
3.2. Performances Metrics
- Sensitivity: Sensitivity is the probability of shock advised for patients who truly have shockable rhythms rhythm.
- Specificity: Specificity is the probability of no shock advised for patients with non-shockable rhythms.
- BER: BER represents the balanced error rate, a balanced statistic that considers shockable and non-shockable rhythm detection errors equally.
- Precision: It estimates the ratio of correctly classified rhythms to the number of all identified rhythms.
- Recall: It estimates the ratio of correctly classified non-shockable rhythms to all non-shockable rhythms.
- F1-Score: It is the harmonic mean of precision and recall. A higher value of the F1-score represents a good model, and its value lies between 0 and 1.
3.3. Comparison of EC–WCGAN with Existing Hybrid Models
3.4. Calculation of Confidence Intervals for Sensitivity and Specificity
4. Conclusions
5. Future Work
Author Contributions
Funding
Data Availability Statement
Acknowledgments
Conflicts of Interest
Abbreviations
Abbreviation | Meaning |
AED | Automated External Defibrillator |
AHA | American Health Association |
BER | Balanced Error Rate |
CNN | Convolution Neural Network |
CNNE | Convolution Neural Network as a Feature Extractor |
CPR | Cardiopulmonary Resuscitation |
CUDB | Creighton University Ventricular Tachyarrhythmia Database |
DCNN | Deep Convolution Neural Network |
DNN | Deep Neural Network |
DL | Deep Learning |
ECG | Electrocardiogram |
EC | External Classifier |
GAN | Generative Adversarial Network |
GP | Gradient Penalty |
GRU | Gated Recurrent Unit |
OHCA | Out-of-Hospital Cardiac Arrest |
LSTM | Long Short-Term Memory |
ML | Machine Learning |
MVDB | Modified Variational Mode Decomposition |
PEA | Pulseless Electrical Activity |
NSH | Non-Shockable |
NSR | Normal Sinus Rhythm |
RNN | Recurrent Neural Network |
SAA | Shock Advise Algorithm |
SCA | Sudden Cardiac Arrest |
SVM | Support Vector Machine |
VF | Ventricular Fibrillation |
VT | Ventricular Fibrillation |
WCGAN | Wasserstein Conditional Generative Adversarial Network |
References
- Ferretti, J.; Di Pietro, L.; De Maria, C. Open-source automated external defibrillator. HardwareX 2017, 2, 61–70. [Google Scholar] [CrossRef]
- Patil Kaustubha, D.; Halperin Henry, R.; Becker Lance, B. Cardiac Arrest. Circ. Res. 2015, 116, 2041–2049. [Google Scholar] [CrossRef] [Green Version]
- Fabbri, A.; Marchesini, G.; Spada, M.; Iervese, T.; Dente, M.; Galvani, M.; Vandelli, A. Monitoring intervention programmes for out-of-hospital cardiac arrest in a mixed urban and rural setting. Resuscitation 2006, 71, 180–187. [Google Scholar] [CrossRef]
- Kennedy Space Center Automated External Defibrillator (AED) Program—Home Page. Available online: https://aed.ksc.nasa.gov/FAQs/AED%20FAQs (accessed on 12 January 2021).
- Sleightholm, K. Non-Shockable Rhythms. The First Aid Show. 2019. Available online: https://www.firstaidshow.com/non-shockable-rhythms/ (accessed on 12 January 2021).
- The Shocking Truth About Defibrillators—IEEE Spectrum. IEEE Spectrum: Technology, Engineering, and Science News. Available online: https://spectrum.ieee.org/biomedical/devices/the-shocking-truth-about-defibrillators (accessed on 12 January 2021).
- Js, S.; Wh, M. Recalls and safety alerts affecting automated external defibrillators. JAMA 2006, 296, 655–660. [Google Scholar] [CrossRef] [Green Version]
- Amarappa, S.; Sathyanarayana, D.S.V. Data classification using Support vector Machine (SVM), a simplified approach. Int. J. Electron. Comput. Sci. Eng. 2014, 3, 435–445. [Google Scholar]
- Nguyen, M.T.; Kiseon, K. Feature Learning Using Convolutional Neural Network for Cardiac Arrest Detection. In Proceedings of the 2018 International Conference on Smart Green Technology in Electrical and Information Systems (ICSGTEIS), Bali, Indonesia, 25–27 October 2018; pp. 39–42. [Google Scholar]
- Isasi, I.; Irusta, U.; Aramendi, E.; Eftestøl, T.; Kramer-Johansen, J.; Wik, L. Rhythm Analysis during Cardiopulmonary Resuscitation Using Convolutional Neural Networks. Entropy 2020, 22, 595. [Google Scholar] [CrossRef]
- Acharya, U.R.; Fujita, H.; Oh, S.L.; Raghavendra, U.; Tan, J.H.; Adam, M.; Gertych, A.; Hagiwara, Y. Automated identification of shockable and non-shockable life-threatening ventricular arrhythmias using convolutional neural network. Future Gener. Comput. Syst. 2018, 79, 952–959. [Google Scholar] [CrossRef]
- Deep Feature Learning for Sudden Cardiac Arrest Detection in Automated External Defibrillators. Abstract—Europe PMC. Available online: http://europepmc.org/article/PMC/6249221 (accessed on 12 January 2021).
- Picon, A.; Irusta, U.; Álvarez-Gila, A.; Aramendi, E.; Alonso-Atienza, F.; Figuera, C.; Ayala, U.; Garrote, E.; Wik, L.; Kramer-Johansen, J.; et al. Mixed convolutional and long short-term memory network for the detection of lethal ventricular arrhythmia. PLoS ONE 2019, 14, e0216756. [Google Scholar] [CrossRef] [Green Version]
- Krasteva, V.; Ménétré, S.; Didon, J.-P.; Jekova, I. Fully Convolutional Deep Neural Networks with Optimized Hyperparameters for Detection of Shockable and Non-Shockable Rhythms. Sensors 2020, 20, 2875. [Google Scholar] [CrossRef]
- Hammad, M.; Kandala, R.N.V.P.S.; Abdelatey, A.; Abdar, M.; Zomorodi-Moghadam, M.; Tan, R.S.; Acharya, U.R.; Pławiak, J.; Tadeusiewicz, R.; Makarenkov, V.; et al. Automated detection of shockable ECG signals: A review. Inf. Sci. 2021, 571, 580–604. [Google Scholar] [CrossRef]
- Sannino, G.; De Pietro, G. A deep learning approach for ECG-based heartbeat classification for arrhythmia detection. Future Gener. Comput. Syst. 2018, 86, 446–455. [Google Scholar] [CrossRef]
- Kanellopoulos, D. Handling imbalanced datasets: A review. Int. Trans. 2006. Available online: https://www.academia.edu/16613336/Handling_imbalanced_datasets_A_review (accessed on 18 May 2022).
- Shafqat, W.; Byun, Y.-C. A Hybrid GAN-Based Approach to Solve Imbalanced Data Problem in Recommendation Systems. IEEE Access 2022, 10, 11036–11047. [Google Scholar] [CrossRef]
- Haque, A. EC-GAN. 2022. Available online: https://github.com/ayaanzhaque/EC-GAN (accessed on 27 April 2022).
- Lee, J.; Park, K. GAN-based imbalanced data intrusion detection system. Pers. Ubiquitous Comput. 2021, 25, 121–128. [Google Scholar] [CrossRef]
- Haque, A. EC-GAN: Low-Sample Classification using Semi-Supervised Algorithms and GANs. arXiv 2021, arXiv:2012.15864. Available online: http://arxiv.org/abs/2012.15864 (accessed on 25 February 2022).
- Walia, M.; Tierney, B.; Mckeever, S. Synthesising Tabular Data using Wasserstein Conditional GANs with Gradient Penalty (WCGAN-GP). In Proceedings of the AICS, Dublin, Ireland, 7–8 December 2020. [Google Scholar] [CrossRef]
- Gulrajani, I.; Ahmed, F.; Arjovsky, M.; Dumoulin, V.; Courville, A. Improved Training of Wasserstein GANs. arXiv 2017, arXiv:1704.00028. Available online: http://arxiv.org/abs/1704.00028 (accessed on 8 March 2022).
- Zekan, M. WCGAN-GP. 2022. Available online: https://github.com/marzekan/WCGAN-GP (accessed on 27 October 2022).
- Dahal, K.; Ali, M.H. Overview of Machine Learning and Deep Learning Approaches for Detecting Shockable Rhythms in AED in the Absence or Presence of CPR. Electronics 2022, 11, 3593. [Google Scholar] [CrossRef]
- AHA. AHA Database Sample Excluded Record. 2003. Available online: https://physionet.org/content/ahadb/1.0.0/ (accessed on 16 December 2022).
- Greenwald, S.D. The MIT-BIH Malignant Ventricular Arrhythmia Database. 1992. Available online: https://physionet.org/content/vfdb/1.0.0/ (accessed on 16 December 2022).
- Nolle, F.M.; Bowser, R.W. Creighton University Ventricular Tachyarrhythmia Database. 1992. Available online: https://physionet.org/content/cudb/1.0.0/ (accessed on 16 December 2022).
- Felipe Alonso—Home Page. Available online: https://tsc.urjc.es/~falonso/ohca_data.html (accessed on 5 May 2022).
- Figuera, C.; Irusta, U.; Morgado, E.; Aramendi, E.; Ayala, U.; Wik, L.; Kramer-Johansen, J.; Eftestøl, T.; Alonso-Atienza, F. Machine Learning Techniques for the Detection of Shockable Rhythms in Automated External Defibrillators. PLoS ONE 2016, 11, e0159654. [Google Scholar] [CrossRef] [Green Version]
- Performance Aspects of Automated Rhythm Detection Capabilities for AEDs. HMP Global Learning Network. 2010. Available online: https://www.hmpgloballearningnetwork.com/site/eplab/articles/Performance-Aspects-Automated-Rhythm-Detection-Capabilities-AEDs (accessed on 11 January 2022).
- He, H.; Bai, Y.; Garcia, E.A.; Li, S. ADASYN: Adaptive synthetic sampling approach for imbalanced learning. In Proceedings of the 2008 IEEE International Joint Conference on Neural Networks (IEEE World Congress on Computational Intelligence), Hong Kong, China, 1–8 June 2008; pp. 1322–1328. [Google Scholar]
- Cao, Y.; Zhao, X.; Zhou, Z.; Chen, Y.; Liu, X.; Lang, Y. MIAC: Mutual-Information Classifier with ADASYN for Imbalanced Classification. In Proceedings of the 2018 International Conference on Security, Pattern Analysis, and Cybernetics (SPAC), Jinan, China, 14–17 December 2018; pp. 494–498. [Google Scholar]
- Shaker, A.M.; Tantawi, M.; Shedeed, H.A.; Tolba, M.F. Deep Convolutional Neural Networks for ECG Heartbeat Classification Using Two-Stage Hierarchical Method. In Proceedings of the International Conference on Advanced Intelligent Systems and Informatics 2020; Hassanien, A.E., Slowik, A., Snášel, V., El-Deeb, H., Tolba, F.M., Eds.; Springer International Publishing: Cham, Switzerland, 2021; pp. 137–147. [Google Scholar]
- Pham, T.-H.; Sree, V.; Mapes, J.; Dua, S.; Lih, O.S.; Koh, J.E.W.; Ciaccio, E.J.; Acharya, U.R. A novel machine learning framework for automated detection of arrhythmias in ECG segments. J. Ambient Intell. Humaniz. Comput. 2021, 12, 10145–10162. [Google Scholar] [CrossRef]
- Deep Convolutional Neural Networks—Run:AI. Available online: https://www.run.ai/guides/deep-learning-for-computer-vision/deep-convolutional-neural-networks/ (accessed on 3 January 2022).
- Shewalkar, A.; Nyavanandi, D.; Ludwig, S.A. Performance Evaluation of Deep Neural Networks Applied to Speech Recognition: RNN, LSTM and GRU. J. Artif. Intell. Soft Comput. Res. 2019, 9, 235–245. [Google Scholar] [CrossRef] [Green Version]
- Yamashita, R.; Nishio, M.; Do, R.K.G.; Togashi, K. Convolutional neural networks: An overview and application in radiology. Insights Imaging 2018, 9, 611–629. [Google Scholar] [CrossRef] [Green Version]
- Ebrahimi, Z.; Loni, M.; Daneshtalab, M.; Gharehbaghi, A. A review on deep learning methods for ECG arrhythmia classification. Expert Syst. Appl. X 2020, 7, 100033. [Google Scholar] [CrossRef]
- Al-Saffar, A.A.M.; Tao, H.; Talab, M.A. Review of deep convolution neural network in image classification. In Proceedings of the 2017 International Conference on Radar, Antenna, Microwave, Electronics, and Telecommunications (ICRAMET), Jakarta, Indonesia, 23–24 October 2017; pp. 26–31. [Google Scholar]
- Hochreiter, S.; Schmidhuber, J. Long Short-Term Memory. Neural Comput. 1997, 9, 1735–1780. [Google Scholar] [CrossRef] [PubMed]
- Graves, A.; Schmidhuber, J. Framewise phoneme classification with bidirectional LSTM and other neural network architectures. Neural Netw. 2005, 18, 602–610. [Google Scholar] [CrossRef] [PubMed]
- Zhao, R.; Wang, D.; Yan, R.; Mao, K.; Shen, F.; Wang, J. Machine Health Monitoring Using Local Feature-Based Gated Recurrent Unit Networks. IEEE Trans. Ind. Electron. 2018, 65, 1539–1548. [Google Scholar] [CrossRef]
- Kostadinov, S. How Recurrent Neural Networks Work. Available online: https://towardsdatascience.com/learn-how-recurrent-neural-networks-work-84e975feaaf7 (accessed on 4 December 2021).
- Nishiyama, T.; Nishiyama, A.; Negishi, M.; Kashimura, S.; Katsumata, Y.; Kimura, T.; Nishiyama, N.; Tanimoto, Y.; Aizawa, Y.; Mitamura, H.; et al. Diagnostic Accuracy of Commercially Available Automated External Defibrillators. J. Am. Heart Assoc. 2015, 4, e002465. [Google Scholar] [CrossRef] [Green Version]
- Basnet, M.; Ali, M.H. Deep Learning-based Intrusion Detection System for Electric Vehicle Charging Station. In Proceedings of the 2020 2nd International Conference on Smart Power Internet Energy Systems (SPIES), Bangkok, Thailand, 15–18 September 2020; pp. 408–413. [Google Scholar]
- Statistics with Confidence: Confidence Intervals and Statistical Guidelines, 2nd ed.; Altman, D.G. (Ed.) BMJ Books: London, UK, 2011. [Google Scholar]
- Confidence Intervals for Sensitivity and Specificity in Python. Available online: https://gist.github.com/maidens/29939b3383a5e57935491303cf0d8e0b (accessed on 20 April 2022).
- De Gauna, S.R.; Irusta, U.; Ruiz, J.; Ayala, U.; Aramendi, E.; Eftestøl, T. Rhythm Analysis during Cardiopulmonary Resuscitation: Past, Present, and Future. BioMed Res. Int. 2014, 2014, e386010. [Google Scholar] [CrossRef]
- American Heart Association. Compression-Only CPR Increases Survival of Out-Of-Hospital Cardiac Arrest. Available online: https://medicalxpress.com/news/2019-04-compression-only-cpr-survival-out-of-hospital-cardiac.html (accessed on 16 March 2021).
Public Database | Patients | Sh | NSh |
---|---|---|---|
VFDB | 22 | 1586 | 7761 |
CUDB | 35 | 716 | 2986 |
AHADB | 10 | 1276 | 3748 |
Total | 67 | 3578 | 14,495 |
Label | Count | Ratio (%) |
---|---|---|
10 | 11,098 | 61.40 |
19 | 2698 | 14.92 |
6 | 1028 | 5.68 |
2 | 855 | 4.73 |
21 | 780 | 4.31 |
11 | 433 | 2.39 |
16 | 373 | 2.06 |
13 | 364 | 2.01 |
8 | 203 | 1.12 |
5 | 125 | 0.69 |
20 | 100 | 0.55 |
18 | 10 | 0.05 |
15 | 6 | 0.03 |
Shockable (Sh) | Non-Shockable (NSh) | ||
---|---|---|---|
AED algorithm decision | Shock | True Positive (TP) | False Positive (FP) |
No Shock | False Negative (FN) | True Negative (TN) |
Models | Se (>90%) | Sp (>95%) | BER |
---|---|---|---|
EC–WCGAN (Using real and generated test data) | 99.16 | 99.67 | 0.005 |
EC–WCGAN (Using only real test data) | 96.76 | 99.54 | 0.01 |
CNN | 99.90 | 95.40 | 0.02 |
DCNN | 99.72 | 94.98 | 0.02 |
DNN | 99.72 | 93.30 | 0.03 |
LSTM | 99.90 | 94.75 | 0.02 |
GRU | 99.81 | 92.38 | 0.03 |
RNN | 99.72 | 90.34 | 0.04 |
Models | Precision | Recall | F1-Score |
---|---|---|---|
EC–WCGAN (using real and generated test data) | 0.99 | 0.99 | 0.99 |
EC–WCGAN (using only real test data) | 0.98 | 0.96 | 0.97 |
CNN | 0.84 | 0.99 | 0.91 |
DCNN | 0.83 | 0.99 | 0.91 |
DNN | 0.79 | 0.99 | 0.88 |
RNN | 0.71 | 0.99 | 0.83 |
LSTM | 0.81 | 0.99 | 0.90 |
GRU | 0.73 | 0.99 | 0.84 |
Proposed Model | Data | Precision | Recall | F1-Score |
---|---|---|---|---|
EC–WCGAN | Shockable rhythm (1) | 0.9965 | 0.9916 | 0.9940 |
Non-shockable rhythm (0) | 0.9922 | 0.9967 | 0.9945 |
Proposed Model | Label | Precision | Recall | F1-Score |
---|---|---|---|---|
EC–WCGAN | 10 | 0.89 | 0.97 | 0.93 |
11 | 0.63 | 0.99 | 0.77 | |
13 | 0.87 | 0.95 | 0.91 | |
15 | 0.98 | 0.98 | 0.98 | |
16 | 0.96 | 0.99 | 0.97 | |
18 | 0.95 | 0.99 | 0.97 | |
19 | 0.95 | 0.95 | 0.95 | |
2 | 0.92 | 0.07 | 0.13 | |
20 | 0.99 | 0.99 | 0.99 | |
21 | 0.97 | 0.93 | 0.95 | |
5 | 0.97 | 0.98 | 0.98 | |
6 | 0.85 | 0.99 | 0.92 | |
8 | 0.98 | 0.97 | 0.98 |
Ref | Type of Method | Approaches | Segments | Acc (%) | Se (%) | Sp (%) | BER | Database |
---|---|---|---|---|---|---|---|---|
EC–WCGAN (Using real and generated test data) | DNN, GAN | 4 s | 99.45 | 99.18 | 99.70 | 0.005 | AHADB, CUDB, VFDB | |
EC–WCGAN (Using only real test data) | DNN, GAN | 4 s | 99.45 | 96.76 | 99.54 | 0.018 | AHADB, CUDB, VFDB | |
[11] | DL | CNN | 2 s | 93.18 | 95.32 | 91.04 | N/A | MITB, VFDB, CUDB |
[12] | DL and ML | CNN, BS, MVMD | 8 s | 99.26 | 97.07 | 99.44 | 0.017 | VFDB, CUDB |
[9] | DL and ML | CNN, SVM, MVMD | 5 s | 99.02 | 95.21 | 99.31 | 0.027 | VFDB, CUDB |
[13] | DL and ML | CNN, LSTM | 4 s 4 s 2 s 2 s | 99.3 98.0 95.2 98.1 | 99.7 99.2 97.5 97.5 | 98.9 96.7 93.6 97.5 | 0.007 0.020 N/A N/A | Public OHCA OHCA Public |
[14] | DL | DCNN, HP-optimization | 5 s 2 s | 99.5 98.2 | 99.6 97.6 | 99.4 98.7 | 0.005 0.018 | OCHA |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2022 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Dahal, K.; Ali, M.H. A Hybrid GAN-Based DL Approach for the Automatic Detection of Shockable Rhythms in AED for Solving Imbalanced Data Problems. Electronics 2023, 12, 13. https://doi.org/10.3390/electronics12010013
Dahal K, Ali MH. A Hybrid GAN-Based DL Approach for the Automatic Detection of Shockable Rhythms in AED for Solving Imbalanced Data Problems. Electronics. 2023; 12(1):13. https://doi.org/10.3390/electronics12010013
Chicago/Turabian StyleDahal, Kamana, and Mohd. Hasan Ali. 2023. "A Hybrid GAN-Based DL Approach for the Automatic Detection of Shockable Rhythms in AED for Solving Imbalanced Data Problems" Electronics 12, no. 1: 13. https://doi.org/10.3390/electronics12010013
APA StyleDahal, K., & Ali, M. H. (2023). A Hybrid GAN-Based DL Approach for the Automatic Detection of Shockable Rhythms in AED for Solving Imbalanced Data Problems. Electronics, 12(1), 13. https://doi.org/10.3390/electronics12010013