解决opencv错误AttributeError: module 'cv2.cv2' has no attribute 'xfeatures2d'

解决opencv错误AttributeError: module 'cv2.cv2' has no attribute 'xfeatures2d'

文章目录:

  • 一、错误原因
  • 二、解决方法

一、错误原因

这个错误是由于opencv-contrib-python版本太新导致出现的问题,应该降低版本

二、解决方法

  1. 卸载opencv-contrib-python
pip uninstall opencv-contrib-python
  1. 安装指定的opencv-contrib-python版本
pip install opencv-contrib-python==3.3.0.10

Reference:
https://github.com/csm-kr/dog_classifier_for_identification/issues/1

在这里插入图片描述



在这里插入图片描述
♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠ ⊕ ♠

你可能感兴趣的:(16_各种错误和bug(你的痛,我的痛,痛痛痛))