当前位置:   article > 正文

解决错误: module 'cv2.cv2' has no attribute 'face'_module 'cv2' has no attribute 'face

module 'cv2' has no attribute 'face
 model = cv2.face.EigenFaceRecognizer_create()

在做人脸识别的时候报错

module 'cv2.cv2' has no attribute 'face'

试了好几个,木有解决

看版本号也是对应的。。

最终,全部卸载,再安装一次就可以了,这是什么毛病。。。。

pip uninstall opencv-contrib-python

pip uninstall opencv-python

pip install opencv-python

pip install opencv-contrib-python

 

再次运行,可以了。。。

 

本文内容由网友自发贡献,转载请注明出处:https://www.wpsshop.cn/w/知新_RL/article/detail/81190
推荐阅读
相关标签
  

闽ICP备14008679号