python3 openCV install error: Symbol not found: _clock_gettime

前端 未结 2 1940
长情又很酷
长情又很酷 2021-01-04 09:12

Can anyone help me fixing an error when importing opencv in python3?

when I import cv2 in python3, I get something like

Traceback (most recent call l         


        
相关标签:
2条回答
  • 2021-01-04 09:34

    clock_gettime() was added in macOS 10.12. It says so in the error message.

    From what I understand it may be possible to build against an earlier Xcode SDK, but the easiest is probably to upgrade to Mac's latest OS.

    0 讨论(0)
  • 2021-01-04 09:51

    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

    0 讨论(0)
提交回复
热议问题