CondaInstall: Difference between revisions

From GNU Radio
Jump to navigation Jump to search
No edit summary
No edit summary
Line 9: Line 9:
== Install conda itself ==
== Install conda itself ==


First, you will need to install a base conda ''distribution'' so that you can use the ''conda'' program to create an environment and install the GNU Radio packages. If you already have this and can run ''conda'' on a command line or use the Anaconda Navigator to install packages, skip to the next step.
First, you will need to install a base conda ''distribution'' so that you can use the <code>conda</code> program to create an environment and install the GNU Radio packages. If you already have this and can run <code>conda</code> on a command line or use the Anaconda Navigator to install packages, skip to the next step.


If this is your first time using conda, we recommend [https://github.com/conda-forge/miniforge miniforge] for the base installation. This provides a minimal environment to run ''conda'' that is already set up to pull packages from conda-forge (which is where you can find GNU Radio). Download and install miniforge by following the instructions at [https://github.com/conda-forge/miniforge]. Installers for many different platforms are available there, but the most relevant are the following:
If this is your first time using conda, we recommend [https://github.com/conda-forge/miniforge miniforge] for the base installation. This provides a minimal environment to run <code>conda</code> that is already set up to pull packages from conda-forge (which is where you can find GNU Radio). Download and install miniforge by following the instructions at [https://github.com/conda-forge/miniforge]. Installers for many different platforms are available there, but the most relevant are the following:


* [https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-Linux-x86_64.sh Linux x86_64]
* [https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-Linux-x86_64.sh Linux x86_64]
Line 17: Line 17:
* [https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-Windows-x86_64.exe Windows x86_64]
* [https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-Windows-x86_64.exe Windows x86_64]


For Linux and macOS, run the downloaded installer from a console and follow the prompts:
For ''Linux and macOS'', run the downloaded installer from a console and follow the prompts:


* <code>bash Miniforge3-Linux-x86_64.sh   # for Linux</code>
* (Linux) <code>bash Miniforge3-Linux-x86_64.sh</code>
* <code>bash Miniforge3-MacOSX-x86_64.sh   # for macOS</code>
* (macOS) <code>bash Miniforge3-MacOSX-x86_64.sh</code>


For Windows, double click on the downloaded installer executable and follow the prompts.
By default, this will install miniforge to your home directory at <code>~/miniforge3</code> and allow you to use the <code>conda</code> command from any console.
 
For ''Windows'', double click on the downloaded installer executable and follow the prompts. By default, this will install miniforge to your user directory at <code>C:\Users\USERNAME\miniforge3</code> and add a "Miniforge Prompt" entry to your start menu. Running the "Miniforge Prompt" should bring up a console window where your base conda environment is activated and you can use the <code>conda</code> command.
 
[https://docs.conda.io/projects/conda/en/latest/user-guide/getting-started.html This guide] provides a nice introduction to using conda generally; it may help you better understand the rest of these instructions, but it is not necessary to read.
 
''(Optional, experts only)'' It may be convenient to now install <code>mamba</code> in your base environment and use it in place of the <code>conda</code> command. Mamba is a third-party alternative to conda that is written in C instead of Python, and its main benefit is faster dependency resolution when installing packages. If you do install mamba, you can simply use the <code>mamba</code> command in place of <code>conda</code> for all subsequent steps.

Revision as of 16:46, 8 January 2021

Why use conda?

Conda is a cross-platform package manager (supporting Linux, macOS, and Windows) that makes it easy to install GNU Radio, its dependencies, and out-of-tree modules in a self-contained environment. Conda lets you create independent environments with their own sets of packages, and those environments are separate from your system installation and other package managers. If you've struggled with installing GNU Radio by other methods, or you want to try out a new version without affecting your tried-and-true system installation, conda may be right for you!

Installation

The conda packages for GNU Radio are unofficial and supported through volunteer effort within the conda-forge community. Please report and discuss any packaging-specific issues with the maintainers at the gnuradio feedstock on Github.

Install conda itself

First, you will need to install a base conda distribution so that you can use the conda program to create an environment and install the GNU Radio packages. If you already have this and can run conda on a command line or use the Anaconda Navigator to install packages, skip to the next step.

If this is your first time using conda, we recommend miniforge for the base installation. This provides a minimal environment to run conda that is already set up to pull packages from conda-forge (which is where you can find GNU Radio). Download and install miniforge by following the instructions at [1]. Installers for many different platforms are available there, but the most relevant are the following:

For Linux and macOS, run the downloaded installer from a console and follow the prompts:

  • (Linux) bash Miniforge3-Linux-x86_64.sh
  • (macOS) bash Miniforge3-MacOSX-x86_64.sh

By default, this will install miniforge to your home directory at ~/miniforge3 and allow you to use the conda command from any console.

For Windows, double click on the downloaded installer executable and follow the prompts. By default, this will install miniforge to your user directory at C:\Users\USERNAME\miniforge3 and add a "Miniforge Prompt" entry to your start menu. Running the "Miniforge Prompt" should bring up a console window where your base conda environment is activated and you can use the conda command.

This guide provides a nice introduction to using conda generally; it may help you better understand the rest of these instructions, but it is not necessary to read.

(Optional, experts only) It may be convenient to now install mamba in your base environment and use it in place of the conda command. Mamba is a third-party alternative to conda that is written in C instead of Python, and its main benefit is faster dependency resolution when installing packages. If you do install mamba, you can simply use the mamba command in place of conda for all subsequent steps.