- 1
- 23 030
Muni Chandra Ch
เข้าร่วมเมื่อ 14 ธ.ค. 2019
Driver Drowsiness Detection System Using Convolutional Neural Networks- Python Project.
This is Driver Drowsiness Detection System which is which is developed in the vision to prevent road accidents because of the sleepiness or drowsiness of the driver.
approximately 20% of the road accidents that are occurred is due to the drowsiness of the driver. This is not a small problem to be not taken seriously as it is not only dangerous for the driver himself it is also dangerous to his fellow passengers and the people who uses the same road. More over if things get worse that could even be a crowded area or a school zone.
To prevent all these complications driver drowsiness detection system is being developed which can potentially save a lot of lives from accidents.
approximately 20% of the road accidents that are occurred is due to the drowsiness of the driver. This is not a small problem to be not taken seriously as it is not only dangerous for the driver himself it is also dangerous to his fellow passengers and the people who uses the same road. More over if things get worse that could even be a crowded area or a school zone.
To prevent all these complications driver drowsiness detection system is being developed which can potentially save a lot of lives from accidents.
มุมมอง: 23 038
code da
Hello sir but we are not getting the output the camera is only running for 2 seconds
Can I use ESP32 OR any other solution instead of Raspberry Pi? Please answer
plz share the code
Source code???
He'llo sir can i get source code pls respond 🙏🙏🙏🙏🙏🙏
please share the code please
Hello, Kindly I need this project codes the datasets.
hi how can i contact with u ?i need your help bcoz now im doing my final year project
please Can you speak arabic ? I am a master's student and I have this same project and I need help, please?
Sir can you please share the source code it's really importantv
Can you share ur code please!!
hi, do you this project documentation
import cv2 import os from keras.models import load_model import numpy as np from pygame import mixer import time mixer.init() sound = mixer.Sound('C:/Users/tvsri/OneDrive/Desktop/New folder (2)/alarm.wav') face = cv2.CascadeClassifier('C:/Users/tvsri/OneDrive/Desktop/New folder (2)/haar cascade files/haarcascade_frontalface_alt.xml') leye = cv2.CascadeClassifier('C:/Users/tvsri/OneDrive/Desktop/New folder (2)/haar cascade files/haarcascade_frontalface_alt.xml') reye = cv2.CascadeClassifier('C:/Users/tvsri/OneDrive/Desktop/New folder (2)/haar cascade files/haarcascade_frontalface_alt.xml') lbl = ['Close', 'Open'] model = load_model('C:/Users/tvsri/OneDrive/Desktop/New folder (2)/Drowsiness.h5') path = os.getcwd() cap = cv2.VideoCapture(0) font = cv2.FONT_HERSHEY_COMPLEX_SMALL count = 0 score = 0 thicc = 2 rpred = [99] lpred = [99] while True: ret, frame = cap.read() height, width = frame.shape[:2] gray = cv2.cvtColor(frame, cv2.COLOR_BGR2GRAY) faces = face.detectMultiScale(gray, minNeighbors=5, scaleFactor=1.1, minSize=(25, 25)) left_eye = leye.detectMultiScale(gray) right_eye = reye.detectMultiScale(gray) cv2.rectangle(frame, (0, height - 50), (200, height), (0, 0, 0), thickness=cv2.FILLED) for (x, y, w, h) in faces: cv2.rectangle(frame, (x, y), (x + w, y + h), (100, 100, 100), 1) for (x, y, w, h) in right_eye: r_eye = frame[y:y + h, x:x + w] count = count - 1 r_eye = cv2.cvtColor(r_eye, cv2.COLOR_BGR2GRAY) r_eye = cv2.resize(r_eye, (24, 24)) r_eye = r_eye / 255 r_eye = r_eye.reshape(24, 24, -1) r_eye = np.expand_dims(r_eye, axis=0) rpred = np.argmax(model.predict(r_eye),axis= -1) #rpred = np.model.predict_classes(r_eye) if rpred[0] == 1: lbl = 'Open' if rpred[0] == 0: lbl = 'Closed' break for (x, y, w, h) in left_eye: l_eye = frame[y:y + h, x:x + w] count = count - 1 l_eye = cv2.cvtColor(l_eye, cv2.COLOR_BGR2GRAY) l_eye = cv2.resize(l_eye, (24, 24)) l_eye = l_eye / 255 l_eye = l_eye.reshape(24, 24, -1) l_eye = np.expand_dims(l_eye, axis=0) lpred = np.argmax(model.predict(l_eye),axis= +1) #lpred = model.predict_classes(l_eye) if lpred[0] == 1: lbl = 'Open' if lpred[0] == 0: lbl = 'Closed' break if rpred[0] == 0 and lpred[0] == 0: score = score + 1 cv2.putText(frame, "Closed", (10, height - 20), font, 1, (255, 255, 255), 1, cv2.LINE_AA) # if(rpred[0]==1 or lpred[0]==1): else: score = score - 1 cv2.putText(frame, "Open", (10, height - 20), font, 1, (255, 255, 255), 1, cv2.LINE_AA) if score < 0: score = 0 cv2.putText(frame, 'Score:' + str(score), (100, height - 20), font, 1, (255, 255, 255), 1, cv2.LINE_AA) if score > 15: # person is feeling sleepy so we beep the alarm cv2.imwrite(os.path.join(path, 'image.jpg'), frame) try: sound.play() except: # isplaying = False pass if thicc < 16: thicc = thicc + 2 else: thicc = thicc - 2 if thicc < 2: thicc = 2 cv2.rectangle(frame, (0, 0), (width, height), (0, 0, 255), thicc) cv2.imshow('frame', frame) if cv2.waitKey(1) & 0xFF == ord('q'): break cap.release() cv2.destroyAllWindows()
give ppt link bro
Hello sir What's ur role in this project how to ans for this question plz ans me sir
Sir Please share the ppt
document and source code share kr dete aap to hamare liye achha hota pleas share your git profile
Can you share documentation of this project
did u have source code ?
Share this code
Source file please share
if anyone found publishing paper of this project
Hey ! I tried this but getting a small error can u help me to solve this
what is the error that u r getting
can u give me the source code
plz share the code !!
Send the dataset please
Hello sir I need documents and source code of this project.
Did you get
Hi @Muni Chandra Ch Can we connect ? Want to buy this project.
bro ineed code for this project
which college r u from ??
Bro ppt ka link share karo na..
I want code for this project for my final year project plz help
Bhai ppt ka link dedo
Can we use Nvidia rather then raspberry pie
Can I use ESP32 OR any other solution instead of Raspberry Pi ? Please answer
Need the project code plzzz
can you plz share code?
If you have the source code kindly share here
Please add your code
Hi can we speak over phone.
I want project files and PPT Can you provide me PLZZ 🥺🥺🥺
My programm not running plz help me !!!
it working now?
Have you code of this project ????
@@91mmona showing error no modul named cv2 and and no module named keras
@@shiviyadav6657same error
which raspberry pi version u used and how connections are made for raspberry pi to camera and buzzer??
Could you pls share the code for the same??
Got solution for this?
@@Sriram-kk7zr send here kindly
@@Sriram-kk7zr please send code for this project
@@danishyaqub1749 not completed fully.
@@knithisha3230 not completed fully.