Abstract:Drowsiness on the road is a widespread problem with fatal consequences; thus, a multitude of solutions implementing machine learning techniques have been proposed by researchers. Among existing methods, Ghoddoosian et al.'s drowsiness detection method utilizes temporal blinking patterns to detect early signs of drowsiness. Although the method reported promising results, Ghoddoosian et al.'s algorithm was developed and tested only on a powerful desktop computer, which is not practical to apply in a moving vehicle setting. In this paper, we propose an embedded system that can process Ghoddoosian's drowsiness detection algorithm on a small minicomputer and interact with the user by phone; combined, the devices are powerful enough to run a web server and our drowsiness detection server. We used the AioRTC protocol on GitHub to conduct real-time transmission of video frames from the client to the server and evaluated the communication speed and processing times of the program on various platforms. Based on our results, we found that a Mini PC was most suitable for our proposed system. Furthermore, we proposed an algorithm that considers the importance of sensitivity over specificity, specifically regarding drowsiness detection algorithms. Our algorithm optimizes the threshold to adjust the false positive and false negative rates of the drowsiness detection models. We anticipate our proposed platform can help many researchers to advance their research on drowsiness detection solutions in embedded system settings.