ImportError: ERROR: recursion is detected during loading of “cv2“ binary extensions. Check OpenCV in

1. import cv2错误

ImportError: ERROR: recursion is detected during loading of “cv2” binary extensions. Check OpenCV installation.

2. 解决

cv2版本太高,需要降低cv2版本

2.1 在anaconda环境下使用conda list查看当前cv2的版本为4.6.0.66,如下图:
ImportError: ERROR: recursion is detected during loading of “cv2“ binary extensions. Check OpenCV in_第1张图片
2.2 使用pip uninstall opencv-python==4.6.0.66(指定卸载的当前cv2版本号)

2.3 安装低版本的cv2:

pip install opencv-python=4.5.3.56(指定低版本的cv2版本号)

2.4 检查是否安装成功: conda list

cv2

你可能感兴趣的:(Python,opencv,python,深度学习)