使用清华镜像源来加速conda的下载和安装,可以按照以下步骤操作:

  1. 打开终端或命令行窗口(Windows用户需要以管理员身份运行),输入以下命令,添加清华镜像源:
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main/
conda config --set show_channel_urls yes
  1. 安装或更新包时,添加-c参数指定使用清华镜像源,例如:
conda install -c https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/ tensorflow
  1. 如果需要使用清华镜像源作为默认源,可以将其设置为第一优先级:
conda config --set default_channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main/ https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/

这样,每次安装或更新包时,conda会自动从清华镜像源下载

conda如何使用清华源

原文地址: https://www.cveoy.top/t/topic/djNy 著作权归作者所有。请勿转载和采集!

免费AI点我,无需注册和登录