Python2.7 opencv-python,tensorflowのインストール

811 ワード

一、Python 2.7 opencv-pythonのインストール
ヒントエラー:ERROR:Command errored out with exit status 1:/usr/bin/python/home/ljl/.local/lib/python2.7/site-packages/pip/_vendor/pep517/_in_process.py get_requires_for_build_wheel/tmp/tmpOJny2O Check the logs for full command output.
1、直接使用すると、コマンドを押すと上記のエラーが表示されます.
 pip install -i https://pypi.tuna.tsinghua.edu.cn/simple opencv-python

この方法でopencv-pythonの最新バージョンが自動的にダウンロードされるためですが、python 2はサポートされていません.2、解決方法:python 2がサポートするopencv-pythonのバージョンを指定します.以下のようにします.
pip install -i https://pypi.tuna.tsinghua.edu.cn/simple opencv-python==4.2.0.32

二、Python 2.7 tensorflowのインストール
python2.7 tensorflowの1.4.1バージョンをサポート
pip install -i https://pypi.tuna.tsinghua.edu.cn/simple tensorflow==1.4.1