https://docs.google.com/presentation/d/1jy2vhj1zzDbKkfnhmzQMh52ak41wFmeJ9P9hhT9sVwg/edit?usp=sharing

Inspiration

Every year about 800 people die in the United States because of drowsy driving- this problem could be solved with AI that detects drowsiness through facial expressions.

What it does

We use a raspberry pi "DrowsyAI companion" that accompanies a driver in their vehicle, and plays loud music if it detects that the driver is drowsy. Our website allows the user to register or log in, sign in with Spotify, and view metrics about their drowsy driving.

How we built it

We used the Python Django framework for the backend , a raspberry pi as the driver companion and the Django templating language on the frontend. The Raspberry Pi uses OpenCV to detect the closing of the eyes and sends a post request to an endpoint on our website. The website interfaces with Spotify to allow access to a user's music-playing device and, when a user is drowsy, sends a request to Spotify to change the music playing on the user's device.

Challenges we ran into

Integrating the raspberry pi with the backend server was a fairly difficult task. Meeting deadlines we had set for ourselves was also hard. Compiling OpenCV on a Raspberry Pi is a resource-intensive task and setting up a stable test environment was time and labor intensive. The project involved creating frontend html and Django templates, creating a database for login on the backend side and interfacing with Spotify, and communicating between the Pi, the website, and Spotify.

Accomplishments that we're proud of

We were able to complete a fairly non trivial hack within 24 hours!

What we learned

We learnt the importance of planning things out and how to communicate effectively. Tangibly, we learnt how to use ML in low resource environments; peculiarities of the Django and Flask frameworks.

What's next for DrowsyAI

DrowseyAI has a fairly potent business use case- and an even greater social responsibility. We look forward to refining the prototype we made over DragonHacks, and potentially taking it to the real world.

Built With

Share this project:

Updates