You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The tutorial for Face Detection with Haar Cascades is a really helpful resource. Unfortunately on some installations of opencv the xml file for the trained haar model is not properly linked. A call of cv2.data.haarcascades should resolve this issue for people.
I would like to propose the following change: face_cascade = cv2.CascadeClassifier('haarcascade_frontalface_default.xml')
to: face_cascade = cv2.CascadeClassifier(cv2.data.haarcascades + 'haarcascade_frontalface_default.xml')
I would be happy to submit a pull request to switch this if there are no issues here.
The text was updated successfully, but these errors were encountered:
The tutorial for Face Detection with Haar Cascades is a really helpful resource. Unfortunately on some installations of opencv the xml file for the trained haar model is not properly linked. A call of
cv2.data.haarcascades
should resolve this issue for people.I would like to propose the following change:
face_cascade = cv2.CascadeClassifier('haarcascade_frontalface_default.xml')
to:
face_cascade = cv2.CascadeClassifier(cv2.data.haarcascades + 'haarcascade_frontalface_default.xml')
I would be happy to submit a pull request to switch this if there are no issues here.
The text was updated successfully, but these errors were encountered: