[python] Conda’s powerful package/environment management tool

Conda is a powerful package/environment management tool

1 Introduction

Conda是Anaconda中一个强大的包和环境管理工具,可以在Windows的Anaconda Prompt命令行使用,也可以在macOS或者Linux系统的终端窗口(terminal window)的命令行使用。

2. Installation

[Linux平台安装教程](https://docs.conda.io/projects/miniconda/en/latest/miniconda-install.html)
[快速安装教程](https://docs.conda.io/projects/miniconda/en/latest/index.html#quick-command-line-install)

3. Instructions

Order illustrate
conda create -n env_name package_name Create a new environment named env_name and install the package named package_name in that environment. You can specify the version number of the new environment, for example:conda create -n python2 python=2.7 numpy pandas
conda env list View env environment
conda activate env_name Switch to env_name environment
conda deactivate Exit environment
conda install package_name Install packages in the current environment
conda update conda Update to the latest version and other related packages will also be updated.
conda update --all Update all packages
conda info -e Show all created environments
conda list View all installed packages
conda remove --name env_name package Delete the package in the specified environment
conda remove package Delete a package from the current environment
conda create --name new_env_name --clone old_env_name Copy old_env_name to new_env_name
conda remove --name env_name –all Delete environment
conda --version Check the conda version and verify whether it is installed
source activate env_name Switch to env_name environment
conda create -n tensorflow_env tensorflow
conda activate tensorflow_env
Install and activate the CPU version of TensorFlow
conda create -n tensorflow_gpuenv tensorflow-gpu
conda activate tensorflow_gpuenv
Install and activate the GPU version of TensorFlow
conda update package_name Update specified package
conda install --name env_name package_name Install package in specified environment
conda env remove -n env_name Delete environment

Guess you like

Origin blog.csdn.net/Darlingqiang/article/details/134426227