Image-Based Motor Imagery EEG Classification Using Convolutional Neural Network
Image-Based Motor Imagery EEG Classification Using Convolutional Neural Network
net/publication/335795385
CITATION READS
1 480
8 authors, including:
Some of the authors of this publication are also working on these related projects:
Prognostic and Monitory EEG-Biomarkers for BCI Upper-limb Stroke Rehabilitation View project
All content following this page was uploaded by Tao Yang on 12 December 2019.
Abstract— Motor Imagery (MI) based Brain Computer Therefore, effective classification of electroencephalography
Interface (BCI) has clinical applications such as rehabilitation or (EEG) signals remains a challenging task.
communication for patients who have lost motor functions.
Accurate classification of motor-imagery based
electroencephalography (EEG) is important in developing such Recently, several groups have applied deep learning
BCI applications. We propose an image-based approach to design algorithms in the classification of EEG signals and have
a convolutional neural network (CNN) to classify EEG signals. In shown that such algorithms can outperform traditional
the proposed method, EEG signals were converted into images machine learning methods [6, 7]. One approach in fitting
based on the locations of scalp electrodes, such that spatial EEG data to a deep convolutional network is taking EEG data
correlation between neighbouring EEG channels was taken into in the form of an image [8, 9], i.e. “EEG-as-image”, each
consideration. We tested the proposed CNN architecture with both
2D and 3D kernels. EEG data were collected from a locked-in ALS
EEG channel is been taken as a pixel of an image. Such an
patient over 5 weeks, when the subject was instructed to perform image approach preserves the spatial features that may be
motor-imagery of right hand movement and idle state. Cross-day significant in classifying MI. In addition, temporal
decoding showed that CNN was able to achieve a 2-class (right vs. information is preserved when the entire EEG signal is
idle) classification accuracy of 68.38±7.29% and 65.94±8.52% represented as a series of images from consecutive time steps.
with 2D and 3D kernels respectively, compared to 55.09±5.74 % C. Tan et al. [8] combined EEG video and optical flow
for the traditionally used filter bank common spatial pattern method to extract multimodal information from EEG data for
(FBCSP) method. We also observed changes in the correlation classification. D. Zhang et al. [9] proposed a convolutional
coefficient of spectral entropy in the EEG data across weeks, and recurrent neural network model with cascade and parallel
these coefficients reveal frequency bands that are important for
decoding. In particular, the CNN architecture with Delta band
structure for the recognition of intention from EEG signal. In
included performed 6.96% higher than that excluding the Delta R. T. Schirrmeister et al.’s work [10], 44 channels of EEG
band. This study shows that the image-based CNN method data went through temporal convolution with 25 linear filters.
improves the classification performance, and the inclusion of The outputs of the temporal convolution were then formed as
Delta band improves classification performance for the current a 44 x 25 array for the subsequent convolution neural network
dataset. (CNN). This layer of 1D convolutional filter increased the
Keywords— Electroencephalography, MI-BCI, Convolutional EEG data from a vector of 44 elements to a 44 x 25 array, and
Neural Network, EEG-as-image. hence a large number of neurons are required to construct the
network.
64 filters were used in the convolutional layer, with a 2D day tests are 68.38±7.29% and 65.94±8.52% for 2D and 3D
kernel size of 6 × 5 or a 3D kernel size of 6 × 5 × 5. The kernel respectively.
activation function for the convolutional layers was the Leaky
Rectified Linear Unit (LeakyReLU) with leak coefficient of Performance of the proposed CNN architecture was
0.05. A dropout rate of 0.5 was used to prevent overfitting. compared to the FBCSP algorithm (Fig. 5). The CNN
Mean pooling with a kernel of 75 and stride of 15 were architecture performed better than FBCSP in all 5 cross-day
applied to the filtered data from CNN to reduce the number tests, by 13.29% and 10. 85% on average for 2D and 3D
of features extracted. The Softmax function was applied to kernel respectively.
normalize the probability for classification.
III. RESULTS
A. EEG Variation over Experimental Period Figure 5. Cross-day validation of CNN. Black, yellow and blue bars
are accuracies obtained using 2D, 3D kernel and FBCSP
EEG signal varies across experimental sessions. Such respectively.
variations lead to inconsistencies in selected features among
experimental sessions which would affect the performance of
classifier. Performance of BCI applications often deteriorates
due to such non-stationarity. Spectral entropy is a measure of
signal disorganization, and its correlation coefficient of two
variables is an indicator of how close these two variables are
linearly related [17]. Figure 4 shows the correlation coefficient
of spectral entropy between ‘right’ and ‘idle’ trials for the data
collected over 5 weeks. High correlation coefficients were
present in data from all weeks except Week 5. The magnitude
of the correlation coefficient varies across the experimental
sessions. On average, the correlation coefficient in Week 4
and 5 are lower compared to the previous 3 weeks. Week 1, 2
and 3 were found with high correlation coefficient in Delta
band.
Figure 6. Classification accuracy of CNN model (2D Kernel) trained
with data including and excluding Delta band in cross-day tests.
B. Performance of CNN
Cross-day tests were performed using the CNN architecture
shown in Figure 3. The CNN was configured with 2D kernel, The correlation coefficients in Delta band were significant in
size of 6 × 5 × 1, and 3D kernel, size of 6 × 5 × 5 separately Weeks 1, 2 and 3 (see Figure 4 a, b and c). Cross-day tests
for the tests. Figure 5 shows the classification accuracies from were conducted using the EEG data including and excluding
the cross-day tests. The average accuracies over the 5 cross- Delta band. These tests were performed on the CNN
architecture with 2D Kernel. The average classification
accuracies of the 5 cross-day tests are 68.38±7.29% and [3] Lazarou I., Nikolopoulos S.,Petrantonakis P. C., Kompatsiaris I.,
Tsolaki M.Lazarou I., “EEG-Based Brain-Computer Interfaces for
61.42±5.90% for CNN trained with Delta band included and Communication and Rehabilitation of People with Motor Impairment:
excluded respectively, showing an improvement in decoding A Novel Approach of the 21 st Century”. Front Hum Neurosci.
accuracy when Delta band was included (Fig. 6). 2018;12:14.. doi:10.3389/fnhum.2018.00014.
[4] M. Marchetti and K. Priftis, “Brain-computer interfaces in amyotrophic
lateral sclerosis: A metanalysis,” Clin Neurophysiol. Vol. 126(6),
IV. DISCUSSIONS AND CONCLUSIONS p.1255-63, Jun. 2015.
[5] Wu W., Chen Z., Gao X., Li Y., Brown E. N., Gao S., "Probabilistic
In this study, we tested the performance of a CNN with both common spatial patterns for multichannel EEG analysis," IEEE
2D and 3D kernel in decoding EEG data and compared with transactions on pattern analysis and machine intelligence, vol. 37, no.
the traditionally used FBCSP method. The average 3, pp. 639-653, 2015
classification accuracies of both 2D and 3D kernel CNN [6] Y. Zhao et al., "On the improvement of classifying EEG recordings
using neural networks," 2017 IEEE International Conference on Big
outperforms FBCSP. No significant difference in Data (Big Data), Boston, MA, 2017, pp. 1709-1711.doi:
classification accuracy was found between 2D and 3D 10.1109/BigData.2017.8258112
kernels. The 3D kernel is an extension of the 2D kernel in [7] S. Sakhavi, C. Guan, and S. Yan, "Learning Temporal Information for
temporal dimension of training samples. Since the subject Brain-Computer Interface Using Convolutional Neural Networks,"
was performing motor imagery consistently during the trial IEEE Transactions on Neural Networks and Learning Systems, 2018.
period, it is not surprising that the 3D kernel would not [8] Tan C., Sun F., Zhang W., Chen J., Liu C., "Multimodal Classification
with Deep Convolutional-Recurrent Neural Networks for
capture additional distinctive features compared to the 2D Electroencephalography," in International Conference on Neural
kernel. Information Processing, 2017, pp. 767-776: Springer.
[9] Zhang D., Yao L., Zhang X.,Wang S., Chen W., Boots R., "EEG-based
The correlation coefficient of spectral entropy of the two Intention Recognition from Spatio-Temporal Representations via
classes of trials (‘right’ and ‘idle’) showed inconsistency in Cascade and Parallel Convolutional Recurrent Neural Networks,"
arXiv preprint arXiv:1708.06578, 2017.
distribution in frequency bands and magnitude of correlation
[10] R. T. Schirrmeister et al., "Deep learning with convolutional neural
coefficient over the experimental period. As shown in Figure networks for EEG decoding and visualization," Human brain mapping,
4, (a), (b) and (c), increased correlation coefficient appeared vol. 38, no. 11, pp. 5391-5420, 2017.
at a frequency below 4 Hz, i.e. Delta band, in data from [11] Yann LeCun, Yosshua Bengio, Geoffrey Hinton “Deep Learing,”
Weeks 1, 2 and 3. The impact of Delta band in decoding is Nature volume 521, pages 436–444 (28 May 2015)
illustrated in Figure 6. Classification accuracy improved [12] K. K. Ang, Z. Y. Chin, C. Wang, C. Guan, and H. Zhang, "Filter bank
common spatial pattern algorithm on BCI competition IV datasets 2a
significantly when Delta band was included in the model and 2b," Frontiers in neuroscience, vol. 6, p. 39, 2012.
training, especially for the first 3 weeks. This result shows [13] Elgendi M., Vialatte F., Cichocki A., Latchoumane C., Jeong J.,
that Delta band signals are important for motor imagery Dauwels J., "Optimization of EEG frequency bands for improved
classification in the current data set. diagnosis of Alzheimer disease, " Conf Proc IEEE Eng Med Biol Soc.
2011;2011:6087-91. doi: 10.1109/IEMBS.2011.6091504.
The magnitudes of correlation coefficients in general across [14] Rosa So Q et al., "Increased Theta Oscillations During Motor Imagery
in a Subject with Late-stage ALS, " Conf Proc IEEE Eng Med Biol Soc.
frequencies and channels are lower in Weeks 4 and 5 (Figure 2018 Jul;2018:1078-1081. doi: 10.1109/EMBC.2018.8512411.
4 d and e) compared to earlier weeks. Lower correlation [15] X. Glorot, Y. Bengio, "understanding the difficulty of training deep
coefficients indicate that the signals collected during these feedforward neural networks," Proceedings of the Thirteenth
weeks were less distinguishable between the motor imagery International Conference on Artificial Intelligence and Statistics,
PMLR 9:249-256, 2010.
tasks, and hence resulted in lower classification accuracy as
[16] Razavian A., Azizpour H., Sullivan J., Carlsson S., "CNN Features off-
shown in Figure 5 Week 4 and 5. This difference might be the-shelf: an Astounding Baseline for Recognition.” CoRR ,
due to lower engagement of the ALS subject during the BCI abs/1403.6382, 2014
sessions in the later weeks. [17] Yang, T., et al. "EEG Channel Selection Based on Correlation
Coefficient for Motor Imagery Classification: A Study on Healthy
In conclusion, an image-based CNN architecture was used for Subjects and ALS Patient." Conf Proc IEEE Eng Med Biol Soc 2018:
1996-1999.
classification of motor imagery EEG signals. We showed that
CNN performs significantly better than FBCSP method on
average using both the 2D and 3D kernels. However, no
significant difference in performance was found between 2D
and 3D kernel in the cross-day tests. As well, future work will
include using data collected over longer periods of time to
statistically validate the significance of these observations.
REFERENCES
[1] Ang K.K, et al., “A large clinical study on the ability of stroke patients
to use an EEG-based motor imagery brain-computer interface.” Clin
EEG Neurosci. 2011 Oct;42(4):253-8.
[2] Broetz D., Braun C., Weber C., Soekadar S. R.,Caria A., Birbaumer,
N.. “Combination of brain-computer interface training and goal-
directed physical therapy in chronic stroke: a case report.” Neurorehab
Neural Re 2010; 24(7): 674-6