杨东明 发表于 2021-10-15 16:00:36

求助opencv安装问题

C:\Users\杨东明>python
Python 3.7.8 (tags/v3.7.8:4b47a5b6ba, Jun 28 2020, 08:53:46) on win32
Type "help", "copyright", "credits" or "license" for more information.

opencv_python-4.5.3.56-cp37-cp37m-win_amd64.whl这是我下的版本

我直接在anacodna prompt上输入pip install D:\anaconda3\Scripts\opencv_python-4.5.3.56-cp37-cp37m-win_amd64.whl报错:
ERROR: opencv_python-4.5.3.56-cp37-cp37m-win_amd64.whl is not a supported wheel on this platform.

网上面说的查看自己python支持的版本方法:
import pip._internal
>>> print(pip._internal.pep425tags.get_supported())

import pip
>>> print(pip.pep425tags.get_supported())

都没用,全报错AttributeError: module 'pip' has no attribute 'pep425tags'或者AttributeError: module 'pip._internal' has no attribute 'pep425tags'

我又试了pip3 install opencv-python报错SyntaxError: invalid syntax

求助 怎么查看python支持的版本以及怎么安装成功

hrpzcf 发表于 2021-10-15 16:29:40

电脑不能联网吗?可以联网的话:
pip install opencv-python -i https://pypi.tuna.tsinghua.edu.cn/simple

叶夜还 发表于 2022-1-4 08:57:25

pip install -i https://pypi.tuna.tsinghua.edu.cn/simple opencv-python==3.7在后面限制一下版本号试一试或者直接在pycharm设置——项目——python解释器里边安装包,pycharm不用管那么多,点一下就按好了
页: [1]
查看完整版本: 求助opencv安装问题