Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

TypeError: Incorrect type of self(must be 'face_faceRecognizer' or its derivative

image description

Hi, I am trying to execute face recognition code(opencv 3.4 and python2.7), i get the following error : TypeError: Incorrect type of self(must be 'face_faceRecognizer' or its derivative.

the code and defect attached

recognizer = cv2.face_LBPHFaceRecognizer()

if os.path.exists("model.yaml"): recognizer.read("model.yaml")

Can you please help me fix this.

click to hide/show revision 2
None

updated 2018-02-21 04:59:01 -0600

berak gravatar image

TypeError: Incorrect type of self(must be 'face_faceRecognizer' or its derivative

image description

Hi, I am trying to execute face recognition code(opencv 3.4 and python2.7), i get the following error : TypeError: Incorrect type of self(must be 'face_faceRecognizer' or its derivative.

the code and defect attached

recognizer = cv2.face_LBPHFaceRecognizer()

if os.path.exists("model.yaml"): recognizer.read("model.yaml")

Can you please help me fix this.

click to hide/show revision 3
retagged

updated 2018-02-21 05:36:12 -0600

berak gravatar image

TypeError: Incorrect type of self(must be 'face_faceRecognizer' or its derivative

Hi, I am trying to execute face recognition code(opencv 3.4 and python2.7), i get the following error : TypeError: Incorrect type of self(must be 'face_faceRecognizer' or its derivative.

the code and defect attached

recognizer = cv2.face_LBPHFaceRecognizer()

if os.path.exists("model.yaml"): recognizer.read("model.yaml")

Can you please help me fix this.