Conda environment commands
===

https://conda.io/docs/index.html

Create environment
---
    conda create --name my_environment python=3
    activate my_environment

To find necessary packages for a given script:

    python my_file.py

For each necessary package we can first search, e.g.

    conda search autograd

And then install them, e.g.

    conda install autograd
    conda install matplotlib
    conda install brewer2mpl
    conda install pandas
    conda install tqdm
    conda install scikit-learn
    conda install spyder
    conda install GPy
    pip install GPyOpt

Roll back to a previous revision
---

First, get a list of the revisions:

    conda list --revisions

Then, install the previous revision (second-to-last in the previous list):

    conda install --revision N

Export the environment file
---
    conda env export > environment.yml

Create environment from file
---
    conda env create -f my_environment.yml

This loads environment from yaml configuration file.

Activate environment
---
    activate my_environment

Deactivate environment
---
    deactivate

Remove environment
---
    conda remove --name my_environment --all

Update environment from YML file
---
    source activate myenv
    conda env update -f=local.yml

List all environments
---
    conda env list