opencv中的python导入错误

时间:2018-02-08 11:12:11

标签: python numpy opencv cv2

尝试导入opencv时出现此错误:

>>> import cv2
RuntimeError: module compiled against API version 0xa but this version of numpy is 0x7
Traceback (most recent call last):
  File "<pyshell#2>", line 1, in <module>
    import cv2
ImportError: numpy.core.multiarray failed to import

1 个答案:

答案 0 :(得分:1)

你在运行什么版本的Numpy?您似乎只运行1.7

升级到最新版本(写作时为1.14)并重试。