Epilepsy Detection by Using Scalogram Based Convolutional Neural Network from EEG Signals
Abstract
:1. Introduction
 (a)
 Studies Based on Conventional Methods
 (b)
 Studies Based on Deep Learning Methods
2. Materials Methods
2.1. Dataset
2.2. Methods
2.2.1. Continuous Wavelet Transform (CWT)
2.2.2. Resize Images
2.2.3. Convolutional Neural Network (CNN)
2.2.4. Structure and Training of the Proposed CNN
2.2.5. Performance Evaluation
3. Results
4. Discussion
 No feature has been obtained from the EEG dataset. At the same time, no size reduction method was used.
 Frequencytime scalograms of raw EEG data were evaluated directly in the CNN structure.
 The comparison of all classes was performed to evaluate the success of the proposed method. It has been found that the proposed method can successfully distinguish each data set with its own characteristic.
 It has been observed that the method used in the study provides a much better success than the methods used in the literature, especially when the data set diversity increases.
Author Contributions
Funding
Conflicts of Interest
Abbreviations
CNN  Convolutional Neural Network 
CWT  Continuous Wavelet Transform 
TQWT  TunableQ Wavelet Transform 
DWT  Discrete Wavelet Transform 
SE  Shannon Entropy 
SD  Standard Deviation 
BP  Band Power 
SVM  Support Vector Machine 
LMD  Local Mean Decomposition 
GA  Genetic Algorithm 
RF  Random Forest 
SVML  Linear Basis Function Based Support Vector Machine 
FFT  Fast Fourier Transform 
1DLBP  One Dimensional Local Binary Pattern 
CEEMDAN  Complete Ensemble Empirical Mode Decomposition with Adaptive Noise 
DTCWT  DualTree Complex Wavelet Transform 
GRNN  General Regression Neural Network 
MEMD  Multivariate Empirical Mode Decomposition 
EMD  Empirical Mode Decomposition 
PCA  Principal Component Analysis 
LSSVM  Least Squares Version of Support Vector Machine 
ME  Mixture of experts 
IMFs  Intrinsic Mode Functions 
ApEn  Approximate entropy 
SDAE  Stacked Denoising Autoencoders 
References
 Başar, E.; BaşarEroglu, C.; Karakaş, S.; Schürmann, M. Gamma, alpha, delta, and theta oscillations govern cognitive processes. Int. J. Psychophysiol. 2001, 39, 241–248. [Google Scholar] [CrossRef]
 Ramele, R.; Villar, A.; Santos, J. EEG Waveform Analysis of P300 ERP with Applications to Brain Computer Interfaces. Brain Sci. 2018, 8, 199. [Google Scholar] [CrossRef] [PubMed]
 Kiloh, L.G.; McComas, A.J.; Osselton, J.W. Clinical Electroencephalography; ButterworthHeinemann: Boston, MS, USA, 2013. [Google Scholar]
 Fisher, R.S.; Boas, W.V.E.; Blume, W.; Elger, C.; Genton, P.; Lee, P.; Engel, J., Jr. Epileptic seizures and epilepsy: Definitions proposed by the International League Against Epilepsy (ILAE) and the International Bureau for Epilepsy (IBE). Epilepsia 2005, 46, 470–472. [Google Scholar] [CrossRef]
 Acharya, U.R.; Sree, S.V.; Swapna, G.; Martis, R.J.; Suri, J.S. Automated EEG analysis of epilepsy: A review. Knowl.Based Syst. 2013, 45, 147–165. [Google Scholar]
 Bonn Dataset. Available online: http://www.meb.unibonn.de/epileptologie/science/physik/eegdata.html (accessed on 17 December 2018).
 MotamediFakhr, S.; MoshrefiTorbati, M.; Hill, M.; Hill, C.M.; White, P.R. Signal processing techniques applied to human sleep EEG signals—A review. Biomed. Signal Proces. 2014, 10, 21–33. [Google Scholar] [CrossRef]
 Subasi, A. EEG signal classification using wavelet feature extraction and a mixture of expert model. Expert Syst. Appl. 2007, 32, 1084–1093. [Google Scholar] [CrossRef]
 Chandaka, S.; Chatterjee, A.; Munshi, S. Crosscorrelation aided support vector machine classifier for classification of EEG signals. Expert Syst. Appl. 2009, 36, 1329–1336. [Google Scholar] [CrossRef]
 Li, S.; Zhou, W.; Yuan, Q.; Geng, S.; Cai, D. Feature extraction and recognition of ictal EEG using EMD and SVM. Comput. Biol. Med. 2013, 43, 807–816. [Google Scholar] [CrossRef] [PubMed]
 Kaya, Y.; Uyar, M.; Tekin, R.; Yıldırım, S. 1Dlocal binary pattern based feature extraction for classification of epileptic EEG signals. Appl. Math. Comput. 2014, 243, 209–219. [Google Scholar] [CrossRef]
 Xiang, J.; Li, C.; Li, H.; Cao, R.; Wang, B.; Han, X.; Chen, J. The detection of epileptic seizure signals based on fuzzy entropy. J. Neurosci. Methods 2015, 243, 18–25. [Google Scholar] [CrossRef]
 Kumar, Y.; Dewal, M.L.; Anand, R.S. Epileptic seizure detection using DWT based fuzzy approximate entropy and support vector machine. Neurocomputing 2014, 133, 271–279. [Google Scholar] [CrossRef]
 Bhattacharyya, A.; Pachori, R.; Upadhyay, A.; Acharya, U. TunableQ wavelet transform based multiscale entropy measure for automated classification of epileptic EEG signals. Appl. Sci. 2017, 7, 385. [Google Scholar] [CrossRef]
 Jia, J.; Goparaju, B.; Song, J.; Zhang, R.; Westover, M.B. Automated identification of epileptic seizures in EEG signals based on phase space representation and statistical features in the CEEMD domain. Biomed. Signal Proces. 2017, 38, 148–157. [Google Scholar] [CrossRef]
 Zahra, A.; Kanwal, N.; urRehman, N.; Ehsan, S.; McDonaldMaier, K.D. Seizure detection from EEG signals using multivariate empirical mode decomposition. Comput. Biol. Med. 2017, 88, 132–141. [Google Scholar] [CrossRef] [PubMed]
 Sharmila, A.; Aman Raj, S.; Shashank, P.; Mahalakshmi, P. Epileptic seizure detection using DWTbased approximate entropy, Shannon entropy and support vector machine: a case study. J. Med. Eng. Technol. 2018, 42, 1–8. [Google Scholar] [CrossRef]
 Lu, Y.; Ma, Y.; Chen, C.; Wang, Y.; Gómez, C.; Schwarzacher, S.P.; Zhou, H. Classification of singlechannel EEG signals for epileptic seizures detection based on hybrid features. Technol. Heal. Care 2018, 26, 337–346. [Google Scholar] [CrossRef] [PubMed]
 Ibrahim, S.; Djemal, R.; Alsuwailem, A. Electroencephalography (EEG) signal processing for epilepsy and autism spectrum disorder diagnosis. Biocybern. Biomed. Eng. 2018, 38, 16–26. [Google Scholar] [CrossRef]
 Ullah, I.; Hussain, M.; Aboalsamh, H. An automated system for epilepsy detection using EEG brain signals based on deep learning approach. Expert Syst. Appl. 2018, 107, 61–71. [Google Scholar] [CrossRef]
 Hussein, R.; Elgendi, M.; Wang, Z.J.; Ward, R.K. Robust detection of epileptic seizures based on L1penalized robust regression of EEG signals. Expert Syst. Appl. 2018, 104, 153–167. [Google Scholar] [CrossRef]
 Yuan, Y.; Xun, G.; Jia, K.; Zhang, A. A novel waveletbased model for eeg epileptic seizure detection using multicontext learning. In Proceedings of the 2017 IEEE International Conference on Bioinformatics and Biomedicine (BIBM), Kansas City, MO, USA, 13–16 November 2017; IEEE: Piscataway, NJ, USA; pp. 694–699. [Google Scholar] [CrossRef]
 Acharya, U.R.U.R.; Oh, S.L.; Hagiwara, Y.; Tan, J.H.; Adeli, H. Deep convolutional neural network for the automated detection and diagnosis of seizure using EEG signals. Comput. Boil. Med. 2018, 100, 270–278. [Google Scholar] [CrossRef]
 Misiti, M.; Misiti, Y.; Oppenheim, G.; Poggi, J.M. Wavelets and Their Applications; John Wiley & Sons: Great Britain, UK, 2013. [Google Scholar]
 Falamarzi, Y.; Palizdan, N.; Huang, Y.F.; Lee, T.S. Estimating evapotranspiration from temperature and wind speed data using artificial and wavelet neural networks (WNNs). Agric. Water Manag. 2014, 140, 26–36. [Google Scholar] [CrossRef]
 Li, B.; Chen, X. Waveletbased numerical analysis: A review and classification. Finite. Elem. Anal. Des. 2014, 81, 14–31. [Google Scholar] [CrossRef]
 Michael, U. A review of wavelets in biomedical applications. Proc. IEEE 1996, 84, 626–638. [Google Scholar]
 Mouraux, A.; Iannetti, G.D. Acrosstrial averaging of eventrelated EEG responses and beyond. Magn. Reson. Imaging 2008, 26, 1041–1054. [Google Scholar] [CrossRef]
 Peng, Z.; Chu, F.; He, Y. Vibration signal analysis and feature extraction based on reassigned wavelet scalogram. J. Sound Vib. 2002, 253, 1087–1100. [Google Scholar] [CrossRef]
 Kareem, A.; Kijewski, T. Timefrequency analysis of wind effects on structures. J. Wind Eng. Ind. Aerod. 2002, 90, 1435–1452. [Google Scholar] [CrossRef]
 Yi, D.; Lei, Z.; Liao, S.; Li, S.Z. Deep metric learning for person reidentification. In Proceedings of the 2014 22nd International Conference on Pattern Recognition, Stockholm, Sweden, 24–28 August 2014; IEEE: Piscataway, NJ, USA; pp. 34–39. [Google Scholar]
 Poultney, C.; Chopra, S.; Cun, Y.L. Efficient Learning of Sparse Representations with an EnergyBased Model. Available online: http://papers.nips.cc/paper/3112efficientlearningofsparserepresentationswithanenergybasedmodel.pdf (accessed on 21 January 2019).
 Guo, Y.; Liu, Y.; Oerlemans, A.; Lao, S.; Wu, S.; Lew, M.S. Deep learning for visual understanding: A review. Neurocomputing 2016, 187, 27–48. [Google Scholar] [CrossRef]
 Wang, H.; Raj, B. On the Origin of Deep Learning. Available online: https://arxiv.org/abs/1702.07800 (accessed on 21 January 2019).
 Uktveris, T.; Jusas, V. Application of Convolutional Neural Networks to FourClass Motor Imagery Classification Problem. Inf. Technol. 2017, 46, 260–273. [Google Scholar] [CrossRef]
 Boureau, Y.L.; Ponce, J.; LeCun, Y. A theoretical analysis of feature pooling in visual recognition. In Proceedings of the 27th International Conference on Machine Learning (ICML 2010), Haifa, Israel, 21–24 June 2010; pp. 111–118. [Google Scholar]
 Lin, M.; Chen, Q.; Yan, S. Network in Network. Available online: https://arxiv.org/abs/1312.4400 (accessed on 19 December 2018).
 Sokolova, M.; Japkowicz, N.; Szpakowicz, S. Beyond accuracy, Fscore and ROC: a family of discriminant measures for performance evaluation. In Australasian Joint Conference on Artificial Intelligence; Springer: Berlin/Heidelberg, Germany, 2006; pp. 1015–1021. [Google Scholar]
 Wang, X.; Gong, G.; Li, N. Automated Recognition of Epileptic EEG States Using a Combination of Symlet Wavelet Processing, Gradient Boosting Machine, and Grid Search Optimizer. Sensors 2019, 19, 219. [Google Scholar] [CrossRef]
 Swami, P.; Gandhi, T.K.; Panigrahi, B.K.; Tripathi, M.; Anand, S. A novel robust diagnostic model to detect seizures in electroencephalography. Expert Syst. Appl. 2016, 56, 116–130. [Google Scholar] [CrossRef]
 Polat, K.; Güneş, S. Classification of epileptiform EEG using a hybrid system based on decision tree classifier and fast Fourier transform. Appl. Math. Comput. 2007, 187, 1017–1026. [Google Scholar] [CrossRef]
 Lee, S.H.; Lim, J.S.; Kim, J.K.; Yang, J.; Lee, Y. Classification of normal and epileptic seizure EEG signals using wavelet transform, phasespace reconstruction, and Euclidean distance. Comput. Meth. Prog. Bio. 2014, 116, 10–25. [Google Scholar] [CrossRef] [PubMed]
 Nigam, V.P.; Graupe, D. A neuralnetworkbased detection of epilepsy. Neurol. Res. 2004, 26, 55–60. [Google Scholar] [CrossRef] [PubMed]
 Zhang, T.; Chen, W. LMD based features for the automatic seizure detection of EEG signals using SVM. IEEE T. Neur. Sys. Reh. 2017, 25, 1100–1108. [Google Scholar] [CrossRef]
 Tawfik, N.S.; Youssef, S.M.; Kholief, M. A hybrid automated detection of epileptic seizures in EEG records. Comput. Electr. Eng. 2016, 53, 177–190. [Google Scholar] [CrossRef]
A  B  C  D  E 

Healthy  Healthy  Epilepsy Patient  Epilepsy Patient  Epilepsy Patient 
Total of 100 segments  Total of 100 segments  Total of 100 segments  Total of 100 segments  Total of 100 segments 
Duration of each segment 23.6s  Duration of each segment 23.6s  Duration of each segment 23.6s  Duration of each segment 23.6s  Duration of each segment 23.6s 
Eyes open recording  Eyes closed recording  PreSeizure, recording from the hippocampal half sphere  Preseizure, record from the epileptic area  Record during the seizure 
Layer  Filter Size  Number of Filters  Number of Neurons  Stride 

Conv1  5 × 5  16    1 
MaxPooling        2 
Conv2  5 × 5  64    1 
MaxPooling        2 
FullyConnected      1000   
Data Set Taken into Consideration  Total Number of Images  Number of Images Used for Training  Number of Images Used for Validation  Number of Images Used for Testing  Number of Classes at CNN Output 

Two  200  144  36  20  2 
Three  300  216  54  30  3 
Four  400  288  72  40  4 
Five  500  360  90  50  5 
Predicted Class  

Original  Class = 1  Class = 0  
Class = 1  True Positive (TP)  (False Positive) FP  
Class = 0  (False Negative) FN  (True Negative) TN  
$$\mathrm{Accuracy}=\frac{\mathrm{TP}+\mathrm{TN}}{\mathrm{TP}+\mathrm{FP}+\mathrm{FN}+\mathrm{TN}}$$
 
$$\mathrm{Sensitivity}=\frac{\mathrm{TP}}{\mathrm{TP}+\mathrm{FP}}$$
 
$$\mathrm{Specificity}=\frac{\mathrm{TN}}{\mathrm{FP}+\mathrm{TN}}$$
 
$$\mathrm{Precision}=\frac{\mathrm{TP}}{\mathrm{TP}+\mathrm{FP}}$$
 
$$\mathrm{Recall}=\frac{\mathrm{TP}}{\mathrm{TP}+\mathrm{FN}}$$
 
$$\mathrm{F}\mathrm{Score}=2\times \frac{\mathrm{Precision}\times \mathrm{Recall}}{\mathrm{Precision}+\mathrm{Recall}}$$

Predicted  Accuracy (%)  Sensitivity (%)  Specificity (%)  f Score (%)  

A  B  
AB  Original  A  97  3  95.50  94.17  96.90  95.50 
B  6  94  
Predicted  
A  C  96.50  98.94  94.28  96.41  
AC  Original  A  94  6  
C  1  99  
Predicted  
A  D  100  100  100  100  
AD  Original  A  100  0  
D  0  100  
Predicted  
A  E  99.50  99.00  100  99.50  
AE  Original  A  100  0  
E  1  99  
Predicted  
B  C  99.00  99.00  99.00  99.00  
BC  Original  B  99  1  
C  1  99  
Predicted  
B  D  100  100  100  100  
BD  Original  B  100  0  
D  0  100  
Predicted  
B  E  99.50  100  100  99.50  
BE  Original  B  100  0  
E  1  99  
Predicted  
C  D  80.00  75.86  85.71  81.48  
CD  Original  C  88  12  
D  28  72  
Predicted  
C  E  98.50  98.01  98.98  98.50  
CE  Original  C  99  1  
E  2  98  
Predicted  
D  E  98.50  98.01  98.98  98.50  
DE  Original  D  99  1  
E  2  98 
Predicted  Accuracy (%)  Sensitivity (%)  Specificity (%)  f Score (%)  
A  B  C  
ABC  Original  A  92  3  5  95.00  92.00  96.50  92.46 
B  5  95  0  97.26  95.00  94.44  95.95  
C  2  0  98  97.60  98.00  97.39  96.55  
Predicted  Accuracy (%)  Sensitivity (%)  Specificity (%)  f Score (%)  
A  B  D  
ABD  Original  A  96  2  2  96.99  96.00  97.48  95.52 
B  4  95  1  97.64  95.00  98.98  96.44  
D  1  0  99  98.63  99.00  98.45  98.01  
Predicted  Accuracy (%)  Sensitivity (%)  Specificity (%)  f Score (%)  
A  B  E  
ABE  Original  A  96  4  0  96.30  96.96  95.97  94.58 
B  5  95  0  96.63  95.00  97.46  95.00  
E  3  1  96  98.62  96.00  100  97.95  
Predicted  Accuracy (%)  Sensitivity (%)  Specificity (%)  f Score (%)  
A  C  D  
ACD  Original  A  94  4  2  95.65  94.00  96.59  94.00 
C  2  87  11  88.88  87.00  89.84  84.05  
D  1  16  83  89.79  83.00  93.29  94.69  
Predicted  Accuracy (%)  Sensitivity (%)  Specificity (%)  f Score (%)  
A  C  E  
ACE  Original  A  96  4  0  97.18  96.00  97.82  96.00 
C  3  97  0  93.55  97.00  91.79  91.07  
E  1  16  83  94.19  83.00  100  90.71  
Predicted  Accuracy (%)  Sensitivity (%)  Specificity (%)  f Score (%)  
B  C  D  
BCD  Original  B  98  1  1  98.56  98.00  98.87  98.00 
C  1  91  8  91.94  91.00  92.42  88.34  
D  1  14  85  91.94  85.00  95.45  87.62  
Predicted  Accuracy (%)  Sensitivity (%)  Specificity (%)  f Score (%)  
B  C  E  
BCE  Original  B  100  0  0  98.99  100  98.49  98.52 
C  1  99  0  99.32  99.00  99.49  99.00  
E  2  1  97  98.99  97.00  100  98.47  
Predicted  Accuracy (%)  Sensitivity (%)  Specificity (%)  f Score (%)  
B  D  E  
BDE  Original  B  100  0  0  98.98  100  98.47  98.52 
D  1  98  1  98.65  98.00  98.98  98.00  
E  2  2  96  98.32  96.00  99.49  97.46  
Predicted  Accuracy (%)  Sensitivity (%)  Specificity (%)  f Score (%)  
D  C  E  
DCE  Original  D  82  17  1  89.71  82.00  93.95  84.97 
C  10  88  2  84.89  88.00  83.83  79.63  
E  1  16  83  92.67  83.00  98.26  89.24  
Predicted  Accuracy (%)  Sensitivity (%)  Specificity (%)  f Score (%)  
A  D  E  
ADE  Original  A  100  0  0  99.00  100  98.50  98.52 
D  2  98  0  99.33  98.00  100  98.98  
E  1  0  99  99.66  99.00  100  99.49 
Predicted  Accuracy (%)  Sensitivity (%)  Specificity (%)  f Score (%)  
A  C  D  E  
ACDE  Original  A  98  1  1  0  96.79  98.00  96.35  94.23 
C  4  81  15  0  92.58  81.00  95.56  84.81  
D  5  9  85  1  91.87  85.00  94.21  84.15  
E  1  0  1  98  99.00  98.00  99.62  98.49  
Predicted  Accuracy (%)  Sensitivity (%)  Specificity (%)  f Score (%)  
B  C  D  E  
BCDE  Original  B  98  1  1  0  98.65  98.00  98.89  97.51 
C  1  86  13  0  92.89  86.00  95.23  86.00  
D  0  13  84  3  92.42  84.00  95.27  84.84  
E  2  0  0  98  98.65  98.00  98.89  97.51 
Predicted  Accuracy (%)  Sensitivity (%)  Specificity (%)  fScore (%)  

A  B  C  D  E  
ABCDE  Original  A  95  3  0  0  2  97.90  95.00  98.67  95.00 
B  3  97  0  0  0  98.52  97.00  98.93  96.51  
C  1  1  87  11  0  95.31  87.00  97.44  88.32  
D  0  0  10  90  0  95.70  90.00  97.17  89.55  
E  1  0  0  0  99  99.36  99.00  99.46  98.50 
Study  Method Used  Datasets  Success (%) 

[14]  TQWTBased MultiScale kNN entropy  AE  100 
[19]  DWT + SE/SD/BP + KNN/SVM  AE  100 
[39]  Wavelet Transform + PCA, GBM, RF, and SVM  AE  100 
[40]  LMD + GA + SVM  AE  100 
[21]  L1Penalized Robust Regression + RF  AE  100 
[13]  DWT + Fuzzy Approximate Entropy + SVML  AE  100 
[41]  FFT and Decision Tree  AE  98.70 
[42]  Wavelet Transform, Phase, Euclid Distance  AE  98.17 
[43]  Artificial Neural Networks  AE  97.50 
[11]  1DLBP and Bayes Net  AD  99.50 
[44]  LMD + GASVM  DE  98.10 
[39]  Wavelet Transform + PCA, GBM, RF, and SVM  DE  98.10 
[14]  TQWT KNN Entropy  DE  98.00 
[15]  CEEMDAN + RF  DE  98.00 
[40]  DTCWT + GRNN  DE  98.00 
[45]  Weighted Permutation Entropy + SVM  DE  96.50 
[13]  DWT + Fuzzy Approximate Entropy + SVML  DE  95.85 
[44]  LMD+GA+SVM  ADE  98.47 
[13]  DWT + Fuzzy Approximate Entropy + SVML  ADE  95.67 
[11]  1DLBPand Bayes Net (LBP all)  ADE  95.67 
[16]  MEMD +ANN  ABCDE  87.2% 
In this Study  CNN + Scalogram  AE  99.50 
CNN + Scalogram  AD  100  
CNN + Scalogram  DE  98.50  
CNN + Scalogram  ADE  99.00  
CNN + Scalogram  ABCDE  93.60 
© 2019 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 (http://creativecommons.org/licenses/by/4.0/).
Share and Cite
Türk, Ö.; Özerdem, M.S. Epilepsy Detection by Using Scalogram Based Convolutional Neural Network from EEG Signals. Brain Sci. 2019, 9, 115. https://doi.org/10.3390/brainsci9050115
Türk Ö, Özerdem MS. Epilepsy Detection by Using Scalogram Based Convolutional Neural Network from EEG Signals. Brain Sciences. 2019; 9(5):115. https://doi.org/10.3390/brainsci9050115
Chicago/Turabian StyleTürk, Ömer, and Mehmet Siraç Özerdem. 2019. "Epilepsy Detection by Using Scalogram Based Convolutional Neural Network from EEG Signals" Brain Sciences 9, no. 5: 115. https://doi.org/10.3390/brainsci9050115