某些包下载过程中会很慢,会出现timeout的情况,解决办法:
可以配置下清华大学开源镜像,加速下载和安装。

二、使用样例

临时使用
pip install -i https://pypi.tuna.tsinghua.edu.cn/simple some-package
注意,simple 不能少, 是 https 而不是 http

永久使用
升级 pip 到最新的版本 (>=10.0.0) 后进行配置:

pip install pip -U
pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
如果您到 pip 默认源的网络连接较差,临时使用本镜像站来升级 pip:

pip install -i https://pypi.tuna.tsinghua.edu.cn/simple pip -U

三、国内知名开源镜像站

阿里云开源镜像站[https://developer.aliyun.com/mirror/]

网易开源镜像站[http://mirrors.163.com/]

清华开源镜像站[https://mirrors.tuna.tsinghua.edu.cn/]

等等

相关文章:

  • 2021-09-26
  • 2021-12-29
  • 2021-11-20
  • 2022-12-23
  • 2022-12-23
  • 2021-11-12
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-06-15
  • 2022-12-23
  • 2022-12-23
  • 2021-10-01
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案