目录
1. 只安装了 python 2 或只安装了 python3
PS. pip的常用源地址
1. 只安装了 python 2 或只安装了 python3
如果系统中只安装了Python2,那么就只能使用pip。
如果系统中只安装了Python3,那么既可以使用pip也可以使用pip3,二者是等价的。
2. 同时安装了Python2和Python3
pip默认给Python2用,pip3指定给Python3用。
PS. pip的常用源地址
https://pypi.tuna.tsinghua.edu.cn/simple/ # 清华大学
https://mirrors.aliyun.com/pypi/simple/ # 阿里云
https://pypi.douban.com/simple/ # 豆瓣
https://pypi.mirrors.ustc.edu.cn/simple/ # 中国科学技术大学
https://pypi.hustunique.com/ # 华中科技大学
——使用举例:
pip3 install opencv_python -i https://pypi.mirrors.ustc.edu.cn/simple/