python, environment, conda

1. What is Conda

    Conda is an open source package management system and environment management system that runs on Windows, macOS, and Linux.

    Conda quickly installs, runs and updates packages and their dependencies.

    Conda easily creates, saves, loads, and switches between environments on your local computer.

    It was created for Python programs but it can package and distribute software for any language.

2. Install Conda and create virtual environment

    ( 1 ) Download the installer for Linux  from here: https://docs.conda.io/en/latest/miniconda.html and I downloaded Miniconda installer for Linux(my system is Ubuntu 14 )  

    ( 2 ) Go to the installer-file directory and run $bash Miniconda3-latest-xxxxxxx.sh 

  ( 3 ) Stop the virtual environment if that virtual environment is running  $conda deactivate  

  ( 4 ) Create a virtual environment naming "helloProject" and install python3.5,  $conda -n helloProject python=3.5   

    ( 5 )  Activate that virtual environment  $ conda activate helloProject

  ( 6 ) Install package under the virtual environment, ( "helloProject" is ahead of  ' $ ' ) which means a virtual environment has launched 

     (helloProject)$ conda install scikit-learn    #install scikit-learn package

  ( 7 ) Exit the virtual environment $ conda deactivate

    

posted @ 2020-01-02 09:48  心怀阳光  阅读(683)  评论(0编辑  收藏  举报