This project aims to detect drowsiness in individuals using computer vision techniques. It is implemented using Python and Keras.
The Drowsiness Detection System monitors the eyes of an individual through a webcam feed. It detects if the person's eyes are closed for an extended period, which could indicate drowsiness or fatigue. When drowsiness is detected, an alarm is triggered to alert the individual.
- Real-time monitoring of eye state (open/closed) using computer vision
- Sound alarm when drowsiness is detected
- Adjustable sensitivity level for drowsiness detection
- Simple and intuitive interface
- Clone the repository to your local machine:
git clone https://github.com/your-username/drowsiness-detection.git
- Install the required dependencies:
pip install -r requirements.txt
- Run the drowsiness_detection.py script:
python drowsiness_detection.py
- Ensure your webcam is connected and functioning properly.
- Run the drowsiness_detection.py script.
- Adjust the alarm threshold and other parameters as needed.
- Keep your eyes visible to the webcam for accurate detection.
- When drowsiness is detected, the alarm will sound.
- OpenCV: Computer vision library for image and video processing
- Keras: Deep learning library for building and training neural networks
- NumPy: Library for numerical computing in Python
- Pygame: Library for multimedia applications, used for sound playback
Contributions are welcome! If you have suggestions for improving the project or find any issues, please open an issue or submit a pull request.