资源算法Drowsiness_Detection

Drowsiness_Detection

2019-12-23 | |  56 |   0 |   0

Drowsiness Detection OpenCV  

This code can detect your eyes and alert when the user is drowsy.

Sourcerer

图片.png

Applications

This can be used by riders who tend to drive for a longer period of time that may lead to accidents

Code Requirements

The example code is in Python (version 2.7 or higher will work).

Dependencies

  1. import cv2

  2. import imutils

  3. import dlib

  4. import scipy

Description

A computer vision system that can automatically detect driver drowsiness in a real-time video stream and then play an alarm if the driver appears to be drowsy.

Algorithm

Each eye is represented by 6 (x, y)-coordinates, starting at the left-corner of the eye (as if you were looking at the person), and then working clockwise around the eye:.

eye1.jpg

Condition

It checks 20 consecutive frames and if the Eye Aspect ratio is lesst than 0.25, Alert is generated.

Relationship

eye2.png

Summing up

eye3.jpg

For more informati

on, see

Working Example

drowsy.gif

Execution

To run the code, type python Drowsiness_Detection.py

python Drowsiness_Detection.py


上一篇:egl-wayland

下一篇:kubevirt-gpu-device-plugin

用户评价
全部评价

热门资源

  • seetafaceJNI

    项目介绍 基于中科院seetaface2进行封装的JAVA...

  • spark-corenlp

    This package wraps Stanford CoreNLP annotators ...

  • Keras-ResNeXt

    Keras ResNeXt Implementation of ResNeXt models...

  • capsnet-with-caps...

    CapsNet with capsule-wise convolution Project ...

  • inferno-boilerplate

    This is a very basic boilerplate example for pe...