gpt4 book ai didi

python3 openCV安装报错: Symbol not found: _clock_gettime

转载 作者:太空狗 更新时间:2023-10-29 21:41:34 24 4
gpt4 key购买 nike

谁能帮我解决在 python3 中导入 opencv 时出现的错误?

当我在 python3 中导入 cv2 时,我得到类似的东西

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

最佳答案

如果不想升级操作系统,可以安装较早版本的opencv:

pip install opencv-python==3.3.0.10

关于python3 openCV安装报错: Symbol not found: _clock_gettime,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/48717726/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com