📦pip 国内常用镜像源地址
📦 国内常用镜像源地址
以下是国内常用的 PyPI 镜像源地址,大家可以根据自身需要选择合适的镜像源。个人推荐清华大学的镜像源哦!😊
镜像源名称 | 镜像地址 |
---|---|
🏫 清华大学源 | https://pypi.tuna.tsinghua.edu.cn/simple |
☁️ 阿里云源 | https://mirrors.aliyun.com/pypi/simple |
🎬 豆瓣源 | https://pypi.douban.com/simple |
🎓 中国科学技术大学源 | https://pypi.mirrors.ustc.edu.cn/simple |
🐧 腾讯云源 | https://mirrors.cloud.tencent.com/pypi/simple |
🔄 换源方法
1. 临时换源 🕒
在下载某个包时,临时将镜像源换成清华源:
pip install package_name -i https://pypi.tuna.tsinghua.edu.cn/simple
注意:package_name
为你要安装的包名。
2. 永久换源 ⚙️
通过修改配置文件来永久使用某个镜像源:
pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
3. 重置镜像源 🔙
查看当前设置的镜像源:
pip config list
删除全局设置的镜像源:
pip config unset global.index-url
删除用户级别设置的镜像源:
pip config unset global.index-url
希望这些信息对你有帮助!🚀 如果有其他问题,随时问我哦!😄