anaconda4.4.0 python3.6 安装opencv3.3.0.10

来源:互联网 发布:java 实时语音聊天 编辑:程序博客网 时间:2024/06/16 19:40

将opencv安装在anaconda里面

网站:http://blog.csdn.net/lwplwf/article/details/61616493
网站:http://www.lfd.uci.edu/~gohlke/pythonlibs/

我尝试了里面的方法,还是import cv2会有错误

>>> import cv2RuntimeError: module compiled against API version 0xb but this version of numpy is 0xaTraceback (most recent call last):  File "<stdin>", line 1, in <module>ImportError: numpy.core.multiarray failed to import

网上的教程都是用opencv_python‑3.2.0‑cp36‑cp36m‑win_amd64.whl这个版本,但是pythonlib里面给出的资源已经更新到了3.3.0了,可能是这个问题。然后我google了一下python怎么安装opencv。国外有一个网站里面说了先卸载之前的安装失败的包
pip uninstall opencv-contrib-python或者pip uninstall opencv-python(看你之前安装的是什么版本)。
然后pip install opencv-python就行了,成功import cv2。

原创粉丝点击