Created
November 30, 2016 07:01
-
Star
(162)
You must be signed in to star a gist -
Fork
(44)
You must be signed in to fork a gist
-
-
Save pratos/e167d4b002f5d888d0726a5b5ddcca57 to your computer and use it in GitHub Desktop.
To package a conda environment (Requirement.txt and virtual environment)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# For Windows users# Note: <> denotes changes to be made | |
#Create a conda environment | |
conda create --name <environment-name> python=<version:2.7/3.5> | |
#To create a requirements.txt file: | |
conda list #Gives you list of packages used for the environment | |
conda list -e > requirements.txt #Save all the info about packages to your folder | |
#To export environment file | |
activate <environment-name> | |
conda env export > <environment-name>.yml | |
#For other person to use the environment | |
conda env create -f <environment-name>.yml |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# For Windows users |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@JutasiR, conda does not add libraries that you didn't install. The only exception is the base environment.
That's why you should create a new environment for your work and install what you need.
[]'s