An Efficient Drowsiness Detection Framework for Improving Driver Safety Through Supervised Learning Models
Abstract
1. Introduction
2. Related Work
3. RDDF: Design Description
3.1. Measured Data Acquisition
3.1.1. Experiment and Simulation Dataset Description
3.1.2. Shapelet Generation
3.1.3. Independence and Coupling Analysis
3.1.4. Shapelet Labeling
3.2. Data Classification and Drowsiness Detection
3.2.1. Database Division
3.2.2. Classifiers Description
- Logistic Regression (LR) [27]: It is a statistical model that employs a logistic function combined with stochastic gradient descent to predict the class category of a given feature set. LR has been widely tested in numerous studies to detect driver drowsiness [28,29]. In this paper, we used the default parameters of LR provided by the scikit-learn library.
- Random Forest (RF) [30]: This is an ensemble learning method that can be efficiently applied for both classification and regression based on multiple hierarchical decision trees during the training phase. Subsequently, the classification output of the RF is the class selected by the majority of trees, while the regression output is the average value of all tree predictions. RF has also demonstrated its potential in outperforming the accuracy of the standard decision tree classifier for driver drowsiness detection [31,32]. In this work, the default values of the random forest classifier implemented in scikit-learn are considered, where the number of trees is fixed to 100.
- Decision Tree (DT) [33]: It is a decision support tool based on a tree structure and if–then–else decision rules. DT is commonly used in various operations research and decision analysis domains, particularly for driver drowsiness detection [34,35,36]. The decision tree algorithm is implemented in the scikit-learn library, where the default parameters, such as tree depth and feature index, are considered in this paper to automatically select the best decision based on the feature set.
- Naïve Bayes (NB) [37]: It is a probabilistic classifier based on Bayes’ theorem with strong independence assumptions between features. NB has demonstrated its computational efficiency in various domains, including drowsiness detection [38,39]. The scikit-learn library provides several models for Naïve Bayes implementation, of which we used the Gaussian model in this work.
- K-Nearest Neighbors (KNN) [40]: It is one of the simplest learning classifiers that does not require creating a training model. The core of KNN mainly depends on measuring the distance between the training and testing data. Furthermore, KNN has shown strong performance in detecting drowsiness through a large number of studies [41,42]. By default, scikit-learn uses KNN with and the Minkowski distance with uniform weights.
- Multi-Layer Perceptron (MLP) [43]: It is a supervised learning method based on an artificial neural network and the backpropagation algorithm for training. Mainly, MLP consists of three layers (input, hidden, and output) and uses an activation function to determine the predicted class. Furthermore, MLP is widely used in drowsiness detection [44,45], and we set the number of neurons in scikit-learn to 500, 250, and 40 for the three layers, respectively.
- Jaccard-based K-Nearest Neighbors (JKNN): In general, KNN uses a distance metric, such as Euclidean, to measure the difference between independent vectors of testing and training data. However, a distance metric is usually appropriate for data that do not exhibit direct correlation or temporal factors among their values. Hence, it is often preferable to use similarity metrics in applications where the information is temporally organized, thus considering correlation in the similarity measure proves to be more appropriate and can even yield more accurate results. In this work, we focused on the Jaccard coefficient to gauge the similarity and diversity between sample sets, as it has been used in a wide range of applications including community detection in social networks [46], document and web page plagiarism detection [47], attack detection [48], and market analysis [49]. Thus, the Jaccard similarity between two shapelets and that correspond to the same measure j is calculated as follows:Then, the same concept of KNN is applied, but in this case, the nearest shapelets are selected according to the Jaccard similarity measure, with the number of neighbors set to .
3.2.3. Drowsiness Detection
- Single-Measure Drowsiness Detection: In this scenario, we applied each classifier based on each measure to analyze the driver or driving behavior. Algorithm 1 shows the process of single-measure drowsiness detection, which takes as input the training shapelets of the monitored measure along with the desired classifier, and produces as output the driver’s state according to the testing shapelets. The process starts by defining a set that stores all driver states of the testing shapelets, e.g., (line 1). Then, for each shapelet in the testing set, its corresponding readings are considered as feature vectors before applying the selected classifier (lines 2–4). Once the predicted state is returned by the classifier, e.g., , it is added to the list of driver states (lines 4–5). Finally, the performance metrics (accuracy, precision, recall, and F1) of the classifier are calculated (see Equations (2) to (5)), and the driver state is returned (lines 7–14).
Algorithm 1 Single-Measure Drowsiness Detection Algorithm - Require:
- A measure: ; Training data of a measure: ; Testing data of a measure: ; A classifier: C.
- Ensure:
- Driver state: awake or drowsy.
- 1:
- 2:
- for each do
- 3:
- consider each as a feature
- 4:
- = apply_classifier (C,,)
- 5:
- 6:
- end for
- 7:
- [accuracy, precision, recall, F1] = confusion_matrix (, )
- 8:
- for each do
- 9:
- if then
- 10:
- return awake
- 11:
- else
- 12:
- return drowsy
- 13:
- end if
- 14:
- end for
where- –
- : A shapelet from the testing data that represents a drowsy state and is correctly predicted as drowsy by the classifier.
- –
- : A shapelet from the testing data that represents an awake state and is correctly predicted as awake by the classifier.
- –
- : A shapelet from the testing data that represents a drowsy state and is incorrectly predicted as awake by the classifier.
- –
- : A shapelet from the testing data that represents an awake state and is incorrectly predicted as drowsy by the classifier.
- Multi-Measure Drowsiness Detection: In this scenario, each classifier is applied to several measures at the same time. Algorithm 2 shows the process of multi-measure drowsiness detection, which takes as input the training shapelets of all the measures in , except for EEG since it is not included in our experiments, along with the total number of shapelets (e.g., ) and the desired classifier. On the other hand, Algorithm 2 returns as output the driver’s state, similarly to that of single-measure drowsiness detection. The algorithm process is divided into four steps: The first step, called multi-shapelet labeling (lines 1–10), monitors both driver and driving behaviors and concatenates the corresponding shapelets of all the measures into a single shapelet (line 3). Then, the concatenated shapelet is assigned a label of 1 if all the measures indicate a drowsy state and 0 otherwise, before being added to the labeled shapelet list (line 9). The second step, called data classification (lines 11–15), applies each classifier to the concatenated shapelets in the testing data (line 13) while adding the predicted state of each shapelet to the list of the predicted ones (line 14). The third and fourth steps, called classification performance (line 16) and driver-state determination (lines 17–23), compute the performance metrics of the classifier and return the driver’s state, similar to the process described in Algorithm 1.
Algorithm 2 Multi-Measure Drowsiness Detection Algorithm - Require:
- Set of measures: ; Training data: ; Testing data: ; Number of total shapelets of each measure: ; A classifier: C.
- Ensure:
- Driver state: awake or drowsy.
- 1:
- 2:
- for to do
- 3:
- 4:
- if and and and then
- 5:
- 6:
- else
- 7:
- 8:
- end if
- 9:
- 10:
- end for
- 11:
- 12:
- for each (,) where do
- 13:
- = apply_classifier (C,,)
- 14:
- 15:
- end for
- 16:
- [accuracy, precision, recall, F1] = confusion_matrix (, )
- 17:
- for each do
- 18:
- if then
- 19:
- return awake
- 20:
- else
- 21:
- return drowsy
- 22:
- end if
- 23:
- end for
3.3. Driver Notification and Database Updating
4. Performance Evaluation
4.1. Rationale for T Selection
4.2. Performance Study of RDDF
- In the best case, RDDF ensures up to accuracy, precision, recall, and F1-score. Otherwise, in the worst case, RDDF drops to accuracy, precision, <1% recall, and <1% F1-score. This decrease occurs because certain classifiers are not suitable for the given dataset characteristics. Across ten repeated data splits, the standard deviation was ±, confirming consistent model performance with low variance despite the limited sample size.
- Classifiers exhibit varying performance depending on each measure and the window length T. Indeed, we observed that there is no classifier that outperforms all the others across all the performance metrics. However, JKNN achieves superior classification results in most cases compared to the other classifiers. This is because the Jaccard similarity acts as a strict constraint, ensuring minimal classification error compared with the conditions used in other classifiers. Thus, it is unlikely that a shapelet labeled as drowsy would be similar to one labeled as awake according to the Jaccard similarity. Moreover, JKNN is generally followed by the RF classifier in performance metrics, mainly due to the large number of trees used in RF (e.g., 100). Subsequently, the classifiers are ordered according to the average accuracy as follows: JKNN (), random forest (), K-nearest neighbor (), decision tree (), logistic regression (), multi-layer perceptron (), and naïve Bayes ().
- The performance of all the classifiers is relatively stable when varying the window length. On the one hand, this indicates that our technique can provide fast and accurate drowsiness detection even with a short driver monitoring period (e.g., s). On the other hand, this implies that the technique can reduce the frequency of driver alerts when using a longer monitoring period (e.g., s).
- The performance of each classifier varies dynamically according to the monitored measure. First, the performance of a classifier changes depending on whether a single or multiple measure is monitored. For instance, the average accuracy of RF reaches for each separate measure (SWA, PP, VS, and TAV), while it increases to when all the measures are combined (i.e., SWA, PP, VS, and TAV). Second, the performance of the classifier also varies according to the type of measure, either driver or driving behaviors. For instance, the average accuracy of RF achieves for driving-based measures (e.g., SWA, PP, and VS) and for driver’s-based measures (e.g., TAV and EEG). This is mainly because the shapelets representing driver’s behavior vary significantly compared to those of driving behavior.
- The recall metric in JKNN is consistently equal to 1. This is because a shapelet indicating the awake state is highly unlikely to resemble that of the drowsy state according to the Jaccard similarity. Thus, is always equal to 0, and the recall metric correspondingly equals 1.
- The obtained results of precision, recall, and F1-score metrics of JKNN outperform those of conventional classifiers. This is due to the imbalanced data problem facing standard classifiers, which is effectively resolved in the new version of the classifier (e.g., JKNN); in fact, JKNN mostly focuses on the drowsy shapelets to classify the testing data independently of its size. Subsequently, we can notice that precision, recall, and F1 metrics mostly exceed in JKNN while they mostly remain below using standard classifiers.
4.3. Training Time Analysis
4.4. RDDF vs. State-of-the-Art: An Analytical Comparison
- Most of the proposed techniques are based on machine- and deep-learning methods.
- The literature shows significant progress in addressing the drowsiness detection problem, with reported accuracies mostly exceeding , except for [24].
- Researchers focus equally on driving and driver behaviors for detecting drowsy drivers, and both driving and physiological measures have been extensively investigated in the literature.
- RDDF is well-positioned in terms of accuracy and shows strong performance compared to other existing techniques. This is mainly because our technique treats each record within a shapelet as an individual feature when classifying the driver’s state. Thus, it outperforms most existing approaches, except for one technique (e.g., [18]) that achieves slightly higher accuracy than RDDF.
4.5. RDDF vs. State-of-the-Art: An Empirical Comparison
4.6. RDDF Limitations
5. Conclusions and Future Work
Funding
Institutional Review Board Statement
Informed Consent Statement
Data Availability Statement
Conflicts of Interest
References
- El Zein, H.; Harb, H.; Delmotte, F.; Zahwe, O.; Haddad, S. VAS-3D: A Visual-Based Alerting System for Detecting Drowsy Drivers in Intelligent Transportation Systems. World Electr. Veh. J. 2024, 15, 540. [Google Scholar] [CrossRef]
- Essahraui, S.; Lamaakal, I.; El Hamly, I.; Maleh, Y.; Ouahbi, I.; El Makkaoui, K.; Filali Bouami, M.; Pławiak, P.; Alfarraj, O.; Abd El-Latif, A.A. Real-time driver drowsiness detection using facial analysis and machine learning techniques. Sensors 2025, 25, 812. [Google Scholar] [CrossRef] [PubMed]
- Ahmad Jan, M.; Adil, M.; Brik, B.; Harous, S.; Abbas, S. Making Sense of Big Data in Intelligent Transportation Systems: Current Trends, Challenges and Future Directions. ACM Comput. Surv. 2025, 57, 197. [Google Scholar] [CrossRef]
- Ganguly, B.; Dey, D.; Munshi, S. An Attention Deep Learning Framework-Based Drowsiness Detection Model for Intelligent Transportation System. IEEE Trans. Intell. Transp. Syst. 2025, 26, 4517–4527. [Google Scholar] [CrossRef]
- Jaulkar, S.; Parihar, A. Different types of injury associated with road traffic accidents. Multidiscip. Rev. 2025, 8, e2025111. [Google Scholar] [CrossRef]
- Soares, S.; Monteiro, T.; Lobo, A.; Couto, A.; Cunha, L.; Ferreira, S. Analyzing driver drowsiness: From causes to effects. Sustainability 2020, 12, 1971. [Google Scholar] [CrossRef]
- Cao, S.; Feng, P.; Kang, W.; Chen, Z.; Wang, B. Optimized driver fatigue detection method using multimodal neural networks. Sci. Rep. 2025, 15, 12240. [Google Scholar] [CrossRef]
- Khanna, M.; Nossam, S.C.; Pulastya, G.; Bandi, H.R.; Anirudh, R. Real-time Driver Drowsiness Detection for safer driving using MESA: A multi-agent based modeling framework. AIP Conf. Proc. 2025, 3237, 020002. [Google Scholar]
- Venkatesan, T.; Naveena, S.; Aadhish, M.; Nandha, S. A Smart IoT-Based Framework for Adaptive Drowsiness Detection and Alert Mechanisms for Preventing Fatigue-Induced Accidents. In Proceedings of the 2025 3rd International Conference on Artificial Intelligence and Machine Learning Applications Theme: Healthcare and Internet of Things (AIMLA), Tiruchengode, India, 29–30 April 2025; IEEE: Piscataway, NJ, USA, 2025; pp. 1–4. [Google Scholar]
- Yang, E.; Yi, O. Enhancing road safety: Deep learning-based intelligent driver drowsiness detection for advanced driver-assistance systems. Electronics 2024, 13, 708. [Google Scholar] [CrossRef]
- Jarndal, A.; Tawfik, H.; Siam, A.I.; Alsyouf, I.; Cheaitou, A. A real-time vision transformers-based system for enhanced driver drowsiness detection and vehicle safety. IEEE Access 2024, 13, 1790–1803. [Google Scholar] [CrossRef]
- Doudou, M.; Bouabdallah, A.; Berge-Cherfaoui, V. Driver drowsiness measurement technologies: Current research, market solutions, and challenges. Int. J. Intell. Transp. Syst. Res. 2020, 18, 297–319. [Google Scholar] [CrossRef]
- El-Nabi, S.A.; El-Shafai, W.; El-Rabaie, E.S.M.; Ramadan, K.F.; Abd El-Samie, F.E.; Mohsen, S. Machine learning and deep learning techniques for driver fatigue and drowsiness detection: A review. Multimed. Tools Appl. 2024, 83, 9441–9477. [Google Scholar] [CrossRef]
- Lacherre, J.; Castillo-Sequera, J.L.; Mauricio, D. Factors, prediction, and explainability of vehicle accident risk due to driving behavior through machine learning: A systematic literature review, 2013–2023. Computation 2024, 12, 131. [Google Scholar] [CrossRef]
- Wang, D.; Pei, X.; Li, L.; Yao, D. Risky driver recognition based on vehicle speed time series. IEEE Trans. Hum.-Mach. Syst. 2017, 48, 63–71. [Google Scholar] [CrossRef]
- Dehzangi, O.; Masilamani, S. Unobtrusive driver drowsiness prediction using driving behavior from vehicular sensors. In Proceedings of the 2018 24th International Conference on Pattern Recognition (ICPR), Beijing, China, 20–24 August 2018; pp. 3598–3603. [Google Scholar]
- Arefnezhad, S.; Samiee, S.; Eichberger, A.; Nahvi, A. Driver drowsiness detection based on steering wheel data applying adaptive neuro-fuzzy feature selection. Sensors 2019, 19, 943. [Google Scholar] [CrossRef]
- Shahverdy, M.; Fathy, M.; Berangi, R.; Sabokrou, M. Driver behavior detection and classification using deep convolutional neural networks. Expert Syst. Appl. 2020, 149, 113240. [Google Scholar] [CrossRef]
- Jiao, Y.; Deng, Y.; Luo, Y.; Lu, B.L. Driver sleepiness detection from EEG and EOG signals using GAN and LSTM networks. Neurocomputing 2020, 408, 100–111. [Google Scholar] [CrossRef]
- Ma, Y.; Chen, B.; Li, R.; Wang, C.; Wang, J.; She, Q.; Luo, Z.; Zhang, Y. Driving fatigue detection from EEG using a modified PCANet method. Comput. Intell. Neurosci. 2019, 2019, 4721863. [Google Scholar] [CrossRef]
- Luo, H.; Qiu, T.; Liu, C.; Huang, P. Research on fatigue driving detection using forehead EEG based on adaptive multi-scale entropy. Biomed. Signal Process. Control 2019, 51, 50–58. [Google Scholar] [CrossRef]
- Budak, U.; Bajaj, V.; Akbulut, Y.; Atila, O.; Sengur, A. An effective hybrid model for EEG-based drowsiness detection. IEEE Sens. J. 2019, 19, 7624–7631. [Google Scholar] [CrossRef]
- de Naurois, C.J.; Bourdin, C.; Stratulat, A.; Diaz, E.; Vercher, J.L. Detection and prediction of driver drowsiness using artificial neural network models. Accid. Anal. Prev. 2019, 126, 95–104. [Google Scholar] [CrossRef]
- Zhang, X.; Wang, X.; Yang, X.; Xu, C.; Zhu, X.; Wei, J. Driver drowsiness detection using mixed-effect ordered logit model considering time cumulative effect. Anal. Methods Accid. Res. 2020, 26, 100114. [Google Scholar] [CrossRef]
- Wang, J.; Cai, M.; Zhu, Z.; Ding, H.; Yi, J.; Du, A. VTD: Visual and Tactile Database for Driver State and Behavior Perception. arXiv 2024, arXiv:2412.04888. [Google Scholar] [CrossRef]
- Bouaziz, B. Drowsiness Detection Dataset. 2020. Available online: https://github.com/bassem-bouaziz/Drowsiness_Detection (accessed on 7 January 2023).
- Cramer, J.S. The Origins of Logistic Regression; Tinbergen Institute: Amsterdam/Rotterdam, The Netherlands, 2002; pp. 167–178. [Google Scholar]
- Yan, L.; Huang, Z.; Zhang, Y.; Zhang, L.; Zhu, D.; Ran, B. Driving risk status prediction using Bayesian networks and logistic regression. IET Intell. Transp. Syst. 2017, 11, 431–439. [Google Scholar] [CrossRef]
- Murata, A. Proposal of a method to predict subjective rating on drowsiness using physiological and behavioral measures. IIE Trans. Occup. Ergon. Hum. Factors 2016, 4, 128–140. [Google Scholar] [CrossRef]
- Parmar, A.; Katariya, R.; Patel, V. A review on random forest: An ensemble classifier. In Proceedings of the International Conference on Intelligent Data Communication Technologies and Internet of Things; Springer: Cham, Switzerland, 2018; pp. 758–763. [Google Scholar]
- Gwak, J.; Hirao, A.; Shino, M. An investigation of early detection of driver drowsiness using ensemble machine learning based on hybrid sensing. Appl. Sci. 2020, 10, 2890. [Google Scholar] [CrossRef]
- Tao, Q.; Zhang, R.; Yan, Y.; Zhang, C.; Li, Z. Improvement of random forest cascade regression algorithm and its application in fatigue detection. In Proceedings of the 2019 IEEE 2nd International Conference on Electronics Technology (ICET), Chengdu, China, 10–13 May 2019; pp. 499–503. [Google Scholar]
- Charbuty, B.; Abdulazeez, A. Classification based on decision tree algorithm for machine learning. J. Appl. Sci. Technol. Trends 2021, 2, 20–28. [Google Scholar] [CrossRef]
- Hu, J.; Min, J. Automated detection of driver fatigue based on EEG signals using gradient boosting decision tree model. Cogn. Neurodynamics 2018, 12, 431–440. [Google Scholar] [CrossRef]
- Yimyam, W.; Ketcham, M. The System for Driver Fatigue Monitoring Using Decision Tree via Wireless Sensor Network for Intelligent Transport System. Int. J. Online Eng. 2018, 14, 21–39. [Google Scholar] [CrossRef]
- Yao, Y.; Zhao, X.; Du, H.; Zhang, Y.; Zhang, G.; Rong, J. Classification of fatigued and drunk driving based on decision tree methods: A simulator study. Int. J. Environ. Res. Public Health 2019, 16, 1935. [Google Scholar] [CrossRef]
- Hand, D.J.; Yu, K. Idiot’s Bayes—Not so stupid after all? Int. Stat. Rev. 2001, 69, 385–398. [Google Scholar]
- Bakheet, S.; Al-Hamadi, A. A Framework for Instantaneous Driver Drowsiness Detection Based on Improved HOG Features and Naïve Bayesian Classification. Brain Sci. 2021, 11, 240. [Google Scholar] [CrossRef]
- Nsaif, A.K.; Ali, S.H.M.; Jassim, K.N.; Nseaf, A.K.; Sulaiman, R.; Al-Qaraghuli, A.; Wahdan, O.; Nayan, N.A. FRCNN-GNB: Cascade Faster R-CNN With Gabor Filters and Naïve Bayes for Enhanced Eye Detection. IEEE Access 2021, 9, 15708–15719. [Google Scholar] [CrossRef]
- Abu Alfeilat, H.A.; Hassanat, A.B.; Lasassmeh, O.; Tarawneh, A.S.; Alhasanat, M.B.; Eyal Salman, H.S.; Prasath, V.S. Effects of distance measure choice on k-nearest neighbor classifier performance: A review. Big Data 2019, 7, 221–248. [Google Scholar] [CrossRef] [PubMed]
- Li, Z.; Zhang, Q.; Zhao, X. Performance analysis of K-nearest neighbor, support vector machine, and artificial neural network classifiers for driver drowsiness detection with different road geometries. Int. J. Distrib. Sens. Netw. 2017, 13, 1550147717733391. [Google Scholar] [CrossRef]
- Ekaputri, C.; Fu’adah, Y.N.; Pratiwi, N.K.C.; Rizal, A.; Sularso, A.N. Drowsiness Detection Based on EEG Signal Using Discrete Wavelet Transform (DWT) and K-Nearest Neighbors (K-NN) Methods. In Proceedings of the 1st International Conference on Electronics, Biomedical Engineering, and Health Informatics; Springer: Singapore, 2021; pp. 487–498. [Google Scholar]
- Hemalatha, K.; Rani, K.U. Advancements in multi-layer perceptron training to improve classification accuracy. Int. J. Recent Innov. Trends Comput. Commun. 2017, 5, 353–357. [Google Scholar]
- Chou, C.L.; Huang, Y.H.; Ho, S.C. Blink Detection Using Facial Landmark Blink Detector and Multi-Layer Perceptron. In Proceedings of the NCS 2019, Huntsville, AL, USA, 4–6 June 2019; pp. 542–545. [Google Scholar]
- Zou, B.; Shen, M.; Li, X.; Zheng, Y.; Zhang, L. EEG-based driving fatigue detection during operating the steering wheel data section. In Proceedings of the 2020 42nd Annual International Conference of the IEEE Engineering in Medicine & Biology Society (EMBC), Montreal, QC, Canada, 20–24 July 2020; pp. 248–251. [Google Scholar]
- Guo, K.; He, L.; Chen, Y.; Guo, W.; Zheng, J. A local community detection algorithm based on internal force between nodes. Appl. Intell. 2020, 50, 328–340. [Google Scholar] [CrossRef]
- Diana, N.E.; Ulfa, I.H. Measuring Performance of N-Gram and Jaccard-Similarity Metrics in Document Plagiarism Application. J. Physics Conf. Ser. 2019, 1196, 012069. [Google Scholar] [CrossRef]
- Li, B.; Gao, M.; Ma, L.; Liang, Y.; Chen, G. Web application-layer DDoS attack detection based on generalized Jaccard similarity and information entropy. In Proceedings of the International Conference on Artificial Intelligence and Security; Springer: Cham, Switzerland, 2019; pp. 576–585. [Google Scholar]
- Moodley, R.; Chiclana, F.; Caraffini, F.; Carter, J. Application of uninorms to market basket analysis. Int. J. Intell. Syst. 2019, 34, 39–49. [Google Scholar] [CrossRef]


| SWA | PP | VS | TAV | EEG | |
|---|---|---|---|---|---|
| SWA | 1.00 | 0.32 | 0.27 | 0.18 | 0.21 |
| PP | 0.32 | 1.00 | 0.35 | 0.42 | 0.29 |
| VS | 0.27 | 0.35 | 1.00 | 0.44 | 0.26 |
| TAV | 0.18 | 0.42 | 0.44 | 1.00 | 0.19 |
| EEG | 0.21 | 0.29 | 0.26 | 0.19 | 1.00 |
| SWA | PP | VS | TAV | {SWA, PP, VS, TAV} | EEG | ||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Acc. | Pre. | Rec. | F1 | Acc. | Pre. | Rec. | F1 | Acc. | Pre. | Rec. | F1 | Acc. | Pre. | Rec. | F1 | Acc. | Pre. | Rec. | F1 | Acc. | Pre. | Rec. | F1 | ||
| s | LR | 0.94 | 0.88 | 0.08 | 0.14 | 0.91 | 0.5 | 0.007 | 0.01 | 0.96 | 1 | 0.01 | 0.03 | 0.98 | 0.63 | 0.21 | 0.31 | 0.94 | 0.76 | 0.17 | 0.28 | 0.57 | 0.6 | 0.6 | 0.6 |
| RF | 0.99 | 0.99 | 0.98 | 0.98 | 0.91 | 0.37 | 0.04 | 0.07 | 0.96 | 0.33 | 0.01 | 0.03 | 0.98 | 0.66 | 0.31 | 0.42 | 0.99 | 0.94 | 0.97 | 0.96 | 0.66 | 0.7 | 0.65 | 0.67 | |
| DT | 0.99 | 0.96 | 0.98 | 0.97 | 0.84 | 0.17 | 0.17 | 0.17 | 0.92 | 0.08 | 0.09 | 0.09 | 0.98 | 0.95 | 0.43 | 0.57 | 0.99 | 0.93 | 0.98 | 0.95 | 0.63 | 0.65 | 0.62 | 0.63 | |
| NB | 0.94 | 0.54 | 1 | 0.7 | 0.69 | 0.06 | 0.17 | 0.09 | 0.72 | 0.06 | 0.4 | 0.1 | 0.98 | 0.55 | 0.23 | 0.32 | 0.94 | 0.55 | 1 | 0.71 | 0.53 | 0.53 | 0.89 | 0.67 | |
| KNN | 0.98 | 0.93 | 0.92 | 0.92 | 0.89 | 0.44 | 0.36 | 0.39 | 0.96 | 0.51 | 0.25 | 0.33 | 0.98 | 0.66 | 0.3 | 0.42 | 0.96 | 0.81 | 0.65 | 0.72 | 0.59 | 0.62 | 0.6 | 0.61 | |
| MLP | 0.99 | 0.97 | 0.89 | 0.93 | 0.9 | 0.33 | 0.02 | 0.03 | 0.96 | - | 0 | - | 0.98 | 0.36 | 0.24 | 0.35 | 0.93 | 0.5 | 0 | 0.01 | 0.53 | 0.6 | 0.4 | 0.48 | |
| JKNN | 0.99 | 0.97 | 1 | 0.98 | 0.99 | 0.98 | 1 | 0.99 | 0.99 | 0.81 | 1 | 0.9 | 0.98 | 0.95 | 1 | 0.97 | 0.98 | 0.81 | 1 | 0.89 | 0.99 | 0.94 | 1 | 0.97 | |
| s | LR | 0.95 | 0.84 | 0.18 | 0.3 | 0.93 | - | 0 | - | 0.96 | 0.25 | 0.02 | 0.05 | 0.99 | 0.6 | 0.48 | 0.54 | 0.95 | 0.76 | 0.16 | 0.27 | 0.52 | 0.53 | 0.6 | 0.56 |
| RF | 0.98 | 0.91 | 0.88 | 0.89 | 0.92 | 0.33 | 0.01 | 0.02 | 0.95 | 0.5 | 0.02 | 0.04 | 0.97 | 0.61 | 0.27 | 0.38 | 0.98 | 0.9 | 0.87 | 0.88 | 0.65 | 0.69 | 0.62 | 0.65 | |
| DT | 0.98 | 0.92 | 0.9 | 0.91 | 0.87 | 0.15 | 0.14 | 0.14 | 0.94 | 0.05 | 0.06 | 0.06 | 0.98 | 0.91 | 0.39 | 0.55 | 0.99 | 0.86 | 0.96 | 0.9 | 0.59 | 0.62 | 0.58 | 0.6 | |
| NB | 0.93 | 0.52 | 1 | 0.68 | 0.43 | 0.05 | 0.5 | 0.09 | 0.74 | 0.05 | 0.44 | 0.09 | 0.98 | 0.53 | 0.23 | 0.32 | 0.94 | 0.56 | 1 | 0.72 | 0.53 | 0.53 | 0.88 | 0.66 | |
| KNN | 0.98 | 0.89 | 0.9 | 0.89 | 0.9 | 0.36 | 0.25 | 0.29 | 0.94 | 0.43 | 0.22 | 0.29 | 0.98 | 0.63 | 0.3 | 0.41 | 0.96 | 0.72 | 0.58 | 0.64 | 0.61 | 0.61 | 0.66 | 0.64 | |
| MLP | 0.99 | 0.92 | 0.91 | 0.92 | 0.93 | 0.2 | 0.01 | 0.02 | 0.96 | - | 0 | - | 0.98 | 0.6 | 0.24 | 0.35 | 0.93 | - | 0 | - | 0.46 | 0.5 | 0.13 | 0.21 | |
| JKNN | 0.99 | 0.91 | 1 | 0.95 | 0.99 | 0.9 | 1 | 0.95 | 0.99 | 0.8 | 1 | 0.88 | 0.99 | 0.89 | 1 | 0.94 | 0.99 | 0.8 | 1 | 0.88 | 0.98 | 0.92 | 1 | 0.96 | |
| s | LR | 0.95 | 0.75 | 0.19 | 0.3 | 0.91 | - | 0 | - | 0.96 | 0.33 | 0.03 | 0.06 | 0.98 | 0.53 | 0.5 | 0.51 | 0.94 | 0.83 | 0.24 | 0.38 | 0.6 | 0.62 | 0.6 | 0.61 |
| RF | 0.98 | 0.91 | 0.8 | 0.85 | 0.93 | 0.5 | 0.03 | 0.06 | 0.97 | 0.5 | 0.09 | 0.15 | 0.96 | 0.61 | 0.25 | 0.36 | 0.98 | 0.92 | 0.81 | 0.86 | 0.65 | 0.7 | 0.63 | 0.66 | |
| DT | 0.99 | 0.95 | 0.87 | 0.91 | 0.86 | 0.12 | 0.12 | 0.12 | 0.94 | 0.06 | 0.1 | 0.07 | 0.98 | 0.94 | 0.38 | 0.54 | 0.99 | 0.9 | 0.95 | 0.93 | 0.59 | 0.62 | 0.55 | 0.58 | |
| NB | 0.92 | 0.49 | 1 | 0.66 | 0.71 | 0.06 | 0.25 | 0.1 | 0.7 | 0.03 | 0.23 | 0.05 | 0.96 | 0.5 | 0.23 | 0.32 | 0.93 | 0.46 | 1 | 0.63 | 0.5 | 0.51 | 0.88 | 0.65 | |
| KNN | 0.98 | 0.84 | 0.77 | 0.81 | 0.91 | 0.46 | 0.27 | 0.34 | 0.95 | 0.28 | 0.18 | 0.22 | 0.98 | 0.6 | 0.25 | 0.29 | 0.96 | 0.79 | 0.41 | 0.54 | 0.61 | 0.64 | 0.69 | 0.66 | |
| MLP | 0.98 | 0.83 | 0.85 | 0.84 | 0.91 | 0.25 | 0.04 | 0.08 | 0.96 | - | 0 | - | 0.97 | 0.54 | 0.23 | 0.32 | 0.95 | 0.63 | 0.63 | 0.45 | 0.52 | 0.54 | 0.68 | 0.6 | |
| JKNN | 0.98 | 0.86 | 1 | 0.92 | 0.99 | 0.85 | 1 | 0.91 | 0.98 | 0.73 | 1 | 0.84 | 0.99 | 0.55 | 1 | 0.71 | 0.98 | 0.55 | 1 | 0.71 | 0.98 | 0.9 | 1 | 0.95 | |
| Classifier | T = 2 s | T = 3 s | T = 4 s |
|---|---|---|---|
| Logistic Regression (LR) | 2.9 | 4.2 | 6.0 |
| Decision Tree (DT) | 0.8 | 1.1 | 1.6 |
| Random Forest (RF) | 8.7 | 12.6 | 17.8 |
| Naïve Bayes (Gaussian NB) | 0.6 | 0.9 | 1.3 |
| K-Nearest Neighbors (KNN, K = 5) | 0.2 | 0.3 | 0.5 |
| Multi-Layer Perceptron (MLP, 500/250/40 neurons) | 68.3 | 95.4 | 132.1 |
| Jaccard-KNN (JKNN, K = 5) | 27.0 | 38.2 | 52.4 |
| Reference | Year | Technique | Monitored Behavior | Measures | Accuracy |
|---|---|---|---|---|---|
| Wang et al. [15] | 2017 | SVM | Driving | VS | |
| Dehzangi et al. [16] | 2018 | DT + Ensemble | Driving | Acceleration, Braking, SWM | |
| Arefnezhad et al. [17] | 2019 | Fuzzy inference + SVM | Driving | SWM | |
| Ma et al. [20] | 2019 | PCANet + SVM + KNN | Driver | EEG | |
| Luo et al. [21] | 2019 | ASF + Entropy | Driver | EEG | |
| Budak et al. [22] | 2019 | LSTM | Driver | EEG | |
| De Naurois et al. [23] | 2019 | CNN | Driving and Driver | Heart rate, head movement, EM, VLD, VS, SWM | |
| Shahverdy et al. [18] | 2020 | CNN | Driving | Gravity, VS, throttle, acceleration | |
| Jiao et al. [19] | 2020 | WT + LSTM | Driver | EEG, EOG | |
| Zhang et al. [24] | 2020 | Logit function | Driving and Driver | VLD, EM | |
| This work | 2025 | RDDF | Driving and Driver | SWA, PP, VS, TAV, EEG |
| Reference | Accuracy (%) | Precision (%) | Recall (%) | F1-Score (%) |
|---|---|---|---|---|
| De Naurois et al. [23] | 92.0 ± 0.9 | 91.5 ± 0.6 | 90.8 ± 0.7 | 91.1 ± 0.6 |
| Shahverdy et al. [18] | 90.5 ± 1.1 | 90.0 ± 1.06 | 89.7 ± 0.97 | 89.9 ± 0.99 |
| RDDF | 95.8 ± 0.42 | 95.4 ± 0.57 | 95.1 ± 0.61 | 95.2 ± 0.58 |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2025 by the author. Published by MDPI on behalf of the World Electric Vehicle Association. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Harb, H. An Efficient Drowsiness Detection Framework for Improving Driver Safety Through Supervised Learning Models. World Electr. Veh. J. 2025, 16, 620. https://doi.org/10.3390/wevj16110620
Harb H. An Efficient Drowsiness Detection Framework for Improving Driver Safety Through Supervised Learning Models. World Electric Vehicle Journal. 2025; 16(11):620. https://doi.org/10.3390/wevj16110620
Chicago/Turabian StyleHarb, Hassan. 2025. "An Efficient Drowsiness Detection Framework for Improving Driver Safety Through Supervised Learning Models" World Electric Vehicle Journal 16, no. 11: 620. https://doi.org/10.3390/wevj16110620
APA StyleHarb, H. (2025). An Efficient Drowsiness Detection Framework for Improving Driver Safety Through Supervised Learning Models. World Electric Vehicle Journal, 16(11), 620. https://doi.org/10.3390/wevj16110620