Installing PyBrain and its dependencies

There are several requirements for PyBrain and we will go through them step by step.


On most Unix systems as Linux or Mac OS X, Python is already installed, but you should check if it is the right version - otherwise you will get weird errors. One way to do this is on the commandline:

$ python --version
Python 2.5.2


Most command line examples will have a Unix look, but all of them are usable on Windows systems, too.

If you have not installed Python, you should go to the official Python download page and follow the instructions there.


Setuptools is a package that contains Python’s package manager and makes installation of python packages easier. We will use this for the requirements.

First, download this bootstrap script and run it:

$ python


On Unix systems, you will possibly have to run these commands as a superuser.

Scipy and Matplotlib

This will install the python package manager Easy Install for you. Afterwards, you can do:

$ easy_install scipy
$ easy_install matplotlib

This might take longer, since scipy will also compile different things.


There are three ways of installing PyBrain: you can either go with our stable release on the webpage or the bleeding edge from our git repository.

To check out the PyBrain repository run:

$ git clone git:// pybrain

If you are unfamiliar with git, there is also a direct download to the latest version here.

Change into the directory Pybrain directory after either checking out got or downloading and extracting the archive. There you run (possibly as a superuser on Unix systems):

$ python install

Now everything should be installed. To test if it works fine, go into Python and import PyBrain. You should see something like this:

$ python
Python 2.5.2 (r252:60911, Sep 17 2008, 11:21:23)
[GCC 4.0.1 (Apple Inc. build 5465)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import pybrain

If this works, you are set.

Table Of Contents

Previous topic

Welcome to PyBrain’s documentation!

Next topic

Building a Network

This Page