pip加速+百度镜像|清华镜像
针对pip install 安装包下载慢的问题,主要pip install直接安装是从国外拉取安装包。
解决办法,加国内镜像,比如百度 https://mirror.baidu.com/pypi/simple
pip install lac -i https://mirror.baidu.com/pypi/simple
比如清华镜像:https://pypi.tuna.tsinghua.edu.cn/simple
pip install numpy -i https://pypi.tuna.tsinghua.edu.cn/simple
如何加快pip下载的速度
pip 之所以慢,是因为它默认使用的国外的统一的下载源,所以要想加快pip的下载速度,可行的办法就是切换下载源为国内,国内一些大公司也提供了对应的竞相网站。
国内镜像网站
阿里云 http://mirrors.aliyun.com/pypi/simple/
中国科技大学 https://pypi.mirrors.ustc.edu.cn/simple/
豆瓣(douban) http://pypi.douban.com/simple/
清华大学 https://pypi.tuna.tsinghua.edu.cn/simple/
中国科学技术大学 http://pypi.mirrors.ustc.edu.cn/simple/
使用方法
pip install [包名] -i [ftp站名地址] --trusted-host [ftp站点名]
- 1
以安装numpy为例,如果使用 阿里的源可以这样输入命令
pip install numpy -i http://mirrors.aliyun.com/pypi/simple/ --trusted-host mirrors.aliyun.com
- 1
如果使用 豆瓣的源可以这样输入命令
pip install numpy -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
- 1
其他类似…
如果想一劳永逸或许可以这样
alias pyinstall='pip install -i http://mirrors.aliyun.com/pypi/simple/ --trusted-host mirrors.aliyun.com '
- 1
将这个alias 放到 /etc/bash.bashrc 或者~/.bashrc中 以后调用pyinstall 时就可以不再加后面的参数,而且也省了 install 这个单词。
pip加速+百度镜像|清华镜像相关推荐
- pip设置默认为清华镜像
在cmd中运行如下指令,即可设置默认为清华镜像 pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple 仅一次 ...
- pip的使用和清华镜像源的设置
使用pip安装第三方库的时候卡的要死.所以我就想pip能不能安装本地的包. 原来pip能干这么多事情!幸福感暴涨! 安装 在安装anaconda的使用就自动下载了pip 列出已安装的包 pip lis ...
- 【Python】pip和Anaconda添加清华镜像源
一.pip添加清华镜像源 pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple 二.Anaconda添加清华 ...
- pip install 使用国内清华镜像
今天在装gensim时发现直接用pip命令会非常慢,原因是连接到国外的URL下载非常慢,于是考虑使用国内的镜像. pip install gensim 第一次使用镜像时报错 pip3 install ...
- android 清华镜像,清华镜像网站下载android源码并编译
8种机械键盘轴体对比 本人程序员,要买一个写代码的键盘,请问红轴和茶轴怎么选? 下载android源码方法: 我的系统是ubuntu 18.04,主要参考了blog通过清华大学镜像下载Android源 ...
- python 清华镜像_Python pip conda 设置为清华镜像
pip设置为默认镜像 pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple conda 设置为默认镜像 运行 ...
- 关于python没法pip install ocr,清华镜像也找不到ocr库
一般的库直接pip install或者conda install就可以从官网或者镜像网址安装: 而OCR识别库不是python本身就有的,需要先安装tesseract软件再在终端执行install命令 ...
- pip速度慢,更换清华镜像源试试?
控制台运行 pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple 成功后
- Ubuntu 20 安装包下载(清华镜像)
Ubuntu 20 安装包下载 在国内推荐使用清华大学镜像 清华镜像地址:https://mirrors.tuna.tsinghua.edu.cn/ 在搜索框中输入Ubuntu,然后点击Ubuntu ...
最新文章
- Hibernate学习(4)- Hibernate对象的生命周期
- RabbitMQ负载均衡(3)——Keepalived+HAProxy实现高可用的负载均衡
- N小时改变一次url时间戳的方法
- jcenter和maven下载失败Can't connect to SOCKS proxy:Connection refused: connect
- android让文件按顺序列表,Java/Android 获取文件夹的文件列表(file.listFiles())并按名称排序,中文优先...
- LeetCode 957. N 天后的牢房(查找循环节)
- java对xml解析_Java中对xml的解析
- 安卓蓝牙键盘切换输入法_采用国产机械轴,三种连接模式轻松切换,TT G521上手体验...
- linux创建sftp服务器,Linux Centos 6.6搭建SFTP服务器
- mysql 跳过一个事物_MySQL基于GTID的数据恢复
- 心情舒畅,升级到u10.04了
- 【2016北京集训测试赛(八)】 直径 (虚树+树的直径)
- 区块链 FISCO BCOS智能合约存储存放位置
- 1-10所有5个数的组合_121期大乐透:关注10+5、重点号6个
- 用nmap查看局域网存活的主机
- 自定义形状的ImageView制作
- sap服务器之间文件复制,sap跨服务器客户端复制
- vue项目无法启动,谷歌浏览器报:您与此网站之间建立的连接不安全,实际是cdn服务器过期
- 公众号运营情况分析 DAY02(获取公众号文章阅读量、在看和评论内容)
- ClickHouse中文官方文档