[英]How to get cv2 running on python3.6?
I'm currently trying to get the cv2 library on python so I could play some videos using python. 我目前正在尝试在python上获取cv2库,以便可以使用python播放一些视频。 Whenever I try to install cv2 from pycharm I get this error: 每当我尝试从pycharm安装cv2时,都会出现此错误:
Collecting cv2
Could not find a version that satisfies the requirement cv2 (from versions: )
No matching distribution found for cv2
I looked around and read that I should install opencv-python
using pip, and I did, but pycharm still does not recognise cv2. 我环顾四周,读到我应该使用pip安装opencv-python
,我做到了,但是pycharm仍然无法识别cv2。
It works for me here. 在这里对我有用。 I just downloaded PyCharm 2018.1, created a new project using Python 3.6 and virtualenv, then navigated to the project settings and installed opencv-python
using the PyCharm package manager 我刚刚下载了PyCharm 2018.1,使用Python 3.6和virtualenv创建了一个新项目,然后导航到项目设置并使用PyCharm软件包管理器安装了opencv-python
I then had to restart the python console in PyCharm and I could successfully import cv2
. 然后,我不得不在PyCharm中重新启动python控制台,然后可以成功import cv2
。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.