A Novel EEG Classification for Baseline Motor Cortex using
Adaboost
Said Abenna
1a
, Mohammed Nahid
1
and Abderrahim Bajit
2
1
Faculty of Sciences and Technology, Hassan II University, Casablanca, Morocco
2
National School of Applied Sciences, Ibn Tofail University, Kenitra, Morocco
Keywords: Brain-computer interface (BCI), Electroencephalogram (EEG), Data Analysis, Classification, Optimization
Abstract: This paper contains a new method for EEG classification and specifically for baseline hand motor cortex
recognition. This work is based on the determination of links between all electrodes when moving hands using
covariance and correlation matrices, also the importance degree for every electrode from the best to the bad
in the classification stage, and thus the application of differential evolution (DE) optimizer to increase the
prediction accuracy of AdaBoost algorithm to the best state. The results obtained show that the prediction
accuracy value for hand EEG motor cortex classification takes the value of 100% when using more than six
electrodes without using feature extraction algorithms, knowing that the related work has a maximum average
accuracy value of 99.1% using the PNN algorithm. Therefore, this work has a very important role in increasing
the EEG signals prediction quality, either on the side of improving the classification algorithms or minimizing
the number of acquisition channels needed.
1 INTRODUCTION
The Brain-Computer Interface (BCI) transmits brain
activity acquired from the human scalp to a computer
for controlling external devices and assisting the
handicapped in regaining organ abilities (Abenna et
al., 2021a). It's almost research for the use of
electroencephalogram (EEG) in the controls
intelligent in robotic arms and other external devices.
Compared to other signal types, EEG signals have
several different direct communications between a
human brain and a computer (Jin et al., 2015; Li et al.,
2016; Tang et al., 2020; Zhang et al., 2018). The
collected brain signals vary depending on the
structure of the human brain and the subject's mental
state, and these brain activities of each subject are
unique. EEG signals are not woody and non-stable,
which means that the EEG signal properties change
over time (Khosla et al., 2020; Tang et al., 2020; Yin
and Zhang, 2017). Furthermore, the recorded EEG
signals are frequently intermingled with noise,
making analysis difficult. As a result, efficient steps
to enhance the signal-to-noise ratio (SNR) of EEG
data should be taken (Michelmann et al., 2018; Tang
et al., 2020; Whitmore and Lin, 2016). EEG waves
a
https://orcid.org/0000-0002-4172-7439
convert brain waves, which means that it is a
continuous record of the brain’s electrical activity by
placing metal electrodes on the scalp (Jasper, 1958;
Khosla et al., 2020; Patel et al., 2018). Neurons
communicate spontaneously with each other by
generating electrical currents and remain active at all
times, even when a person is asleep or relaxed. Low
cost, high time resolution, high flexibility, usability,
non-invasive, portability, and safe nature make the
EEG a powerful tool compared to other functional
neuroimaging techniques such as magneto-
encephalogram (MEG), positron emission
tomography (PET), functional magnetic resonance
imagery (fMRI), and transcranial magnetic
stimulation (TMS). This work is interested in
developing a new method more efficient for the
predicting system of EEG signals, in this sense, this
work uses the covariance and correlation matrices to
determine the acquisition system quality used and
finds electrical leaks between all electrodes, thus
optimization algorithms like DE used to maximize the
quality of the results found, and ultimately the
AdaBoost classification algorithm used to generate
the prediction models (Abenna et al., 2021a), Fig. 1
presents a basic architecture of the prediction system
Abenna, S., Nahid, M. and Bajit, A.
A Novel EEG Classification for Baseline Motor Cortex using AdaBoost.
DOI: 10.5220/0010729600003101
In Proceedings of the 2nd International Conference on Big Data, Modelling and Machine Learning (BML 2021), pages 125-129
ISBN: 978-989-758-559-3
Copyright
c
2022 by SCITEPRESS – Science and Technology Publications, Lda. All rights reserved
125
Figure 1: Illustrate of EEG acquisition and processing.
for an EEG signal. This method has been applied for
hand EEG motor cortex, in such a way the prediction
accuracy values are usually 100% using more than 6
acquisition electrodes, compared to related work that
has accuracy values less than 99.1% using PNN.
The rest of the article is organized as follows:
Section 2 presents all algorithms of classification and
optimization proposed for the system. Results and
discussion are presented in section 3, while section 4
provides conclusions and an overview of the future
work.
2 METHODS
2.1 Dataset
'Projectbci-1D' dataset: The motive is a 21-year-old
right arm with no known health condition. An EEG
consists of a random movement of the actual left and
right hands, such as the recorded is with closed eyes.
The electrodes used in this work (FP1, FP2, F3, F4,
C3, C4, P3, P4, O1, O2, F7, F8, T3, T4, T5, T6, FZ,
CZ, and PZ) are distributed as following the
international system 10-20 as illustrated in Fig. 2.a.
The recording sampling at 500 Hz with NeuroFax
EEG device using 19 electrodes for acquisition. The
data were exported with a common reference
'eemagine-EEG', where the AC line operates at 50 Hz.
Fig. 3 illustrates some of the EEG signals acquired by
the NeuroFax device using 19 electrodes when eyes
are closed and the left-hands move. We notice that the
EEG signals are very noisy and misunderstood.
2.2 Adaptive Boost
Freund and Chapyle invented AdaBoost in 1996 as an
iterative boost procedure. The primary goal of this
recovery effort is to focus on situations that are
difficult to categorize. First, each instance is assigned
the
same weight. Iteration increases all weights of
(a) Location of all
electrodes
(b) Nerve system between the
lef
t
hand and the central lobe
Figure 2: Positioning of all electrodes used to acquire the
EEG signals for the motor cortex of hands.
Figure 3: A part of EEG signals acquired using NeuroFax
device.
lower-ranked instances and reduces correctly ranked
instances, more details are in (Chatterjee et al., 2019).
The AdaBoost is supported by the Algo. 1. Such as
the 𝑥
and 𝑦
represent the feature set and the
corresponding decision class label for the ith instance.
It represents the variance vector with n size because
there is a T iteration, and each instance starts with a
distribution of 1/n. 𝐴
is calculated in the n training
instance (Chatterjee et al., 2019). The weak learner is
applied at each step, and AdaBoost employs the
exponential loss function 𝑒𝑥𝑝𝑎
𝑦
𝜙
𝑥
 to
calculate a weighted error epsilon of 𝐴
. 𝑎
, 𝑦
, and
BML 2021 - INTERNATIONAL CONFERENCE ON BIG DATA, MODELLING AND MACHINE LEARNING (BML’21)
126
Algorithm 1: Adaptive boosting.
- Inputs: Given 𝑥
,𝑦
,...,𝑥
,𝑦
,
where n is the total number of
training data instances, 𝑥
is the
feature data and 𝑦
is the
associated decision class,
𝑥
𝑒𝑠𝑡
is
the testing data;
- Initialize: 𝐴
1/n, where 𝑖 
1,...,𝑛;
for each iteration t in T do
Use distribution to train weak
learners 𝐴
;
Choose: 𝑎
12∗𝑙𝑜𝑔1𝜖
/𝜖
;
Loss: 𝑒𝑥𝑝𝑎
𝑦
𝜙
𝑥
;
Update: 𝐴
1𝑖𝐴
𝑖 ∗ 𝑙𝑜𝑠𝑠/𝑔
,
where 𝑔
is a new normalization
factor;
𝑔
𝐴
𝑖 ∗ 𝑒𝑥𝑝𝑎
𝑦
𝜙
𝑥


;
End.
R
eturn
𝑓
𝑥

←𝑠𝑔𝑖𝑛
𝑎
𝜙
𝑥


;
𝜙
𝑥
denote an n-dimensional weight vector, a
vector containing the actual decision class of n cases,
and a vector containing the anticipated outcome for
the ith instance, respectively. The weight
combination sign of the lower classifier is calculated
by the final classifier f (Chatterjee et al., 2019).
2.3 Optimization
The optimization advantage is to select a valid
classifier and to reduce the functionality used in
restricted classifications to increase the prediction
accuracy. This process is further optimized by the DE
algorithm to determine optimal synthesis conditions
(Estimators number (NE), learning rate (LR), and
random-state (RS)) to maximize reaction yield, more
details are in (Abenna et al., 2021a; Rodrigues et al.,
2018).
3 RESULTS AND DISCUSSION
The experiments were conducted on the 2.4 GHz
desktop and 6 GB of RAM with four Intel®Core
(TM) i5 CPUs and 64 bit/Windows 10 operating
system, and python.3.6 for programming.
3.1 Analysis Results
Fig. 4 illustrates the matrix of covariance between the
19 acquisition electrodes in the state of the left hand
(Fig. 4.a) and of the right-hand movement (Fig. 4.b).
In this figure, we can observe easily the existence of
more connection between all electrodes when the
right-hand moves compared to the left hand,
indicating a large change in the distribution of
electrical signals in the brain between the two hands
state, which also shows that has facilitated the
classification of these signals.
Table 1: Symbol and description.
Symbol Description
N
E n-estimators
L
R learning-rate
RS
random-state
EEG The numbe
r
of electrodes
AC
Accurac
y
Z
OL Zero One Loss
Tc Classification time
Tp Prediction time
To
Optimization time
(a) Left hand (b) Right hand
Figure 4: The covariance matrix for each moved hand.
3.2 Feature Selection Results
Fig. 5 shows a classification of electrodes according
to their importance for the classification stage using
the AdaBoost algorithm (Abenna et al., 2021b),
knowing that each electrode has been represented by
its degree of importance from 0 to 1, in this figure we
notice that the best electrodes used are FP1, PZ, and
FP2, knowing that the number of electrodes can be
decreased up to 3 or 1 single electrode without a great
degradation of the system accuracy. Fig. 5.b
illustrates the correlation matrix between the
electrodes signal to detect all links between them and
avoid electrical leaks that degrade the quality of the
acquired signals, such that we notice that all degrees
are low except between some electrodes such as T5,
O1, O2, CZ, and FP2, which implies the best quality
of the acquisition system, and we are not needed to
use any spatial filter to decrease the correlation
between the channels (Whitmore and Lin, 2016).
A Novel EEG Classification for Baseline Motor Cortex using AdaBoost
127
(a) Channels selection using AB (b) Correlation matrix
Figure 5: Channels selection and correlation matrix for EEG signals classification of hands moved.
3.3 Evaluation Metrics
Accuracy and Zero-One-Loss are typically metrics
used to measure the performance of biomedical and
complex data during classification.
𝐴𝐶


(1)
𝑍𝑂𝐿 FP  FN (2)
Where True Positive (TP) refers to a circumstance
in which an alarm is generated although the left hand
has moved during testing. The term TN (True
Negative) describes a circumstance in which the
right-hand moves but no alarm is generated. When the
left hand is employed, the alert is not raised, which is
referred to as FP (False Positive). The term FN (False
Negative) describes a circumstance in which the
right-hand moves but no alarm is triggered (Abenna
et al., 2021b).
3.4 Classification Results
Table 2 shows a main parameter optimization of
AdaBoost to well improve the quality of prediction,
as it can find during testing large combinations of
AdaBoost parameters for that gives precision values
of 100%, knowing that we can choose only those
corresponding to a low value of NE, to guarantee a
high speed of classification and prediction, thus a
good quality of prediction. Table 3 shows a size
improvement of the acquisition system without
degradation of prediction performance, such that we
do the recognition of EEG signals during testing
using these AdaBoost parameters (NE = 257, LR =
0.9969, and RS = 911), so we choose only the best
NEEG-channel have been selected in Figure 5.a, and
we notice that the accuracy value remains at the level
of 100% when NEEG 6, we notice that the use of
just two electrodes FP2 and PZ gives an accuracy of
97%, indicating the possibility of developing new
devices for the baseline hand EEG motor cortex
prediction with a small size, as well as Tc and Tp,
decreases when we decrease the NEEG. In table 4, the
work of Hossain et al. (Hossain et al., 2015) who uses
the BP and PNN algorithms for the EEG
classification finds that the precision value cannot
exceed 99.1% but at the work of this paper the
accuracy value take 100% when using more than six
acquisition electrodes.
Table 2: AdaBoost parameters optimization using DE.
AdaBoost parameters Optimization results
NE LR RS AC (%) ZOL To (s)
257 0.9969
911 100.0 0 97.73
319 1.5301
559 100.0 0 124.94
Table 3: Improving the number of channels used for hands
EEG classification.
NEEG
Classification results
AC (%) ZOL Tc(s) Tp(s)
10
100.0 1 48.47 1.43
6
100.0 0 33.39 1.17
3
99.58 108 22.91 1.62
2
97.00 771 18.40 1.00
1
90.10 2547 15.03 1.00
Table 4: Comparative results with related work.
Work Accurac
y
Methods
Hossain et al.
(
2015
)
88.9% BP
99.1% PNN
This wor
k
100% AdaBoost
BML 2021 - INTERNATIONAL CONFERENCE ON BIG DATA, MODELLING AND MACHINE LEARNING (BML’21)
128
4 CONCLUSIONS
In conclusion, the method used in this work shows its
efficiency in predicting the hand moved from the
EEG signals without any mistake, such that this work
uses the covariance matrices to show all changes in
the distribution of the brain activities when moving
every single hand (left or right), so the correlation
matrix used to determine the electrical leaks between
all electrodes, also the use of AdaBoost algorithm to
classifying the EEG signals and the minimization of
the number of channels (NEEG). Also, the use of the
DE optimizer improves the classification
performances, knowing that the accuracy value in this
work takes the value of 100% when using more than
six electrodes. We hope that this work will help other
researchers to develop a good EEG signals prediction
system. In future work, our team focuses on
developing new and more efficient methods and
instigating this work for real-time applications of the
BCI systems.
REFERENCES
Abenna, S., Nahid, M., Bajit, A., 2021. “BCI: Classifiers
Optimization for EEG Signals Acquiring in Real
Time”. In 2020 6th IEEE Congress on Information
Science and Technology (CiSt), IEEE.
Abenna, S., Nahid, M., Bajit, A., 2021. “Chapter 18 Brain
Computer Interface: A Novel EEG Classification for
Baseline Eye States Using LGBM Algorithm”,
Springer Science and Business Media LLC.
Chatterjee, R., Datta, A., Sanyal, D.K., 2019. “Ensemble
learning approach to motor imagery EEG signal
classification”. Machine Learning in Bio-Signal
Analysis and Diagnostic Imaging.
Hossain, A.A., Rahman, M.W., Riheen, M.A., 2015. “Left
and right hand movements EEG signals classification
using wavelet transform and probabilistic neural
network”. International Journal of Electrical and
Computer Engineering.
Jasper, H., 1958. “Report of the committee on methods of
clinical examination in electroencephalography.
Electroencephalogr”. Clin. Neurophysiol.
Jin, J., Sellers, E., Zhou, S., Zhang, Y., Wang, X.,
Cichocki, A., 2015. “A p300 brain-computer interface
based on a modification of the mismatch negativity
paradigm”. International Journal of Neural Systems.
Khosla, A., Khandnor, P., Chand, T., 2020. “A comparative
analysis of signal processing and classification methods
for different applications based on EEG signals”.
Biocybernetics and Bio-medical Engineering, 1–2.
Li, Y., Pan, J., Long, J., Yu, T., Wang, F., Yu, Z., Wu, W.,
2016. “Multimodal BCIs: Target detection, multi-
dimensional control, and awareness evaluation in
patients with disorder of consciousness”. Proceedings
of IEEE.
Michelmann, S., Treder, M.S., Griffiths, B., Kerre´n, C.,
Roux, F., Wimber, M., Rollings, D., Sawlani, V.,
Chelvarajah, R., Gollwitzer, S., Kreiselmeyer, G.,
Hamer, H., Bowman, H., Staresina, B., Hanslmayr, S.,
2018. “Data-driven re-referencing of intracranial EEG
based on independent component analysis (ICA)”.
Journal of Neuroscience Methods journal.
Patel, R., Gireesan, K., Sengottuvel, S., 2018. “Decoding
non-linearity for effective extraction of the eye-blink
artifact pattern from EEG recordings”. Pattern
Recognition Letters. doi:10.1016/j.patrec. 2018.01.022.
Rodrigues, H.C., Herskovits, J., Soares, C.M.M., Arau´jo,
A.L., Guedes, J.M., Folgado, J.O., Moleiro, F.,
Madeira, J.F.A., 2018. “EngOpt 2018 proceedings of
the 6th international conference on engineering
optimization”. Springer Nature Switzerland.
Tang, X., Li, W., Li, X., Ma, W., Dang, X., 2020. Motor
imagery EEG recognition based on conditional
optimization empirical mode decomposition and multi-
scale convolutional neural network. Expert Systems
With Applications.
Whitmore, N., Lin, S., 2016. “Unmasking local activity
within local field potentials (LFPs) by removing distal
electrical signals using independent component
analysis”. NeuroImage.
Yin, Z., Zhang, J., 2017. “Cross-session classification of
mental workload levels using EEG and an adaptive
deep learning model”. Biomedical Signal Processing
and Control.
Zhang, Y., Wang, Y., Zhou, G., Jin, J., Wang, B., Wang,
X., Cichocki, A., 2018. “Multi-kernel extreme learning
machine for EEG classification in brain-computer
interfaces”. Expert Systems With Applications.
A Novel EEG Classification for Baseline Motor Cortex using AdaBoost
129