日韩av黄I国产麻豆传媒I国产91av视频在线观看I日韩一区二区三区在线看I美女国产在线I麻豆视频国产在线观看I成人黄色短片

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 >

解决pip安装时速度慢的问题 镜像源(pip install -i [镜像源地址] [包名])

發布時間:2025/3/20 76 豆豆
生活随笔 收集整理的這篇文章主要介紹了 解决pip安装时速度慢的问题 镜像源(pip install -i [镜像源地址] [包名]) 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

更改pip源即可,修改為pip國內源:

新版ubuntu要求使用https源,要注意。

清華:https://pypi.tuna.tsinghua.edu.cn/simple 阿里云:http://mirrors.aliyun.com/pypi/simple/ 中國科技大學 https://pypi.mirrors.ustc.edu.cn/simple/ 華中理工大學:http://pypi.hustunique.com/ 山東理工大學:http://pypi.sdutlinux.org/ 豆瓣:http://pypi.douban.com/simple/

臨時使用:

可以在使用pip的時候加參數-i https://pypi.tuna.tsinghua.edu.cn/simple

例如:pip install -i https://pypi.tuna.tsinghua.edu.cn/simple gevent,這樣就會從清華這邊的鏡像去安裝gevent庫。

比如,我使用清華鏡像源安裝sklearn,賊快,賊猛!!!!

pip install -i https://pypi.tuna.tsinghua.edu.cn/simple sklearn C:\Users\HuaWei>pip install -i https://pypi.tuna.tsinghua.edu.cn/simple sklearn Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple Collecting sklearnDownloading https://pypi.tuna.tsinghua.edu.cn/packages/1e/7a/dbb3be0ce9bd5c8b7e3d87328e79063f8b263b2b1bfa4774cb1147bfcd3f/sklearn-0.0.tar.gz Collecting scikit-learnDownloading https://pypi.tuna.tsinghua.edu.cn/packages/21/d9/7da9d5afdf901ab069226853c84a432c5db80fd616849ebcee29fd8a04e0/scikit_learn-0.22.1-cp36-cp36m-win_amd64.whl (6.3MB)|████████████████████████████████| 6.3MB 6.8MB/s Collecting joblib>=0.11Downloading https://pypi.tuna.tsinghua.edu.cn/packages/28/5c/cf6a2b65a321c4a209efcdf64c2689efae2cb62661f8f6f4bb28547cf1bf/joblib-0.14.1-py2.py3-none-any.whl (294kB)|████████████████████████████████| 296kB 6.8MB/s Requirement already satisfied: scipy>=0.17.0 in d:\yolov3_tensorflow\python\lib\site-packages (from scikit-learn->sklearn) (1.1.0) Requirement already satisfied: numpy>=1.11.0 in d:\yolov3_tensorflow\python\lib\site-packages (from scikit-learn->sklearn) (1.15.1) Building wheels for collected packages: sklearnBuilding wheel for sklearn (setup.py) ... doneCreated wheel for sklearn: filename=sklearn-0.0-py2.py3-none-any.whl size=1321 sha256=97f825459ab15505b1fd6cab5ff19adf5acc286a367aa80f93cdfed5f4274e42Stored in directory: C:\Users\HuaWei\AppData\Local\pip\Cache\wheels\6f\cd\11\f6acd1062135d70bc0a7066808561580d256b3149055cb33ad Successfully built sklearn Installing collected packages: joblib, scikit-learn, sklearn Successfully installed joblib-0.14.1 scikit-learn-0.22.1 sklearn-0.0 WARNING: You are using pip version 19.3.1; however, version 20.0.2 is available. You should consider upgrading via the 'python -m pip install --upgrade pip' command.C:\Users\HuaWei>

參考文章:解決pip install慢的方法

總結

以上是生活随笔為你收集整理的解决pip安装时速度慢的问题 镜像源(pip install -i [镜像源地址] [包名])的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。