Let F˙i for i = 1…l represent a set of data points with cor- responding class labels yi ∊ {− 1,1}。 The SVM attempts to select a hyperplane to separate the data points based on their
class labels。 Let the equation of the separating hyperplane be
w� 。 F�i + b = 0, where the weight vector, w˙ is perpendicular to
the hyperplane and |b|/�w� � is the perpendicular distance from
the hyperplane to the origin, and "w˙ " is the Euclidean norm
(d ) be the shortest distance from the separating
closest positive (negative) class label。 Thus,
yperplane to thethe margin of the hyperplane is given by d
the training data satisfy the following constraints:
The SVM classifier minimizes the margin "w˙ " to obtain the optimal hyperplane with maximum margin, subject to constraints given in (8)。
Here, we have employed an AdaBoost。M2 extension [10] for multi-class discrimination, which employs a one- against-one strategy for classification。 The merit of this extension is it minimizes the pseudo-loss of the whole process。
The stimuli designed for online testing of the classifier are shown in Fig。 3b, which is similar to the one in Fig。 3a with the following modification: In each trial, a feedback period of 3 s is included after the motor activation period of 2 s。 The testing is performed by the user over a single ses- sion with 10 repetitions of each MI task。 From the advent of the signal acquisition, the AAR feature vector is pre- pared for every 1,000 ms of EEG data before the current time and fed to the pre-trained AdaBoost MI classifier。 This classifier is used as the MI detector in our designed control scheme for real-time robot arm control。
2。3。2Design of the P300 detector
The visual stimuli designed to train the classifier for P300 detection is based on the oddball paradigm [17], shown in Fig。 3c。 As shown in Fig。 3c, the screen is pided into nine blocks where one of the blocks contains a yellow ball indicating the “stop” command and the rest comprises the MI tasks discussed in the previous section。 Each block is highlighted randomly for 1,000 ms。 The user is instructed to focus on the yellow ball when its corresponding block is highlighted and to ignore the rest of the cues。 Each user performs the P300 experiment for 3 sessions, and in each session, the block containing yellow ball is highlighted 50 times and the rest of the blocks are highlighted 200 times。
It is known from existing literature [8, 17] that the P300 components in an EEG signal are elicited at around 300 ms from the time of response to a visual or auditory stimuli in the frequency band of 0。1–10 Hz。 The incoming sig- nals acquired from the Pz electrode are, first, band-pass- filtered by an elliptical filter of order 4 and bandwidth of 0。1–10 Hz。 Then, we determine the averages [29] of four consecutive EEG signals over a period of 0–500 ms, and the resultant output is known as the “feature vector。”
The feature vectors are then used to train a linear kernel- SVM classifier [1] to distinguish the P300 component from rest of the EEG。 The aim of this classifier is to detect the P300 components, which is a peak at around 300 ms in the incoming EEG signals。 Details on SVM are given in the previous section。
The testing session is similar to training session with an additional feedback period of 2 s after every instruction cue, as shown in Fig。 3d。 In the test session, the block con- taining the yellow ball is highlighted 20 times and the rest of the blocks are highlighted 80 times。 Then, we construct a P300 data vector at every 500 ms from the incoming EEG signals, as above。 Next, we average the current data vectors
with three previous data vectors and normalize it in the range [−1, 1] to create the feature vectors, which are then fed to the pre-trained classifier as inputs。 If y is the output class labels of the classifier, then when y = 1, the system decides to stop moving the robot arm and when y = 0, the system continues moving the robot arm。