可能遇到的问题
- pip install xxx Could not fetch URL https://pypi.org/simple/pip/
- 下载经常中断
conda换清华源
进入cmd,查看当前的源
conda config --show
而后进入,C:\Users***.condarc,修改文件内容
channels:
- defaults
show_channel_urls: true
channel_alias: https://mirrors.tuna.tsinghua.edu.cn/anaconda
default_channels:
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/r
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/pro
- https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/msys2
custom_channels:
conda-forge: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
msys2: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
bioconda: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
menpo: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
pytorch: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
simpleitk: https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud
pip 更换清华源
进入C:\Users***,新建pip文件夹,新建文件pip.ini,输入如下内容:
[global]
index-url = https://pypi.tuna.tsinghua.edu.cn/simple
如果有问题,可以更换为阿里云试试
参考资料
- Anaconda 镜像使用帮助 https://mirror.tuna.tsinghua.edu.cn/help/anaconda/
- pip conda 换清华源 https://blog.csdn.net/lily1234567/article/details/91040603
网友评论