## 5 Conclusions  
We have proposed an approach for detecting driver fatigue and distracted driving. Our approach uses the face and posture information of the driver to determine the driving status. For driver fatigue detection, our approach uses six fatigue parameters and the YawDD data set for training. Random forest is then trained to determine whether the driver is fatigued. The average accuracies are 100% for both face and eye detection. Moreover, the average accuracies of eye opening and closing detection using the EAR metric is 94.5%. For classification, the random forest algorithm can achieve the accuracy of 91%. The frequency of yawning is the most crucial parameter for detecting driver fatigue because it was highly related to the use of the YawDD data set for training. Other data sets can be added for training and a smaller feature detection network can be used for improvement. For distracted driving, our approach can be detected in real-time on the Nvidia Jetson TX2 platform. The results demonstrate that our approach performs better than the previous methods.  
In future research, we aim to use a CNN to more accurately estimate where the driver is looking and to process eye information for detecting driver fatigue. Moreover, we aim to reduce the computational expense by using a smaller face detection network while maintaining adequate accuracy.  
Methodology, B.-T.D. and H.-Y.L.; Supervision, H.-Y.L. and C.-C.C.; Writing--original draft, B.-T.D.; Writing--review & editing, H.-Y.L. and C.-C.C. All authors have read and agreed to the published version of the manuscript.  
\begin{table}
\begin{tabular}{c c} \hline \hline
**Method** & **Accuracy** \\ \hline Pixel SVC [38] & 18.3\% \\ SVC + HOG [38] & 28.2\% \\ SVC + PCA [38] & 34.8\% \\ SVC + Bbox + PCA [38] & 40.7\% \\ VGG-16 [38] & 90.2\% \\ VGG-GAP [38] & 91.3\% \\ MLP [27] & 82\% \\ RNN [27] & 91.7\% \\ Drive-Net [27] & 95\% \\ Ensemble VGG-16 and VGG-GAP [28] & 92.6\% \\ RGB + Optical flow [28] & 94\% \\ Our approach & 97.5\% \\ \hline \hline \end{tabular}
\end{table}
Table 6: Comparison of the proposed distracted driving detection with previous methods.  
\begin{table}
\begin{tabular}{c c c c c c c c c c c} \hline \hline  & **c0** & **c1** & **c2** & **c3** & **c4** & **c5** & **c6** & **c7** & **c8** & **c9** \\ \hline c0 & 1949 & 25 & 2 & 17 & 1 & 1 & 0 & 0 & 0 & 0 \\ c1 & 5 & 1799 & 3 & 2 & 0 & 0 & 0 & 1 & 0 & 1 \\ c2 & 0 & 6 & 1819 & 0 & 0 & 4 & 3 & 0 & 11 & 0 \\ c3 & 17 & 2 & 1 & 1805 & 5 & 0 & 0 & 2 & 0 & 0 \\ c4 & 4 & 9 & 2 & 4 & 1819 & 0 & 3 & 10 & 8 & 2 \\ c5 & 6 & 0 & 1 & 3 & 5 & 1826 & 10 & 1 & 1 & 3 \\ c6 & 3 & 2 & 4 & 0 & 0 & 1 & 1849 & 0 & 24 & 0 \\ c7 & 1 & 1 & 0 & 0 & 1 & 0 & 1 & 1577 & 17 & 5 \\ c8 & 0 & 0 & 1 & 0 & 6 & 0 & 1 & 4 & 1523 & 14 \\ c9 & 2 & 0 & 0 & 8 & 0 & 4 & 1 & 2 & 16 & 1673 \\ \hline \hline \end{tabular}
\end{table}
Table 7: Confusion matrix for the Kaggle data set.  
**Funding:** The authors would like to thank the Ministry of Science and Technology of Taiwan for financially supporting this research under Contract No. MOST 111-2221-E-239-027.  
**Institutional Review Board Statement:** Some participants participated in the collection of public databases, and they will be informed by the authors that their facial expressions will be used for research. Some participants participation has been recorded in the author's database, and they will also be informed that their facial expressions will be used for research. The authors have also selected and used a few of their students to be drivers.  
**Informed Consent Statement:** Not applicable.  
**Data Availability Statement:** Not applicable.  
**Acknowledgments:** This paper is a revised and expanded version of a paper entitled, \"An on-board monitoring system for driving fatigue and distraction detection,\" in Proceedings of the 22 nd IEEE International Conference on Industrial Technology (ICIT), Valencia, Spain, 10-12 March 2021.  
**Conflicts of Interest:** The authors declare no conflict of interest.