Updated if person

This commit is contained in:
HeshamTB 2018-11-30 10:37:53 +00:00
parent 30c8e4b074
commit a8990873ba

View File

@ -65,9 +65,11 @@ def start( camera, face_cascade):
roi_gray = gray[y:y+h, x:x+w]
roi_color = img[y:y+h, x:x+w]
person = recognize(roi_gray)
if person == 'Hesham' or person == 'Saeed':#Change to if 'unknown' elif openShifter
if person == 'unknown':
print('Found unknown person')
else:
print('Found '+person)
OpenShifter()
print('Sending to Arduino!')
cv2.rectangle(img,(x,y),(x+w,y+h),(255,0,0),2)
cv2.putText(img, person, (x, y), cv2.FONT_HERSHEY_PLAIN, 1.7, (255, 0, 0), 2)