3. Literature survey: Classification of sleepiness in drivers
3.4 Machine Learning Algorithms to predict sleep in driving
3.4.3 Support Vector Machines
3.4.3.1 SVM to predict sleep while driving
SVMs have been used to classify sleep and awake states in drivers (Yeo et al., 2009; Shuyan & Gangtie, 2009). Yeo et al. (2009) used SVM to classify drivers in three different classes: alert and drowsy. EEG data were used to determine the different levels of sleepiness. The EEG data were divided in 10 seconds epoch and then manually classified by two raters. Epochs were classified into alert if there was were eye blink artifcats lasting 0.3 to 0.4 seconds, inter-blink intervals lasting 6 to 8 seconds and EEG activity in the beta frequency. The epochs with eye closures lasting longer than 0.5 seconds, EEG showing alpha activity in the occipital region (more than 50% of the epoch) and with appearances of alpha dropout events were classified as drowsy. Epochs were discarded due to lack of consensus between the raters, especially in cases where the alpha dropout was not very prominent. During the experiment, twenty young (10 males and 10 females) students between 20 to 25 years old were recruited to take part in a driving simulator task. They had to drive for one hour on a monotonous highway. Their blinking behaviour (through EOG) and brain activity was recorded using a 17 channels EEG (Figure 3-9 shows an example of the EEG recording). As described before, the EEG and the EOG were used to determine the different levels of sleepiness. The brain activity data (split into 10 seconds epochs) was then transformed using Fast Fourier Transformation to obtain four features per epoch, which were used to train the SVM. The four features obtained per epoch were dominant frequency (frequency with the highest power), average power of dominant peak (average power of the full width half maximum band using the dominant peak), centre of gravity (using the formula ๐ฎ๐ญ = ๐๐ท ๐๐ ๐๐๐
๐ท ๐๐
frequency and ๐ท ๐๐ is the estimated power density), and frequency variability (using
the formula ๐ญ๐ฝ = ๐๐ท ๐๐๐๐๐๐!( ๐๐ท ๐๐๐๐๐)๐/ ๐๐ท ๐๐
๐ท ๐๐
๐ ). Each feature was done for the four
different frequency bands (delta, theta, alpha and beta). This meant that each epoch was a 272x1 vector (4 features x 17 EEG channels x 4 frequency bands). The SVM was trained with 239 epochs of alert and 702 epochs of drowsiness and it was tested with 239 epochs of alert and 702 epochs of drowsiness. The SVM obtained 99.3% accuracy when detecting the different stages (awake and sleep) and 90% accuracy when detecting transition stages, e.g. from alert to drowsy and from drowsy to sleepy.
Figure 3-9 Eye blink and brain activity sample used to determine the different stages of sleepiness and train the SVM. (Source: Yeo et al., 2009). Reprinted from โCan SVM be used for automatic EEG detection of drowsiness during car driving?โ by Mervyn V.M. Yeo et al. Copyright ยฉ 2009 by Mervyn V.M. Yeo et al. Used by permission of Elsevier.
Shuyan & Gangtie (2009) also used a multiclass SVM to predict increase of sleepiness in drivers. Thirty-seven sleep-deprived participants took part in a driving simulator study lasting 45 minutes. Subjective sleepiness (using 9 scale Karolinska Sleepiness Scale; KSS), EEG and eye movement (EOG) behaviour was recorded while the participants were in the driving task. The EEG and subjective data were used to classify the data into three different categories: alert, sleepy and very sleepy. The data were separated into 20 seconds epochs. Each EEG epoch was separated in 2 seconds bins (10 x 2 second bins). Each bin was visually analysed to determine if there were signs of high levels of sleepiness (slow eye movements, alpha activity and/or theta activity). If there were signs of high levels of sleepiness, the bin would be assigned a value of 10; otherwise, the bin would be assigned a value of 0. At the
end, each epoch had a value between 0 and 100 (the sum of the values of each of the 10 x 2 seconds bins) and this value was called Karolisnka Drowsiness Scale (KDS). The KDS and the KSS were used to classify the epochs into alert, sleepy and very sleepy. An epoch was classified as alert if the epoch was from the first 5 minutes of driving, the KSS value during those 5 minutes was less or equal to 7 and the KDS value of the epoch was less than 10; the epoch was classified as sleepy if the epoch was part of the middle of the driving time, the KSS value during those 5 minutes is more or equal to 7 and the KDS values of the epoch was more than 15 and less than 25; the very sleepy epochs were the ones that were part of the 5 minutes before an accident happened (the car going out of the road), a KSS value of 8 or more and a KDS value of the epoch with a value more than 25.
The SVM was trained with 11 features (per participant) obtained from the eye movement behaviour. The features were the following: blink duration, blink duration 50-50 (from the half rise point to the half fall point of the blinking), amplitude of the blink (measured in microVolts), the average speed of the closure of the eye, the peak value of the speed of the closure of the eye, the average speed of the opening of the eye, the peak value of the speed of the opening of the eye, the delay of eyelid opening from previous blink, time from 80% of eyelid opening at rise to 20% of eyelid closure at fall, length of time for complete closure of the eye and length of time for complete opening of the eye. The features obtained from the eye behaviour are presented in Figure 3-10. Same as the research conducted by Yeo et al. (2009), the dataset of Shuyan & Gangtie has a high dimension. The epochs of five participants were used for training of the SVM. The same data were used for validation of the SVM. The SVM in this research obtained an accuracy of around 85% when identifying the different stages the driver was in (Shuyan & Gangtie, 2009).
Figure 3-10 Features extracted from a single blink of a participant to train the SVM. (Source: Shuyan & Gangtie, 2009). Reprinted from โDriver drowsiness detection with eyelid related parameters by Support Vector Machineโ by Shuyan Hu and Gangtie Zheng. Copyright ยฉ 2009 by Shuyan Hu and Gangtie Zheng. Used by permission of Elsevier.