import cv2时出错,没安装cv2,No module named 'cv2', 需要pip 安装,pip install cv2 error
网上搜了下说
pip install opencv-python
然后又错哦
raise ReadTimeoutError(self._pool, None, 'Read timed out.')
搜了下说是源的问题,速度不行要用国内源
pip install -i https://pypi.tuna.tsinghua.edu.cn/simple opencv-python
又出错了,no skbuild
然后就
pip install scikit-build
pip install -i https://pypi.tuna.tsinghua.edu.cn/simple opencv-python
终于安装成功了
建议先更新下pip
pip install --upgrade pip