Open AccessOpen Access


Classification of Electroencephalogram Signals Using LSTM and SVM Based on Fast Walsh-Hadamard Transform

Saeed Mohsen1,2,*, Sherif S. M. Ghoneim3, Mohammed S. Alzaidi3, Abdullah Alzahrani3, Ashraf Mohamed Ali Hassan4

1 Electronics and Communications Engineering Department, Al-Madinah Higher Institute for Engineering and Technology, Giza, 12947, Egypt
2 Department of Artificial Intelligence Engineering, Faculty of Computer Science and Engineering, King Salman International University (KSIU), South Sinai, 46511, Egypt
3 Department of Electrical Engineering, College of Engineering, Taif University, Taif, 21944, Saudi Arabia
4 Department of Electronics and Communications Engineering, October High Institute for Engineering and Technology, 6th of October City, Giza, 12596, Egypt

* Corresponding Author: Saeed Mohsen. Email:

Computers, Materials & Continua 2023, 75(3), 5271-5286.


Classification of electroencephalogram (EEG) signals for humans can be achieved via artificial intelligence (AI) techniques. Especially, the EEG signals associated with seizure epilepsy can be detected to distinguish between epileptic and non-epileptic regions. From this perspective, an automated AI technique with a digital processing method can be used to improve these signals. This paper proposes two classifiers: long short-term memory (LSTM) and support vector machine (SVM) for the classification of seizure and non-seizure EEG signals. These classifiers are applied to a public dataset, namely the University of Bonn, which consists of 2 classes –seizure and non-seizure. In addition, a fast Walsh-Hadamard Transform (FWHT) technique is implemented to analyze the EEG signals within the recurrence space of the brain. Thus, Hadamard coefficients of the EEG signals are obtained via the FWHT. Moreover, the FWHT is contributed to generate an efficient derivation of seizure EEG recordings from non-seizure EEG recordings. Also, a k-fold cross-validation technique is applied to validate the performance of the proposed classifiers. The LSTM classifier provides the best performance, with a testing accuracy of 99.00%. The training and testing loss rates for the LSTM are 0.0029 and 0.0602, respectively, while the weighted average precision, recall, and F1-score for the LSTM are 99.00%. The results of the SVM classifier in terms of accuracy, sensitivity, and specificity reached 91%, 93.52%, and 91.3%, respectively. The computational time consumed for the training of the LSTM and SVM is 2000 and 2500 s, respectively. The results show that the LSTM classifier provides better performance than SVM in the classification of EEG signals. Eventually, the proposed classifiers provide high classification accuracy compared to previously published classifiers.


Cite This Article

S. Mohsen, S. S. M. Ghoneim, M. S. Alzaidi, A. Alzahrani and A. M. Ali Hassan, "Classification of electroencephalogram signals using lstm and svm based on fast walsh-hadamard transform," Computers, Materials & Continua, vol. 75, no.3, pp. 5271–5286, 2023.

This work is licensed under a Creative Commons Attribution 4.0 International License , which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.
  • 459


  • 247


  • 0


Share Link