Skip to content

Commit 76bafd0

Browse files
update instances of conda with mamba
1 parent 1275fce commit 76bafd0

20 files changed

+130
-151
lines changed

README.md

+1-3
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
[![Ubuntu version](https://img.shields.io/badge/ubuntu-(PPA)-blue?logo=debian)](https://nest-simulator.readthedocs.io/en/latest/installation/)
1414
[![Fedora package](https://img.shields.io/fedora/v/nest?logo=fedora)](https://src.fedoraproject.org/rpms/nest)
15-
[![Conda version](https://img.shields.io/conda/vn/conda-forge/nest-simulator.svg?logo=conda-forge&logoColor=white)](https://anaconda.org/conda-forge/nest-simulator)
15+
[![conda-forge version](https://img.shields.io/conda/vn/conda-forge/nest-simulator.svg?logo=conda-forge&logoColor=white)](https://anaconda.org/conda-forge/nest-simulator)
1616
[![Homebrew version](https://img.shields.io/homebrew/v/nest.svg?logo=apple)](https://formulae.brew.sh/formula/nest)
1717
[![Docker Image Version](https://img.shields.io/docker/v/nest/nest-simulator?color=blue&label=docker&logo=docker&logoColor=white&sort=semver)](https://hub.docker.com/r/nest/nest-simulator)
1818
[![Virtual applicance](https://img.shields.io/badge/VM-v3.7-blue?logo=CodeSandbox)](https://nest-simulator.readthedocs.io/en/latest/installation/livemedia.html#live-media)
@@ -127,5 +127,3 @@ to find out how to install NEST.
127127
Please cite NEST if you use it in your work.
128128

129129
- You can find all the information for [citing NEST here](https://nest-simulator.readthedocs.io/en/latest/citing-nest.html)
130-
131-

doc/htmldoc/connect_nest/nest_server.rst

+3-3
Original file line numberDiff line numberDiff line change
@@ -59,11 +59,11 @@ For native installations, the requirements can be simply installed via ``pip``::
5959

6060
pip3 install Flask Flask-Cors gunicorn RestrictedPython
6161

62-
or by installing the full NEST development environment in case you prefer using ``conda``::
62+
or by installing the full NEST development environment in case you prefer using ``mamba``::
6363

6464
cd <nest-source-dir>
65-
conda env create -p conda/
66-
conda activate conda/
65+
mamba env create -p mamba/
66+
mamba activate mamba/
6767

6868
As an alternative to a native installation, NEST Server is available from the NEST Docker image. Please check out the
6969
corresponding :ref:`installation instructions <docker>` for more details.

doc/htmldoc/developer_space/guidelines/mailing_list_guidelines.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ please follow the guidelines below:
3030

3131
* the steps you took that lead to the problem.
3232
* the specific error messages you get.
33-
* relevant system and version information (e.g., Ubuntu 22.04/ NEST 3.5 installed using the Conda package).
33+
* relevant system and version information (e.g., Ubuntu 22.04/ NEST 3.5 installed using the conda-forge package).
3434

3535
#. Keep topics separate.
3636

doc/htmldoc/developer_space/workflows/documentation_workflow/user_documentation_workflow.rst

+15-7
Original file line numberDiff line numberDiff line change
@@ -84,30 +84,38 @@ If you have not done so alrealdy first
8484
Set up your environment
8585
~~~~~~~~~~~~~~~~~~~~~~~
8686

87-
Using the Conda package (includes everything to build NEST, including documentation)
88-
````````````````````````````````````````````````````````````````````````````````````
87+
Using the conda-forge package (includes everything to build NEST, including documentation)
88+
```````````````````````````````````````````````````````````````````````````````````````````
8989

90-
For details on Conda, see :ref:`conda_tips`
90+
For details on installation see :ref:`conda_forge_install`
9191

9292
.. code-block:: bash
9393
9494
cd <nest_source_dir>/
95-
conda env create -p conda/
96-
conda activate conda/
95+
mamba env create -p mamba/
96+
mamba activate mamba/
9797
9898
If you later on want to deactivate or delete the build environment:
9999

100100
.. code-block:: bash
101101
102-
conda deactivate
103-
rm -rf conda/
102+
mamba deactivate
103+
rm -rf mamba/
104104
105105
Using pip (includes packages for documentation only)
106106
````````````````````````````````````````````````````
107107

108108
If you want to install only a minimal set of packages for building the
109109
documentation and avoid using Conda, you can use pip:
110110

111+
Create and activate a Python virtual environment:
112+
113+
.. code-block:: bash
114+
115+
python -m venv <myvenv>
116+
117+
source <myvenv>/bin/activate
118+
111119
.. code-block:: bash
112120
113121
pip3 install -r <nest_source_dir>/doc/requirements.txt

doc/htmldoc/developer_space/workflows/nest_with_ides.rst

+8-8
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ Requirements and limitations
2525
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2626

2727
* Focus on single build configuration
28-
* Assumes all dependencies (OpenMPI, GSL, etc) installed in a Conda environment
28+
* Assumes all dependencies (OpenMPI, GSL, etc) installed in a Mamba environment
2929
* Does not support debugging on macOS (because Eclipse does not support lldb)
3030
* Does not read the NEST `.clang-format` file, so code formatting may
3131
be incorrect
@@ -62,25 +62,25 @@ Setting up the project
6262
#. Right click the project and choose ``Properties`` from the context
6363
menu
6464

65-
a. Under ``C/C++ Build/Build Variables``, define ``BUILD_DIR`` and ``CONDA_ENV``,
65+
a. Under ``C/C++ Build/Build Variables``, define ``BUILD_DIR`` and ``MAMBA_ENV``,
6666
both of type ``Path``. The first should contain the full path to the build
67-
directory you created above, the second the full path to your conda
68-
environment, usually something like ``.../miniconda3/envs/nest-dev``.
67+
directory you created above, the second the full path to your mamba
68+
environment, usually something like ``.../mamba/envs/nest-dev``.
6969
#. Under ``C/C++ Build – [Tab] Builder Settings``,
7070

7171
#. uncheck ``Use default build command``
7272
#. set ``Build Command`` to ``make -k -j4 all install`` (adjust
7373
number of processes to your situation)
7474
#. set ``Build Directory`` to ``${BUILD_DIR}``
7575
#. Under ``C/C++ Build > Environment``, prepend
76-
``${CONDA_ENV}/bin`` to ``PATH``
76+
``${MAMBA_ENV}/bin`` to ``PATH``
7777
#. Under ``C/C++ General > Paths and Symbols – [Tab] Includes``, add the
7878
following two direcories
7979

8080
* ``${BUILD_DIR}/libnestutil`` (contains ``config.h``)
81-
* ``${CONDA_ENV}/include`` (all headers from packages provided in conda environment)
81+
* ``${mamba_env}/include`` (all headers from packages provided in Mamba environment)
8282
#. Under ``PyDev - Interpreter/Grammar``, choose the interpreter from
83-
your Conda environment (you may need to add it by following the
83+
your Mamba environment (you may need to add it by following the
8484
``Click here to configure an interpreter not listed`` link and
8585
then ``Browse for python/pypy exe`` (this temporarily takes you
8686
to the global Eclipse preferences in a separate window).
@@ -261,7 +261,7 @@ We need several packages installed, before we can become productive with NEST:
261261
* gsl
262262
* cmake
263263
* libtool
264-
* ipython, python, cython, ... The best way to install all the python requirements is to use `Anaconda <https://store.continuum.io/cshop/anaconda/>`_.
264+
* ipython, python, cython, ... The best way to install all the python requirements is to use `Mamba <https://mamba.readthedocs.io/en/latest/index.html/>`_.
265265

266266
We present two ways to install the rest: MacPorts and Homebrew. For both versions you need to have Xcode and Xcode command line tools installed:
267267

+13-16
Original file line numberDiff line numberDiff line change
@@ -1,61 +1,58 @@
11
.. _conda_forge_install:
22

3-
Conda forge install
3+
conda-forge install
44
===================
55

66
.. admonition:: osx-arm64: missing random number generators
77

8-
Due to a cross-compiling issue in the conda NEST package, some random number
9-
generators are not available if you are using macOS arm64 architecture.
8+
Due to a cross-compiling issue in the conda-forge NEST package, some random number
9+
generators are not available if you are using macOS arm64 architecture.
1010
The available generators are the Mersenne Twister generators `mt19937` and `mt19937_64`.
1111

1212
.. note::
1313

14-
If you encounter problems installing the NEST conda package and
15-
environment, we recommend using Mamba (https://mamba.readthedocs.io).
14+
We recommend using Mamba (https://mamba.readthedocs.io).
1615
Mamba has the advantage of installing conda packages and
1716
environments more quickly and can be used as a complete drop-in replacement for conda.
1817

19-
1. To keep your conda setup tidy, we recommend that you install NEST into
20-
a separate `conda environment <https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/manage-environments.html>`_
18+
1. To keep your mamba setup tidy, we recommend that you install NEST into
19+
a separate environment
2120
together with Python packages that you will use when working with NEST;
2221
see also our :ref:`conda_tips`.
2322

2423
To install the latest version of NEST in a new environment called ``ENVNAME``, just run
2524

2625
.. code-block:: sh
2726
28-
conda create --name ENVNAME -c conda-forge nest-simulator
27+
mamba create --name ENVNAME -c conda-forge nest-simulator
2928
3029
To install additional packages into the environment, just list them together with ``nest-simulator``.
3130

3231
.. code-block:: sh
3332
34-
conda create --name ENVNAME -c conda-forge nest-simulator jupyterlab seaborn
33+
mamba create --name ENVNAME -c conda-forge nest-simulator jupyterlab seaborn
3534
3635
#. To see all NEST versions available via conda, either run
3736

3837
.. code-block:: sh
3938
40-
conda search -c conda-forge nest-simulator
39+
mamba search -c conda-forge nest-simulator
4140
42-
or browse the `conda forge file list
43-
<https://anaconda.org/conda-forge/nest-simulator/files>`_ (note
44-
there are multiple pages). To install, e.g., NEST 2.18.0, run
41+
To install a specific version e.g., NEST 2.18.0, run
4542
4643
.. code-block:: sh
4744
48-
conda create --name nest_2_18_0 -c conda-forge nest-simulator=2.18.0=*
45+
mamba create --name nest_2_18_0 -c conda-forge nest-simulator=2.18.0=*
4946
5047
The syntax for this install follows the pattern: ``nest-simulator=<version>=<build_string>``.
5148

5249
#. Activate your environment:
5350

5451
.. code-block:: sh
5552
56-
conda activate ENVNAME
53+
mamba activate ENVNAME
5754
5855
#. Note the following:
5956

60-
- We currently provide NEST with thread-based parallelization on conda. This should suffice for most
57+
- We currently provide NEST with thread-based parallelization on conda-forge. This should suffice for most
6158
uses on personal computers.
+25-41
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,27 @@
11
.. _conda_tips:
22

3-
Tips for installing NEST with conda
3+
Tips for installing NEST with Mamba
44
===================================
55

6-
.. note::
6+
.. note::
77

8-
If you encounter problems installing the NEST conda package and
9-
environment, we recommend using Mamba (https://mamba.readthedocs.io).
10-
Mamba has the advantage of installing conda packages and
8+
We recommend using Mamba (https://mamba.readthedocs.io).
9+
Mamba has the advantage of installing conda packages and
1110
environments more quickly and can be used as a complete drop-in replacement for conda.
1211

1312
This page provides a series of recommendations for installing pre-built NEST with
1413
conda or to set up conda environments for building NEST and NEST documentation.
1514

16-
Basic conda setup
15+
Basic mamba setup
1716
-----------------
1817

19-
Choice of conda base installation
20-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
21-
22-
We test NEST in conda environments using Miniconda installations and thus recommend
23-
that you do the same. The recommendations that we provide here will also likely work with a
24-
full-sized Anaconda installation, but we can only provide limited support for this.
25-
26-
You can either install
18+
Apple systems
19+
~~~~~~~~~~~~~
2720

28-
- Miniconda from `<https://docs.conda.io/en/latest/miniconda.html>`_
29-
- Miniforge from `<https://github.com/conda-forge/miniforge>`_
3021

31-
For Apple systems with an M1 chip, you must at present use Miniforge and
32-
select the ``arm64 (Apple Silicon)`` installer to create a conda environment
22+
For Apple systems with an M1 chip, you must at present use `Miniforge
23+
<https://github.com/conda-forge/miniforge>`_ and
24+
select the ``arm64 (Apple Silicon)`` installer to create a mamba environment
3325
that will support native builds of NEST.
3426

3527

@@ -38,32 +30,29 @@ Keep your base environment empty
3830

3931
Your base environment should be as empty as possible in order to avoid
4032
conflicts with other environments. Always install packages only in the new
41-
environments (don't worry about duplicates, conda will link the packages
33+
environments (don't worry about duplicates, mamba will link the packages
4234
if they are used in multiple environments, and not produce disk eating copies).
4335

4436

45-
Get familiar with conda environments
37+
Get familiar with mamba environments
4638
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4739

48-
Conda environments are a powerful tool. See the `Conda documentation on Managing Environments
49-
<https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/manage-environments.html>`_
50-
for more information.
5140

5241
To see which environments are installed on your system, use
5342

5443
.. code:: sh
5544
56-
conda info --envs
45+
mamba info --envs
5746
5847
59-
Installing NEST with Conda
60-
--------------------------
48+
Installing NEST with conda-forge
49+
--------------------------------
6150

62-
We provide pre-built versions of NEST on `Conda Forge <https://anaconda.org/conda-forge/nest-simulator/files>`_.
63-
Follow :ref:`these instructions to install NEST from Conda Forge <conda_forge_install>`.
51+
We provide pre-built versions of NEST on `conda-forge <https://conda-forge.org/docs/>`_.
52+
Follow :ref:`these instructions to install NEST from conda-forge <conda_forge_install>`.
6453

6554

66-
Creating a Conda environment for running and building NEST
55+
Creating a mamba environment for running and building NEST
6756
----------------------------------------------------------
6857

6958
If you want to compile NEST yourself, you can create an environment containing all necessary
@@ -72,31 +61,26 @@ software for running and building NEST by executing the following command from t
7261
.. code:: sh
7362
7463
cd <nest-source-dir>
75-
conda env create -p conda
64+
mamba env create -p mamba
7665
77-
This will create an environment in the folder ``conda/``. If you would like to activate the environment, use
66+
This will create an environment in the folder ``mamba/``. If you would like to activate the environment, use
7867

7968
.. code:: sh
8069
81-
conda activate conda/
70+
mamba activate mamba/
8271
83-
Note that the trailing slash is required for conda not to confuse the path with a named environment (for example when
72+
Note that the trailing slash is required for mamba not to confuse the path with a named environment (for example when
8473
using ``--name``).
8574

8675

8776
Get a good overview
8877
-------------------
8978

9079
Obtain a good overview of which packages are installed where. You can use
91-
``conda env export -n base`` and ``conda env export -n yournestenv``
80+
``mamba env export -n base`` and ``mamba env export -n yournestenv``
9281
(replacing the ``yournestenv`` name with whatever you chose). Make
93-
sure each environment contains all dependencies. One way to make
94-
this obvious would be to reduce conda stack to ``0`` (see conda documentation on
95-
`nested activation <https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/manage-environments.html#nested-activation>`_),
96-
and/or to a certain degree by not auto-activating the base environment (see conda documentation on
97-
`conda init <https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/manage-environments.html#conda-init>`_).
98-
Then packages from base do not 'leak' into your new environments.
82+
sure each environment contains all dependencies.
9983

10084
.. note::
101-
Packages from your system will usually also be available in your conda
85+
Packages from your system will usually also be available in your mamba
10286
environment and may cause similar conflicts.

doc/htmldoc/installation/condaenv_install.rst

+10-15
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,21 @@
11
.. _condaenv:
22

3-
Install from source in a conda environment
3+
Install from source in a mamba environment
44
==========================================
55

6-
.. note::
6+
.. note::
77

8-
If you encounter problems installing the NEST conda package and
9-
environment, we recommend using Mamba (https://mamba.readthedocs.io).
10-
Mamba has the advantage of installing conda packages and
8+
We recommend using Mamba (https://mamba.readthedocs.io).
9+
Mamba has the advantage of installing conda packages and
1110
environments more quickly and can be used as a complete drop-in replacement for conda.
1211

13-
* Create a conda environment from the `environment.yml <https://github.com/nest/nest-simulator/blob/master/environment.yml>`_ file.
14-
We recommend specifying a dedicated location (``-p <path/to/conda/env>``) for your environment.
15-
See the `conda documentation <https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/manage-environments.html#specifying-a-location-for-an-environment>`_
16-
on using a custom location rather than the default envs folder.
12+
* Create a mamba environment from the `environment.yml <https://github.com/nest/nest-simulator/blob/master/environment.yml>`_ file.
13+
We recommend specifying a dedicated location (``-p <path/to/mamba/env>``) for your environment.
1714

1815
.. code-block:: sh
1916
20-
conda env create -f nest-simulator/environment.yml --p <path/to/conda/env>
21-
conda activate <path/to/conda/env>
17+
mamba env create -f nest-simulator/environment.yml --p <path/to/mamba/env>
18+
mamba activate <path/to/mamba/env>
2219
2320
* Create a build directory:
2421

@@ -32,12 +29,12 @@ Install from source in a conda environment
3229
3330
cd build_dir
3431
35-
* Configure NEST. Add the cmake option ``-CDMAKE_INSTALL_PREFIX:PATH=$CONDA_PREFIX`` to link nest to your active conda environment.
32+
* Configure NEST. Add the cmake option ``-CDMAKE_INSTALL_PREFIX:PATH=$MAMBA_PREFIX`` to link nest to your active mamba environment.
3633
You may need additional ``cmake`` options (see :ref:`cmake_options`).
3734

3835
.. code-block:: sh
3936
40-
cmake -DCMAKE_INSTALL_PREFIX:PATH=$CONDA_PREFIX </path/to/NEST/src>
37+
cmake -DCMAKE_INSTALL_PREFIX:PATH=$MAMBA_PREFIX </path/to/NEST/src>
4138
4239
* Compile and install NEST:
4340

@@ -60,5 +57,3 @@ sourcing the script:
6057
.. note::
6158

6259
To build the developer or user documentation see :ref:`doc_workflow`
63-
64-

0 commit comments

Comments
 (0)