1、下载安装文件,清华源下载地址:
https://pypi.tuna.tsinghua.edu.cn/simple/opencv-python/
2、cmd进入whl文件所在文件夹,安装open cv
pip install opencv_python-4.2.0.34-cp37-cp37m-win_amd64.whl
出现"pip is configured with locations that require TLS/SSL, however the ssl…"错误
在PATH中添加Anaconda3、Anaconda3\Scripts和Anaconda\Library\bin
出现"Requirement already satisfied: …"错误
Requirement already satisfied: opencv-python==4.2.0.34 from file:///E:/World/python/opencv_python-4.2.0.34-cp37-cp37m-win_amd64.whl in e:\world\python\anaconda\lib\site-packages (4.2.0.34)
Requirement already satisfied: numpy>=1.14.5 in e:\world\python\anaconda\lib\site-packages (from opencv-python= =4.2.0.34) (1.16.4)
解决方法:
在–target=后加路径,安装成功!!
pip install --target=E:\World\python\Anaconda\Lib\site-packages opencv_python-4.2.0.34-cp37-cp37m-win_amd64.whl