一、使用Anaconda配置Python环境
安装anaconda:bash Anaconda3-2019.10-Linux-x86_64.sh
实验室服务器没有挂公网,所以只能用离线方式安装,包括下面的pytorch和TensorFlow都是一样。
panchengchang@a-node03:~/envir_packages$ bash Anaconda3-2019.10-Linux-x86_64.sh
Welcome to Anaconda3 2019.10
In order to continue the installation process, please review the license
agreement.
Please, press ENTER to continue
>>>
按要求一直回车,要输yes就输yes就可以。
Do you accept the license terms? [yes|no]
[no] >>> yes
Anaconda3 will now be installed into this location:
/raid/620/panchengchang_19/anaconda3
- Press ENTER to confirm the location
- Press CTRL-C to abort the installation
- Or specify a different location below
[/raid/620/panchengchang_19/anaconda3] >>>
-按ENTER确认位置
-按CTRL-C中止安装
-或者在下面指定其他位置
直接回车就进行安装了,后面还需要再输一次yes
Preparing transaction: done
Executing transaction: done
installation finished.
Do you wish the installer to initialize Anaconda3
by running conda init? [yes|no]
[no] >>> yes
no change /raid/620/panchengchang_19/anaconda3/condabin/conda
no change /raid/620/panchengchang_19/anaconda3/bin/conda
no change /raid/620/panchengchang_19/anaconda3/bin/conda-env
no change /raid/620/panchengchang_19/anaconda3/bin/activate
no change /raid/620/panchengchang_19/anaconda3/bin/deactivate
no change /raid/620/panchengchang_19/anaconda3/etc/profile.d/conda.sh
no change /raid/620/panchengchang_19/anaconda3/etc/fish/conf.d/conda.fish
no change /raid/620/panchengchang_19/anaconda3/shell/condabin/Conda.psm1
no change /raid/620/panchengchang_19/anaconda3/shell/condabin/conda-hook.ps1
no change /raid/620/panchengchang_19/anaconda3/lib/python3.7/site-packages/xontrib/conda.xsh
no change /raid/620/panchengchang_19/anaconda3/etc/profile.d/conda.csh
modified /raid/620/panchengchang_19/.bashrc
==> For changes to take effect, close and re-open your current shell. <==
If you'd prefer that conda's base environment not be activated on startup,
set the auto_activate_base parameter to false:
conda config --set auto_activate_base false
Thank you for installing Anaconda3!
===========================================================================
Anaconda and JetBrains are working together to bring you Anaconda-powered
environments tightly integrated in the PyCharm IDE.
PyCharm for Anaconda is available at:
https://www.anaconda.com/pycharm
panchengchang@a-node03:~/envir_packages$
重启终端,输入conda或pip验证用户环境变量是否可以使用。
这