Training a Classifier

Using an SVM Classifier to detect sleepiness:

This algorithm works primarily on the principle that if the person has kept his eyes closed for too long the driver is detected to be sleepy. After extracting each frame from a video, we manually classify each image as open or closed eye. We then separate our dataset of images into training and test data - with 30 percent being training-data and the rest 60 percent being test-data. We do this split randomly. This makes our training and test data different each time we run the program. Using SVM Classifier, we generate a model based on a bag of features. We find the accuracy of the model using confusion matrices. The next step is to feed the video and to get labels as open or closed  for each new frame. Whether the eyes are open or closed in each frame. We keep track of how long the eyes have been closed continuously by resetting a count variable (that counts the elapsed time ) each time the eye opens. If the count is beyond a certain threshold value, we conclude that the driver is drowsy.



Comments

Popular posts from this blog

Eye Detection

Yawn Detection