Driver Drowsiness Detection | AI & Vision Real-Time Safety

πŸ” Project Overview

The Driver Drowsiness Detection System is an AI-powered safety solution that uses computer vision and machine learning to monitor driver alertness in real time. By analyzing eye closure, yawning, and head movement through a webcam, the system provides instant alerts to help prevent accidents caused by fatigue.

πŸ† Key Achievements

  • 44 - Real-time detection: Monitors drowsiness and yawning instantly via webcam
  • Multi-feature analysis: Tracks eyes, mouth, and head position for robust detection
  • Fast inference : Results in seconds per scan
  • Cross-platform: Immediate sound notification for drowsiness events
  • User-friendly GUI: Simple interface built with Tkintern

πŸŽ₯ Project Explanation Video

πŸ“Œ Video Highlights

  • Live drowsiness detection demo
  • Real-time alerts for eye closure and yawning
  • Head movement and attention monitoringos

πŸ› οΈ Technical Stack

Frontend

  • Tkinter (Python GUI)
  • HTML5 / CSS3 / JavaScript
  • Responsive UI Design

Backend

  • Python 3.7+
  • OpenCV for video processing
  • dlib for facial landmark
  • NumPy, SciPy, imutils for data processings
  • playsound for audio alerts

πŸ“‚ Project Structure: Driver Drowsiness Detection System

driver-drowsiness-detection/
β”‚
β”œβ”€β”€ index.html                        # Main web page (project showcase)
β”‚
β”œβ”€β”€ requirement.txt                   # Python dependencies for macOS
β”‚
β”œβ”€β”€ DrowsinessDetector.py             # Main Python script
β”‚
β”œβ”€β”€ shape_predictor_68_face_landmarks.dat  # Pre-trained model (large file)
β”‚
β”œβ”€β”€ alert.mp3                         # Audio alert file
β”‚
β”œβ”€β”€ SVMclassifier.dat                 # (If used) SVM model file
β”‚
β”œβ”€β”€ run.bat                           # (Optional) Windows batch file to run the script
β”‚
β”œβ”€β”€ video/
β”‚   └── demo.mp4                      # Demo video of your project
β”‚
β”œβ”€β”€ images/                           # (Optional) Folder for screenshots, thumbnails, etc.
β”‚   └── thumbnail.jpg                 # Thumbnail for video (used in HTML poster)
β”‚
β”œβ”€β”€ src/                              # (Optional) Source code folder if you want to organize scripts
β”‚   └── ...                           # Additional Python scripts or modules
β”‚
β”œβ”€β”€ docs/                             # (Optional) Documentation, reports, or extra info
β”‚   └── README.md                     # Project readme (if not in root)
β”‚
β”œβ”€β”€ .idea/                            # (Optional) IDE/project config files (can be ignored for sharing)
β”‚   └── ...                           # PyCharm or VSCode config files
β”‚
└── Dlib_Windows_Python3.x-main/      # (Optional) Dlib Windows wheel and related files (not needed for macOS)
    └── ...                           # Dlib wheel, README, etc.

How It Works:

  • Captures video from the webcam in real time
  • Detects facial landmarks to monitor eyes, mouth, and head position
  • Calculates Eye Aspect Ratio (EAR) and Mouth Aspect Ratio (MAR) to detect drowsiness and yawning
  • Triggers an audio alert if drowsiness or yawning is detected
  • Displays results and status in a user-friendly GUI

✨ Core Features

  • Real-Time Monitoring : Detects drowsiness and yawning instantly
  • Audio Alerts: Notifies the driver immediately
  • Head Movement Detection: Alerts if the driver looks away or down
  • Easy Setup: Simple installation and usage instructionsg

πŸ’‘ Why This Matters

  • Drowsy driving is a leading cause of road accidents. This system helps prevent accidents by alerting drivers before fatigue becomes dangerous.

About :

  • Developed by : Praveen Kumar
  • For more information, contact: praveen11x@gmail.com

πŸš€ Ready to Build Something Similar?

Need a custom AI solution? Let’s build a cutting-edge system together.

πŸ’Ύ Download Project Files

You can access the full Project.

Includes: Source code, web app files, trained models, dataset (optional), and deployment scripts.


Need custom setup and web app version?
Contact us β†’

πŸš€ Let’s Work Together

πŸš€ Let’s Work Together