Set up Conda on your computer¶
Whether you're installing conda on your own computer, a cloud instance, or high performance computer (HPC) server, you'll need to consider the following:
- Both are free versions with Miniconda being the light weight version
Operating system: Windows, MacOS, Linux
- Bit-count: 32 vs 64-bit
- MacOS is 64-bit only
- Python version for root environment (2.x vs 3.x)
- version 3.x is the default option (we recommend this!)
- choose 2.7 version if you have mostly 2.7 code or use packages that do not have a 3.x version (but keep in mind that python 2.x is no longer being maintained)
Conda can be installed via Miniconda (a smaller more efficient package) or Anaconda (the full installation of conda). From the conda website:
"Miniconda is a free minimal installer for conda. It is a small, bootstrap version of Anaconda that includes only conda, Python, the packages they depend on, and a small number of other useful packages, including pip, zlib and a few others. Use the conda install command to install 720+ additional conda packages from the Anaconda repository."
This tutorial is a walk-through with Miniconda for MacOS.
Linux and Windows
The process below is very similar for installing the Linux version.
For Windows computers, take a look at the instructions from conda. You can run conda commands in the Anaconda Prompt terminal interface, which comes with the installation.
Step 1: Download the installer¶
Select the installer for: "Miniconda3 MacOSX 64-bit bash". We are using the 64-bit version for working with Python 3.x.
Alternatively, you can download from Anaconda's repository of installers via command line with the
Step 2: Verify your installer hashes¶
Go to the directory where you saved the installer file (e.g., "Downloads/"). Open up Terminal and navigate to that directory:
Let’s check our installation to make sure it went smoothly. We can do this by verifying the digital fingerprint or ‘hash’ of the files we just installed using the
shasum -a 256 Miniconda3-latest-MacOSX-x86_64.sh
Step 3: Install Miniconda¶
you will be asked to review the license. Hit Enter key and scroll through.
you will be asked if you accept the license terms. Type
Miniconda will be installed in the location printed on the screen. Hit Enter key to confirm.
Miniconda will now be installed. This takes a few minutes to complete. The progress will be displayed in the Terminal window.
you will be asked if you wish the installer to initialize Miniconda3 by running
conda init. Type
for changes to take effect,
exitand re-open Terminal window.
Step 4: Verify that you can run conda¶
Now, when you re-open Terminal, the command prompt will start with
(base), indicating that you are in the base conda environment. It will look something like this:
Check the version of your new conda installation:
If you got a conda version, then you are ready to use conda!
Remember to configure your conda channels:
conda config --add channels defaults conda config --add channels bioconda conda config --add channels conda-forge
- Now you have a working conda installation that you can use to create custom conda environments on your computer, cloud instance, or space on an HPC server!
- As a reminder, if you are using your local installation of conda on a Windows computer, the
biocondachannel is not supported. While it's possible to add as a channel, you won't be able to search or install software from it! The
conda-forgechannels are available for Windows.