Skip to content

Why this happened?: SystemError: <class 'cv2.CascadeClassifier'> returned a result with an error set #32

Open
@Thomas-stc

Description

@Thomas-stc

Dear sir.
When I practice face detection by using the code as follows and an error happened as mentioned in Title.
gray = cv2.cvtColor(img, cv2.COLOR_BGR2GRAY)
face_cascade = cv2.CascadeClassifier('opencv-files/lbpcascade_frontalface.xml')
faces = face_cascade.detectMultiScale(gray, scaleFactor=1.0, minNeighbors=5)
I am sure that the the file "lbpcascade_frontalface.xml" has in the folder "opencv-files" which I created.
by the way, I got "lbpcascade_frontalface.xml" from my colleague because I don't know where to download this file on web.
I am looking forward for your answer, thank you very much.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions