下载地址
https://docs.conda.io/projects/miniconda/en/latest/index.html
安装conda
bash
mkdir -p ~/miniconda3
wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh -O ~/miniconda3/miniconda.sh
bash ~/miniconda3/miniconda.sh -b -u -p ~/miniconda3
rm -rf ~/miniconda3/miniconda.sh
配置conda环境,主要是配置path变量
bash
# 1
vim /etc/profile
# 2 添加以下内容:
export PATH="~/miniconda3/bin:$PATH"
# 3
source /etc/profile
# 4
conda config --set auto_activate_base false
# 5 需要激活,否则 报错 conda: error: argument COMMAND: invalid choice: 'activate'
source activate
创建conda虚拟环境
bash
conda create -n gps python=3.8
conda activate gps # gps 为自己创建的环境名字
# conda deactivate gps