本文介绍了python3 openCV安装错误:找不到符号:_clock_gettime的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
在python3中导入opencv时,有人可以帮助我修复错误吗?
Can anyone help me fixing an error when importing opencv in python3?
当我在python3中导入cv2时,我得到类似的东西
when I import cv2 in python3, I get something like
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-
packages/cv2/__init__.py", line 4, in <module>
from .cv2 import *
ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/cv2/cv2.cpython-36m-darwin.so, 2):
Symbol not found: _clock_gettime
Referenced from: /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/cv2/.dylibs/libavutil.55.78.100.dylib
(which was built for Mac OS X 10.12)
Expected in: /usr/lib/libSystem.B.dylib
in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/cv2/.dylibs/libavutil.55.78.100.dylib
另外,我正在使用python 3.6.3版本
Also, I'm using python version 3.6.3
推荐答案
如果您不想升级操作系统,则可以安装早期版本的opencv:
If you don't want to upgrade your OS, you can install an earlier version of opencv:
pip install opencv-python==3.3.0.10
这篇关于python3 openCV安装错误:找不到符号:_clock_gettime的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!