解决opencv-python 安装报错 Could not build wheels for opencv-python

  • 使用python3.6时会报错
    • `ERROR: Could not build wheels for opencv-python, which is required to install pyproject.toml-based projects`
    • pip更新

使用python3.6时会报错

ERROR: Could not build wheels for opencv-python, which is required to install pyproject.toml-based projects

pip更新

pip install --upgrade pip

但是发现更新完了之后还是没用,因为主要原因是如果直接安装opencv默认安装最新版,此时找一个python3.6支持的版本就行了,如4.3.0.38,使用如下命令即可成功安装

pip install -i https://pypi.douban.com/simple/ pip install opencv-python==4.3.0.38