The regions package requires the following packages:

  • Python 3.6 or later

  • Numpy 1.16 or later

  • Astropy 2.0 or later

In addition, the following packages are needed for optional functionality:

Stable version

Installing the latest stable version is possible either using pip or conda.

Using pip

To install regions with pip from PyPI, run:

pip install regions --no-deps


The --no-deps flag is optional, but highly recommended if you already have Numpy installed, since otherwise pip will sometimes try to “help” you by upgrading your Numpy installation, which may not always be desired.

Using conda

To install regions with Anaconda, simply run:

conda install -c conda-forge regions

Testing installation

To check if there are any issues with your installation, you can run the tests:

python -c 'import regions; regions.test()'

Development version

Install the latest development version from :

git clone
cd regions
python install

To run the tests, you will need to make sure the pytest-arraydiff package is installed (version v0.3 or newer). Then, run the tests with:

python test

To build the documentation, do:

python build_docs