Installation
From NEST
Contents |
Requirements
Libraries
To compile NEST, you only need the GNU readline library, which is used for commandline editing in the builtin interpreter. On most Linux distributions, the library is split into two packages: the library itself (called libreadline) and a development package (libreadline-dev). To compile NEST, you need both of them.
To make additional neuron models available and to extend the number of different random number generators and NEST can use the GNU Scientific Library (GSL) library. The package is called libgsl-dev on most Linux distributions. It is, however not necessary to build NEST.
Optional dependencies
- If you intend to use PyNEST, the Python bindings for NEST, you need the Python development packages in a version >= 2.4. For higher performance, you can also install the numpy extension.
- If you intend to extend NEST with new models for neurons, devices or synapses, you need the GNU autotools, namely autoconf automake and libtool.
On Debian based systems, you are set using the following packages. For other Linux or Unix variants, the names may be similar, although other versions may be present.
- build-essential
- autoconf
- automake
- libtool
- libreadline5-dev
- libgsl0-dev
- libltdl3-dev
- libstdc++6.4.1-dev
- python-dev
- python-numpy-dev
- python-numpy
- python-matplotlib
- ipython
- python-scientific
- python-scientific-doc
Compilation and installation
Compilation and installation of NEST is straight forward on most recent Linux and Unix variants, including Mac OS X.
Installation into your home directory
Many users may not have root rights and want to install NEST into their home directory. In this case, NEST will create its own installation file-tree.
Assume you want to install NEST under /home/user/nest . Unpack the NEST archive in some temporary location. Next, create a directory in which you compile NEST. This way, it is possible to compile NEST with different options.
tar xzf nest-x.y.z.tar.gz mkdir build cd build ../nest-x.y.z/configure --prefix=/home/user/nest make make install
This will install NEST in your home directory. After installation, you can safely delete the build directory.
Global installation
If you want to install NEST into your operating system's file structure, you can just type
tar xzf nest-x.y.z.tar.gz mkdir build cd build ../nest-x.y.z/configure make su - make install
This will install NEST system-wide for all users. After installation, you can delete the build directory. It is no longer needed.
What gets installed where
The default prefix for the installation depends on the operating system you are using. However, in most cases it will default to /usr or /usr/local. It can be changed by using the --prefix=/path/ switch for configure. In the following, we will use $PREFIX to refer to this location.
- Executables
-
$PREFIX/bin - Extension modules
-
$PREFIX/lib/nest - SLI libraries
-
$PREFIX/share/nest/sli - Documentation
-
$PREFIX/share/doc/nest - Examples
-
$PREFIX/share/doc/nest/examples - PyNEST
-
$PREFIX/lib/pythonX.Y/site-packages/nest - PyNEST examples
-
$PREFIX/share/doc/nest/examples/pynest - Extras
-
$PREFIX/share/nest/extras/emacs/sli
Calling NEST
To call NEST, you must add the installation directory to your search path. For example, if you are using bash:
export PATH=$PATH:$PREFIX/bin
To make Python aware of NEST, define the following in your .bashrc
export PYTHONPATH=$PREFIX/lib/pythonX.Y/site-packages
Please replace $PREFIX by your configured --prefix= value and pythonX.Y by your Python version.
Configure options
If you need special features, like e.g. support for distributed computing via the Message Passing Interface (MPI) or if you want to compile the Python bindings (PyNEST), you can add commandline switches to the call to configure. ./configure --help will show you all available options. For more information on the installation of NEST, please see the file INSTALL that is included in the distribution archive.
Mac OSX
Before you can install NEST under Mac OS, you need to install development packages, including g++ and Python (see above).
Mac has two popular systems to install and update GNU/Unix related software. They are called Fink and Macports.
After you have installed these packages, follow the generic installation instructions for Linux.
Windows
Windows and Linux differ considerably in their systems calls. This is the reason why it is difficult to compile (read: nobody ever dared) NEST under Windows.
However, it is still possible to use NEST under Windows. There are three methods:
- Don't
- In a virtual machine
- Using cygwin.
Virtual Machines
A virtual machine is a software that lets you use Linux in parallel to Windows. Popular systems are VMWare and VirtualBox.
Install a virtual machine with a Linux distribution and follow the generic installation instructions.
Pre-configured Linux images for many distributions are available on the NEST.
Cygwin
Cywin is a software layer which emulates Unix system calls. NEST should compile and install under cygwin with the generic installation instructions.
Compilation under Cygwin is very slow, but the execution times are comparable to an equivalent Linux installation.
