Multi-Class EEG Classification for Brain Computer Interface - IJSER.org

5 downloads 0 Views 854KB Size Report
notion of a theta wave was introduced by Wolter and. Dovey in 1944 [9]. .... Rio de Janeiro - PUC-Rio. [8] Neep Hazarika Jean Zhu Chen Ah Chung ,Tsoi Alex.
International Journal of Scientific & Engineering Research, Volume 4, Issue 9, September-2013 ISSN 2229-5518

2304

Multi-Class EEG Classification for Brain Computer Interface Mythra H V, Veenakumari H M, Sanjeev Kubakaddi

Abstract— In this work EEG signals decomposition, reconstruction and classification is achieved for the brain computer interface.EEG signals are most widely used in the medical field to analyse the patient condition, because it contains much information about human task. From several studies it has been suggested that EEG can be used to detect the severity of several diseases such as CJD, Alzheimer's, dementia and schizophrenia, in addition, specific events (known patterns in electrical stimulation) can indicate epileptic seizures. In general, EEG data analysis has been performed to either predict or classify signals. For the decomposition of EEG signals Discrete wavelet transform is observed and for the classification purpose KNN classifier, SVM classifier and LDA are observed. SVM classifier reaches to 100% efficiency.

Index Terms—Electroencephalogram (EEG), Feature extraction, KNN classifier, LDA, SVM classifier, Wavelet decomposition, 10-20 electrode system

——————————  —————————— Different machine learning techniques for classification of 1 INTRODUCTION mental tasks from Electroencephalograph (EEG) signals is The Electroencephalogram signal is one of the most widely investigated, in that improvement for the BCI is done for used signal in bioinformatics due to its rich information this purpose Bayesian graphical network, Neural Network, about human tasks, EEG waves classification is done on Bayesian quadratic, Fisher linear and Hidden Markov normalized by using the Discrete wavelet transform (DWT) Model classifiers are applied to two known EEG datasets in with fast Fourier transform [1].Electroencephalogram repthe BCI field. The Bayesian network classifier is used for the resents complex irregular signal that may provide the infirst time in this work for classification of EEG signals [4]. formation about the underlying neural activities in the Brain Computer Interface (BCI) is designed using electroenbrain, EEG signals exhibit no stationary and extremely cephalogram (EEG) signals where the subjects have to think complex behaviour. The traditional methods, such as short of only a single mental task. The method uses spectral powterm Fourier transform and Gabor transform, are not suited er and power difference in 4 bands: delta and theta, beta, for localizing transient and patchy features of the signal [2]. alpha and gamma, in the experimental study, EEG signals Algorithm to do automatic sleep stage classification is done, were recorded from 4 subjects while they were thinking of 4 it consists of three modules. A wavelet packet transfordifferent mental tasks. Combinations of resting (baseline) mation (WPT) is applied to 30 seconds long epochs of EEG state and another mental task are studied at a time for each recordings to provide localized time-frequency inforsubject [5]. mation, a feature generator which quantifies the information and reduce the data set size, and an artificial neural network for doing optimal classification, the classification An EEG signal is a measurement of currents that results compared to those of a human expert reached a 70 flow during synaptic excitations of the dendrites of many to 80% of agreement [3]. pyramidal neurons in the cerebral cortex. When brain cells

IJSER

————————————————







Mythra H V currently persuing masters degree program in Electronics, ECE Department, Channabasaveswara Institute of technology, Gubbi-572 216, Tumkur, Karnataka, India E mail:[email protected] Veenakumari H M is working as Associate Professor, ECE Department,Channabasaveswara Institute of technology,Gubbi-572 216,Tumkur,KarnatakaIndia.Email:[email protected] Sanjeev Kubakaddi is working as Director, itie Knowledge Solutions, India. E-mail:[email protected]

(neurons) are activated, the synaptic currents are produced within the dendrites. This current generates a magnetic field measurable by electromyogram (EMG) machines and a secondary electrical field over the scalp measurable by EEG systems. There are five major brain waves distinguished by their different frequency ranges. These frequency bands from low to high frequencies respectively are called alpha (α), theta (θ), beta (β), delta (δ), and gamma (γ). The alpha and beta waves were introduced by Berger in 1929. Jasper and Andrews (1938) used the term ‘gamma’ to refer to the waves of above 30 Hz. The delta rhythm was introduced by Walter (1936) to designate all frequencies

IJSER © 2013 http://www.ijser.org

International Journal of Scientific & Engineering Research, Volume 4, Issue 9, September-2013 ISSN 2229-5518

below the alpha range. He also introduced theta waves as those having frequencies within the range of 4–7.5 Hz. The notion of a theta wave was introduced by Wolter and Dovey in 1944 [9].In this work EEG classification is done using wavelet transform and Fourier transform is used to observe the frequency component of each EEG band. For classification K nearest neighbour (KNN) and Support Vector machine (SVM) Classifiers are used.

2305

It includes Normalization of the EEG data which taken from any of the electrodes c3, c4, p3, p4, o1, o2 and Filtering. For filtering Bandpass equiripple filter 0-40 Hz and sampling frequency is 250 Hz is designed using Filter design tool in MATLAB. Normalized signal is passed through this filter. Data before normalization, after normalization and filtering is shown in bellow figure.

2. METHODOLOGY This methodology consists of four modules namely Data collection, Data pre-processing, Feature extraction, Testing and cross validation.

2.1 Data Collection EEG data used in this study are taken from standard dataset. Data is a cell array of cell arrays. Each individual cell array is made up of a subject string, task string, trial string, and data array. Each data array is 7 rows by 2500 columns. The 7 rows correspond to channels c3, c4, p3, p4, o1, o2, and EOG, and these electrodes are placed according to 10-20 electrodes system. Across columns are samples taken at 250 Hz for 10 seconds, for 2500 samples. For example, the first cell array looks like 'subject 1' 'baseline' 'trial 1'[7x2500 single]. Recordings were made with reference to electrically linked mastoids A1 and A2.EOG was recorded between the forehead above the left brow line and another on the left cheekbone. Recording was performed with a bank of Grass 7P511 amplifiers whose band pass analog filters were set at 0.1 to 100 Hz. Subjects 1 and 2 were employees of a university and were left-handed age 48 and right-handed age 39, respectively. Subjects 3 through 7 were right-handed college students between the age of 20 and 30 years old. All were mail subjects with the exception of Subject 5. Subjects performed five trials of each task in one day. They returned to do a second five trials on another day. Subjects 2 and 7 completed only one 5-trial session. Subject 5 completed three sessions. For more information see Alternative Modes of Communication between Man and Machine, Zachary A. Keirn, Masters Thesis in Electrical Engineering, Purdue University, December, 1988.

Fig.2. (a).Original signal, (b) Normalized signal, (c) Filtered signal

IJSER

2.3 Feature Extraction Filtered signal is wavelet decomposed into 6 levels using Daubechies `wavelet. The names of the Daubechies family wavelets are written dbN, where N is the order and db the "surname" of the wavelet. To extract Delta, Theta, Alpha, Beta, and Gama bans 6 level is sufficient. Statistical parameters like mean, minima, maxima, standard deviation are applied to the feature matrix. Bellow figure shows the concept of signal decomposition using DWT. The DWT means choosing subsets of the scales ( a ) and positions (b ) of the wavelet mother ψ (t). 𝛹(𝑎,𝑏) = 2𝑎/2 Ψ(2𝑎/2 (t-b)) (1)

Choosing scales and positions are based on powers of two, which are called dyadic scales and positions {𝑎𝑗 = 2−𝑗 ;𝑏𝑗,𝑘 = 2−𝑗 k} ( j and k integers). Equation (1) shows that it is possible to built a wavelet for any function by dilating a function 𝜓(𝑡) with a coefficient2𝑗 , and translating the resulting function on a grid whose interval is proportional to2−𝑗 .

Fig.1Electrode Placement.

2.2Data pre-processing IJSER © 2013 http://www.ijser.org

International Journal of Scientific & Engineering Research, Volume 4, Issue 9, September-2013 ISSN 2229-5518

Fig.3 Wavelet Decompsition Structure The amplitude spectrum of the Delta, Theta, Alpha, Beta, and Gama bands are shown bellow.

2306

will refer to as q. Ai and we wish to know its class. In KNN, the class of q is found as follows: 1. Find the k instances in the dataset that are closest to q. 2. These k instances then vote to determine the class of q.

Fig.4 Amplitude spectrum of Delta

Fig. 9 Query q is here being classified by its 3 nearest neighbours

Fig. 5 Amplitude spectrum of Theta

IJSER

The illustration below shows the basic idea behind Support Vector Machines. Here we see the original objects (left side of the schematic) mapped, i.e., rearranged, using a set of mathematical functions, known as kernels. The process of rearranging the objects is known as mapping (transformation). Note that in this new setting, the mapped objects (right side of the schematic) is linearly separable and, thus, instead of constructing the complex curve (left schematic), all we have to do is to find an optimal line that can separate the GREEN and the RED objects.

Fig. 6 Amplitude spectrum of Alpha

Fig. 7 Amplitude spectrum of Beta

Fig. 8 Amplitude spectrum of Gama

Fig. 10 Basic idea behind SVM

3 RESULTS 2.4Testing and cross validation For classification KNN and SVM classifiers are observed. K fold experiment is observed,in that if we choose 10 fold one sample is used for testing all other samples excluding testing sample are used for training. In KNN classifier we are given an instance q (the query), whose attributes we

KNN classifier gives 60% accuracy, SVM classifier gives 98% accuracy, and LDA gives 80 % accuracy. This can be shown from cp.ErrorRate, where cp is class performance object. When we execute cp.CountingMatrix in MATLAB command window we will get matrix, this matrix for KNN

IJSER © 2013 http://www.ijser.org

International Journal of Scientific & Engineering Research, Volume 4, Issue 9, September-2013 ISSN 2229-5518

classifier, SVM classifier and LDA are respectively shown bellow

2307

of classification, changing Training Data size can also add some advantages in good classification

ACKNOWLEDGMENT The authors wish to thank itie Knowledge Solution, Bangalore for the support given to this research.

KNN classifier: cp.CountingMatrix ans = 12 8 0

REFERENCES [1]

9 11 0

[2] [3]

SVM classifier: cp.CountingMatrix ans= 19 1 0

0 20 0

LDA: cp.CountingMatrix ans= 17 3 0

4 16 0

[4]

[5]

Maan M Shaker, "EEG Waves Classifier using Wavelet Transform and Fourier Transform", International Journal Of Biological and Life Science 1:2 2005 Joydeep Bhattacharya and Hellmuth Petsche, "Universality in Brain While Listening to Music", Proc. Royal Society Edgar Oropesa, Hans L. Cycon and Marc Jobert, "Sleep Stage Classification using Wavelet Transform and Neural Network ", International Computer Science Institute, TR- 99-008, March 30, 1999 Kouhyar Tavakolian, Faratash Vasefi, Kaveh Naziripour and Siamak Rezaei, " Mental Task Classification for Brain Computer Interface Applications, First Canadian student Conference on Biomedical Computing Ramaswamy Palaniappan, " Brain Computer Interface Design using Band Power Extracted During Mental Task", Dept. of Computer Science, University of Essex, Colchester, United Kingdom, Dept. of Computer Science, University of Essex, Colchester, United states Y. P. A. Yong, N. J. Hurley, and G. C. M. Silvestre, "SingleTrial EEG Classification for Brain-computer Interface Using Wavelet Decomposition", Department of Computer Science, University College Dublin, Belfield, Dublin 4, Ireland, Alexandre Ormiga G. Barbosa, David Ronald A. Diaz, Marley Maria B.R.Vellasco, MarcoAntonio Meggiolaro and Ricardo Tanscheit, "Mental Tasks Classification for a Non- invasive BCI Application" , Pontifical Catholic University of Rio de Janeiro - PUC-Rio Neep Hazarika Jean Zhu Chen Ah Chung ,Tsoi Alex Sergejew, "Classification of EEG signals using Wavelet Transform,0-7803-4137-6/97/$10.0001977 IEEE John Wiley & Sons, Ltd, " EEG Signal Processing", Saeid Sanei and J.A.Chambers, Centre of Digital Signal Processing, Cardiff University, UK 2007

IJSER [6]

[7]

In KNN case, in first column out of 20 samples 12 are correctly classified as group 1, 8 are misclassified as group 2, similarly for second column out of 20 samples, 11 are correctly classified as group 2 and 9 are misclassified as group 1. Diagonal elements are the correctly classified samples. Similarly for SVM and LDA.

4 CONCLUSION & FUTURE WORK Classification of EEG signal is observed with KNN and SVM classifier and LDA, out of which SVM is the best one. By adopting different classifiers with different statistical parameter can reduce the error rate and improve the degree

IJSER © 2013 http://www.ijser.org

[8]

[9]

Suggest Documents