https://repo.anaconda.com/archive/
, 或者自己在电脑上把已经下载好的anaconda通过FTP上传到到服务器上。
1
|
Wget https://repo.anaconda.com/archive/Anconda3.-5.3.0-Linux-x86_64.sh
|
1
|
conda create -n your_env_name python=3.7 //your_env_name为虚拟环境名
|
1
|
source deactivate your_env_name
|
1
|
source deactivate your_env_name
|
1
|
conda remove -n your_env_name --all
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55
|
#列出所有已安装的包 conda list #安装软件包,同时它会自动安装此软件包的依赖项 conda install package_name #同时安装多个包 conda install numpy pandas #安装指定版本的包 conda install python=2.7 #安装离线包 conda install /package-path/package-filename.tar.bz2 #卸载包 conda remove package_name #更新环境中的所有已安装的包 conda update/upgrade --all #更新conda,保持conda最新 conda update conda #更新anaconda conda update anaconda #更新python conda update python #查看conda安装信息 conda info #查看conda帮助 conda help #搜索可以安装的包 conda search package_name #创建conda虚拟环境 conda create -n env_name #在这里,-n env_name 设置环境的名称(-n 是指名称),而 list of packages 是要安装在环境中的包的列表 conda create -n env_name list of packages #可以创建具有特定 Python 版本的环境 conda create -n py2.7.14 python=2.7.14 #查看conda版本 conda -V
#进入环境 #linux 下用 source activate env_name #windows 下用 activate env_name
#离开环境 #linux 下用 source deactivate #windows 下用 deactivate
#列出环境 conda env list #删除环境 conda env remove -n env_name #导出环境将包保存为 YAML,输出环境中的所有包的名称(包括 Python 版本) conda env export > environment.yaml #加载环境 conda env create -f environment.yaml
|