

Users/computationalphysics/anaconda/envs/astroconda/bin/python For example if you wanted to run ipython in the astroconda environment you would use the following commands. You don't need to do anything to activate the root environment, but to activate the other environments you issue the command source activate environment_name. For general purpose programming the default root environment is probably best. Installing these environments allows you to use whichever version of Python you need. Again, it's a large amount of code so it will take a few minutes to install. You will again be prompted to proceed with the installation. $ conda create -n iraf27 python=2.7 iraf-all pyraf-all stsci

This command will generate some output and then will display the prompt Proceed (/n)?.

The following installation instructions is a summary drawn from the Installation Instructions on the Space Telescope Science Institue AstroConda page. This is because IRAF doesn't "play well" with Python 3.

An AstroConda/IRAF environment running Python 2.7.An AstroConda environment running Python 3.The Anaconda default (root) environment running Python 3.A better flow will depend on your need.These instructions should install the Anaconda Python distribution and three separate Anaconda environments: This will install on activated envĪt the end of the day, conda is there to help you. Python -m pip install -r requirements.txtĪt any point, we can add packages in conda environment with # this will install requests to ml_api env. I will do: conda create -name ml_api python=3.7 -c conda-forge scikit-learn pandas For example, if I have a project with requirements.txt to be installed with pip but would like it to have pandas and scikit-learn from conda-forge. In fact, we often use a mix here and there. create an environment, activate, install packagesĬonda install package_name another_packageĬonda create -n env_name python=3.8 package_name another_packageīoth methods are correct.There are multiple ways to create and install packages using conda.
