Driver Drowsiness Detection System
issue 1

Driver Drowsiness Detection System

1Divya Zade, 2Manjusha Nannaware, 3Prajakta Umare, 4Yogeshree Bawankule, 5 Dr. A.A Jaiswal
1Student, 2Student, 3Student, 4Student, 5Head of Department
1Computer Technology, 2Computer Technology, 3Computer Technology, 4Computer Technology, 5Computer Technology 1K
1K.D.K.College of Engineering, Nagpur, India, 2K.D.K.College of Engineering, Nagpur, India, 3K.D.K.College of Engineering
Nagpur, India, 4K.D.K.College of Engineering, Nagpur, India, 5K.D.K.College of Engineering, Nagpur, India

Abstract:

In recent years driver weariness is one of the major causes of vehicle accidents in the world. A direct way of measuring driver weariness is measuring the state if the driver i.e. drowsiness. So it is very important to detect the over-tiredness of the driver to save life and property. This project is aimed towards developing a prototype of an exhaustion/weariness detection system. This system is a real- time system which takes image endless and marks the state of the eye according to the specified algorithm and gives a warning if required. Though there are several methods for measuring the drowsiness this approach is completely non- invasive which does not affect the driver in any way hence giving the exact condition of the driver. The priority is on improving the safety of the driver without being interrupting. In this concept/plan, the eye flicker of the driver is decried. If the driver’s eyes remain to liquidate for more than a definite time, the driver is said to be tired and an alarm is sounded. The programming for this is done in OpenCV for the detection of face/look features. The entire system is implemented using Python-3.6.8 and Ubuntu 16.04.

Keywords – OpenCV, Drowsiness, Accident, Live Detect, Eye blinks, Ubuntu, Python.

I. INTRODUCTION

Driver weariness detection is a car safety technology that prevents accidents when the driver is getting weary. Various studies have suggested that around 20% of all road accidents are weariness-related, up to 50% on many different roads. Driver inattention might be the result of shortness of remodeling when driving due to driver weariness and distraction. Driver obstruction occurs when an object or thing draws a person’s attention away from the driving task. This paper aims to develop a prototype of a weary driver warning system our whole focus and concentration will be placed on manipulative the system that will validly monitor the open and closed circumstances of the driver’s eye in real-time. By persistently monitoring the eyes, it can be seen that the expression of the driver’s lack of vitality can be detected early enough to avoid an accident. This discernment can be done using the advancement of an image of eyes as well as face and head gestures. The observation of eye gesture and its edges for the discernment will be used. Devices to detect when drivers are falling asleep and to provide a warning/alarm to attentive them of the risk, or even control the vehicle’s movement, have been the subject to much research and development.

II. EXISTING SYSTEM

By using a non-intrusive machine vision based concepts, drowsy/weariness of the driver detected system is developed. Many existing systems require a camera which is installed in front of driver [4]. It points straight towards the face of the driver and monitors the driver’s eyes in order to identify the drowsiness. For large vehicle such as heavy trucks and buses this arrangement is not pertinent. Bus has a large front glass window to have a broad view for safe driving. If we place a camera on the window of front glass, the camera blocks the frontal view of driver so it is not practical. If the camera is placed on the frame which is just about the window, then the camera is unable to detain the anterior view of the face of the driver correctly. The open CV detector detects only 40% of face of driver in normal driving position in video recording of 10 minutes. In the oblique view, the Open CV eye detector (CV-ED) frequently or continuously fails to trace the pair of eyes. If the eyes are closed for five successive frames the system or machine concludes that the driver is declining slumbering and issues a warning signal [4]. Hence existing system is not applicable for large vehicles. In order to conquer the problem of existing system, new detection system is developed in this project work.

III. RELATED WORK

  • They are find out the action, means the units are positive or negative of drowsiness. Using (FACS) facials action coding system, on basis of that they are defining whether the driver are drowsy or alert.[1,2]
  • (ALERT) Computer Expression Recognition Toolbox. This is a toolbox which are used for detecting the facial movement. They are extra feature from face, and find out the state of driver. [3] By using indicator they are detected the power spectrum of EEG brain waves, as a drowsiness are above the limit EEG power of alpha are increases and theta are decreases. By using this EEG technique they are detecting the situation of driver.[4]
  • For detecting the driver condition, they were used (ECR) Eye Closure Rate. This is work well in night, but not in day. Because of sunlight it is impossible for detect retinal reflection of infrared waves.[5]
  • Used Local Binary Patterns – [LBP] and SVM classifier they were found the eye location of the person. After find the eye region, they find the eye state. And finding the drowsiness and build a system for ADAS (Advanced Driver assistance System).[6]
  • Thus with above literature work we have a proposed a system that to detects driver drowsiness using openCV library using python technology.

IV. PROPOSED SYSTEM

We have a proposed a system to detects driver drowsiness using openCV library and Python technology. A web camera capable of capturing a video without blurring them

All the details of our project are following:

SOFTWARE REQUIRED:

  1. Ubuntu/Linux
  2. Python-3.x

HARDWARE REQUIRED:

  1. Advanced Computer System
  2. Camera

GENERAL FLOW:

  • Opening of Camera
  • Dividing into frames
  • Face Detection
  • Feature Extraction
  • Eye Detection
  • Drowsiness Detection
  • Alarm

IMPORTED LIBRARY ARE:

  • scipy.spatial
  • imutils
  • threading
  • numpy
  • playsound
  • argparse
  • dlib
  • cv2

Each library function has its importance and are used according to needs in the program as per requirement of programmer aim. All the packages are easily downloaded except “dlib” which is mainly used for importing and providing the environment to use C++ function into other platform. Which play a vital role to make code run. To import “dlib” we require to download Microsoft visual studio.

A. IMAGE PROCESSING BASED TECHNIQUE

In image processing based techniques, drivers face images that are used for processing so that one can find its frame of mind. From the face image, one can see that the driver is enthralled or dreaming. Using the same images, they can define drowsiness of the driver because in the face image if the driver is sleep lightly then his/her eyes are closed in the image. And other symptoms of weariness can also be observed from the face image. We can surveillance this blueprint/design in three sub-categories.

The implemented project is mainly based on three components:

  1. Face and Eye detection: Performs scale invariant detection using a webcam.
  2. Eye feature extraction: Eye features are extracted using EAR and
  3. Extract single eye and perform drowsiness detection on it.

EAR (Eye aspect Ratio) :-

Where p1, …, p6 are 2D facial landmark locations. The numerator of this equation computes the distance between the vertical eye landmarks while the denominator computes the distance between horizontal eye landmarks, weighting the denominator appropriately since there is only one set of horizontal points but two sets of vertical points. the eye aspect ratio is approximately constant while the eye is open, but will rapidly fall to zero when a blink is taking place. When the person blinks the eye aspect ratio decreases dramatically, approaching zero. As shown in Figure-2, eye aspect ratio is constant, then rapidly drops close to zero, then increases again, indicating a single blink has taken place.

Python Function for calculating EAR as,

def eye_aspect_ratio(self, eye):
A = dist.euclidean(eye[1], eye[5])
B = dist.euclidean(eye[2], eye[4])
C = dist.euclidean(eye[0], eye[3])
ear = (A + B) / (2.0 * C) return ear.

B. EYE BLINKING BASED TECHNIQUE

In this eye blinking rate and eye, closure duration is measured to diagnose the driver’s weariness. Because when the driver felt snooze at that time his/her eye blinking and intend between eyelids are different from normal situations so they are easily weariness. In this system, the position of irises and eye states is to oversee through time to estimate eye blinking frequency and eye close duration and in this type of system uses a remotely or by wi-fi methods, camera are placed to collect video and computer vision methods are then applied to fundamentally localize face, eyes and eyelids positions to measure the ratio of closure. Using these eyes closure and blinking ratio one can detect weariness of driver. In this paper, we represent a methodology for detection of eye blinking in all conscience or actively in real time environment. Here we use the connected component technique and root method to track and blinking of eyes on platform which is open source and developed by Intel.

C. FACE DETECTION

The humanThe human eyes are located in 0.2h to 0.6h heights from the top border of the facial frame area (Where the total height of the face is h). This feature was used and given as an input for the eye detection algorithm of an eye [7]. After detection of the eye, to detect the eyes open or shut the Hough circle detection algorithm methods was used. When the eye is in the open state iris can be detected by Hough circle detection algorithm. To improve the detection mechanism canny filters which is mainly used for image processing for the color, shape and size detection of face. When the eye lids are closed then no iris is detected and this is used to calculate the shut duration of eyes. For every 50 frames of the input video, number of frames for which eye lid is closed and recorded as its input to create the fuzzy input for the system logarithms.

D. TEMPLATE MATCHING TECHNIQUE

In this adroitness/technique, one can use the states of eye i.e. if the driver closes eye/s for some distinct time then the system will activate the alarm. Because this technique system has both closed and open eyes template of the driver. This system can also be an advancement to get open and closed eye markings of driver. This docket is simple and easy to structure because templates of both open and closed eye states are available to the system. Researchers have used this adroitness/technique. Template matching is a method for discovering zones of a picture that match to a format picture. There are two picture classifications the source picture, the picture in which we hope to discover a match to the format image and the Template picture the patch image which will be contrasted with the format picture.

E. USE OF Open CV IN DROWSINESS

OpenCV (Open-source Computer Vision) is the Swiss Army knife of computer vision. It has a wide range of modules that can help us with a lot of computer vision problems. But reasonably most useful part of OpenCV is its architecture and memory management. It provides you with a framework or workable platform in which you can work with images and video in any way you want, using Open CV’s algorithms or your own, without worrying about allocating are allocated memory for images. Open CV libraries and functions are highly optimized and can be used for real time image and video processing. OPENCV’s highly optimized image processing function are used by author for real time image processing of live video feed from camera.

F. DIVIDING INTO FRAMES

Here we deal with a real time situation where in our video gets recorded and needs processing to be done. But the processing can be done only on the image. Hence the captured image has to be divided into frames for further analyzation. In this stage of the process, we deal with identifying the face of the driver. By identifying the frame of face of the driver it mean that detection of facial features or characters through the use of computer. The frame maybe random. Only facial related structures are identified other types of objects are ignored.

G. WORKFLOW OF DETECTION SYSTEM

When the system is initiated a delay for two to three seconds, it experienced for capturing the image for the first time. This results in losing the data from the first three fabricates/frames. The system actually starts its execution once the face or fabrication has been detected. Each detected frames is stored for half a second to crop the image in order to detect the eye. After the eyes have been ex- traced from an image, the current frame is replaced by a new one. The eyes extracted are now categorized in two parts – the left eye and the right eye. Both the eyes are binaries to determine the threshold value and then the results are produced. If the system encounters five consecutive frames with the eyes closed the alarm is triggered for the next five frames. Creating a real time system mechanism means high speed processing. Thus it was decided after generating several results that our proposed system will not be storing the old results as they had no significance and consumed a lot of space therefore slowing down the whole system. So we have taken each frame, generating and saving the results and replacing the previous frame with the current new frame. Once an image is retrieve from a real time detection from a camera and its analysis takes a couple of seconds to generate the results and the accumulation of many frames results together.

V. RESULT

The detection of drowsy state of eye which give an alert signal or warning in the form of audio (Beep or Alarm Sound). Here we have designed such that an eye blink is continuously monitored by the eye blink Camera, if eye is in closing position the buzzer is operated.

• EYE DETECTION PROCESS

VI. ADVANTAGES

The various advantages of the implemented system are mentioned below:

  1. Detection of drowsiness
  2. Decreasing road accident
  3. This method is practically applicable.

VII. APPLICATION

The drowsiness detection system can be used for different applications. One of them is heavy vehicles for example trucks, since the drivers of trucks and cab drivers have long driving periods. It can also be used for commercial vehicles. Many people use public transport facility for travelling. For their safety this system can be used in public vehicles. Heavy things are lifted by using cranes and transporting them to other places. So for overloaded cranes and mobile cranes this system can be used to avoid accidents related to drowsiness.

VIII. CONCLUSION

The existing system consists of various approaches/threaten like image processing, EEG, vehicular, vocal measures, etc. Any of these approaches/threaten don’t give 100% results. The maximum result is achieved using EEG based approaches/threaten but these are intrusive. Other adroitness/techniques also have some limitations which don’t allow them to give a perfect result. Thus based on our study we conclude that if we try with a combination of two or more approaches/threaten such that one can scale down the limitations of other approaches/threaten and thus helps us in providing the best result. This can lead us to make a non- intrusive and most efficient driver drowsiness/weariness detection system. We can combine some image processing approaches/threaten with some vehicular measures and physiological measures. Heart rate and respiration rates can be a good example of physiological Measures/evaluate which are clear indicators of drowsiness. To remove the intrusive nature of physiological measures/evaluate we can use wireless sensors that can be effectively fitted in seat belts, seat covers, etc. In simple words Drowsiness Detection can be explained. The role of the system is to detect facial landmark from images that are collected from the camera while the person is driving the vehicle which is attached to the vehicle and deliver the obtained data to the trained model to identify the driver’s state. Once the collected data is detected to be showing signs of drowsiness the person will be alerted using the speakers in the vehicle so that the person can stop the vehicle to avoid any accidents due to his drowsy or weariness state while driving.

IX. ACKNOWLEDGEMENT

We thank each and every person who was involved with us throughout the project and gave us confidence. Small efforts can also lead to biggest achievements. Without you we could have never reached this level of success in this project. We thank our teachers, guides and colleagues for their unwavering support.

X. REFERENCES

  1. Mehran Pakdaman, M. Mehdi Sanaatiyan, “Design and Implementation of Line Follower Robot”, 2009 Second International Conference on Computer and Electrical Engineering.
  2. Mustafa Engin, Dilşad Engin, “Path Planning of Line Follower Robot”, 2012 5th European DSP Education and Research Conference (EDERC).
  3. Dr. Antonio Carlos Bento, “IoT: NodeMCU 12e X Arduino Uno, Results of an Experimental and Comparative Survey”,Volume 6, Issue 1, January 2018, International Journal of Advance Research in Computer Science and Management Studies.
  4. J. W. Beek, B. Han, K. Kim, Y. Chung and S. Lee, “Real- Time Drowsiness Detection Algorithm for Driver State Monitoring Systems,” 2018 Tenth International Conference on Ubiquitous and Future Networks (ICUFN), Prague,2018
  5. Dr. A. Subbarao, Associate professor, ECE Department, SR Engineering College, Warangal, Telangana, India K. Sahithya, M. Tech student, ECE Department, S.R Engineering College, Warangal, Telangana, India.
  6. Eddie E. Galarza, Fabricio D. Egas, Franklin M. Silva, Paola M. Velasco, Eddie D. Galarza.
  7. Oraan Khunpisuth, Taweechai Chotchinasri, Varakorn Koschakosai and Narit Hnoohom. “Driver Drowsiness Detection using Eye-Closeness Detection,” 2016 12th International Conference on Signal-Image Technology & Internet-Based Systems.
  8. Association for Safe International Road Travel (ASIRT), Road Crash Statistics.
  9. Bangkok Post. (2015, October 20), Thailand’s roads second- deadliest in world, UN Agency finds.
  10. Jan, T., Karnahl, Seifert, K., Hilgenstock, J., & Zobel, R. Don’t sleep and drive – VW’s fatigue detection technology.
  11. International Journal of Engineering and Advanced Technology (IJEAT) ISSN: 2249 – 8958, Volume-8 Issue-4, April, 2019
  12. International Journal of Scientific & Engineering Research, Volume 6, Issue 3, March-2015
  13. ISSN 2348-1196 (print) International Journal of Computer Science and Information Technology Research ISSN 2348- 120X (online) Vol. 4, Issue 3, pp: (127-139), Month: July – September 2016.
  14. Real time drowsy driver detection using haarcascade samples. Dr.Suryaprasad J, Sandesh D, Saraswathi V.
  15. Integrated Approach for Nonintrusive Detection of Driver Drowsiness. Yu, Xun. Duluth: s.n., 2012.
  16. Eye-Blink Detection System for Human-Computer Interaction. Aleksandra Krolak, Pawel Strumillo. Oslo, Norway: s.n., 2010.
  17. MG Terzano, L Parrino, A Sherieri, R Chervin, S Chokroverty, C Guilleminault, M Hirshkowitz, M Mahowald, H
  18. Moldofsky, A Rosa, R Thomas, A Walters. The CAP Sleep Database.
  19. Method of Drowsy State Detection for Driver Monitoring. Miyaji, Masahiro. July 2014, International Journal of Information and Electronics Engineering Vol. 4, No. 4, pp. 264-268.

Related posts

Simulation On Web Controlled Smart Notice Board Using Raspberry pi

admin

A Survey on Range Finder with Ultrasonic Sensor and Arduino

admin

“ Implementation Of Basic SMPS and LED Driver Using Arduino”

admin

Leave a Comment