python下载慢怎么解决,python下载的特别慢
pip install numpy==1.11.0安装指定版本为1.11.0的numpy包。中国科学技术大学:http://pypi.mirrors.ustc.edu.cn/simple/中国科技大学:https://pypi.mirrors.ustc.edu.cn/simple/清华大学:https://pypi.tuna.tsinghua.edu.cn/simple/阿里云:http://mi
大家好,本文将围绕python下载慢怎么解决展开说明,python下载的特别慢是一个很多人都想弄明白的事情,想搞清楚下载python网速很慢需要先了解以下几个事情。

python默认使用的是国外镜像,有时候下载非常慢,最快的办法就是在下载命令中增加国内源:
常用的国内源如下:
清华大学:https://pypi.tuna.tsinghua.edu.cn/simple/
阿里云:http://mirrors.aliyun.com/pypi/simple/
中国科技大学:https://pypi.mirrors.ustc.edu.cn/simple/
豆瓣(douban) :http://pypi.douban.com/simple/
中国科学技术大学:http://pypi.mirrors.ustc.edu.cn/simple/
临时使用pip+国内源
示例:
pip install requests -i https://pypi.tuna.tsinghua.edu.cn/simple
永久使用pip+国内源
示例:
# 永久设置阿里云的国内源
pip config set global.trusted-host mirrors.aliyun.com
pip config set global.index-url https://mirrors.aliyun.com/simple# 永久设置清华大学的国内源
pip config set global.trusted-host pypi.tuna.tsinghua.edu.cn
pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple/
其他常用的pip命令
pip list 查看已安装包列表
pip install numpy 直接安装包
pip install numpy==1.11.0 安装指定版本为1.11.0的numpy包
pip install --upgrade numpy 升级包
pip uninstall numpy 卸载包
Pycharm中修改库下载源
在setting中按如下路径打开包下载

点击“+”

在Available Packages 对话框中,点击Manage Respositories
点击"+" 添加国内源路径即可

魔乐社区(Modelers.cn) 是一个中立、公益的人工智能社区,提供人工智能工具、模型、数据的托管、展示与应用协同服务,为人工智能开发及爱好者搭建开放的学习交流平台。社区通过理事会方式运作,由全产业链共同建设、共同运营、共同享有,推动国产AI生态繁荣发展。
更多推荐


所有评论(0)