1、python下载
下载地址:https://www.python.org #为确保稳定性,通常下载最新版本的前一个版本
2、环境变量配置
点击环境变量中的path
点击新建添加python路径
在CMD中输入python验证
3、配置国内镜像源
配置镜像源,在CMD中输入:
pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple # 镜像源地址
例如:pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
国内常用镜像源地址如下:
清华:https://pypi.tuna.tsinghua.edu.cn/simple
华为:https://repo.huaweicloud.com/repository/pypi/simple
阿里云:http://mirrors.aliyun.com/pypi/simple/
中科大:https://pypi.mirrors.ustc.edu.cn/simple/
查看验证当前镜像源,在CMD中输入:
pip config list