Create and activate a new conda environment:
$ conda create -n myenv python=3 --yes
$ conda activate myenv
Add the conda-forge
channel into the conda configuration:
$ conda config --add channels conda-forge
Add packages into the environment using both conda
and pip
:
$ pip install imutils
$ pip install wget
$ conda install sqlalchemy
$ pip install sqlalchemy_utils
$ conda install tensorflow-gpu
$ pip install keras-retinanet
$ conda install scikit-learn
Save the environment's requirements to requirements.txt
and environment.yml
:
$ pip freeze > requirements.txt
$ conda env export | grep -v "^prefix: " > environment.yml