Astronomical Interferometry in PYthon (AIPY)

maintained by Aaron Parsons

This package collects together tools for radio astronomical interferometry. In addition to pure-python implementations of phasing, calibration, imaging, and deconvolution code, this package include interfaces to MIRIAD (a Fortran interferometry package), and routines from SciPy for fitting and interpolation.

The primary driver for this software is the Precision Array for Probing the Epoch of Reionization (PAPER), an experiment for detecting the first stars and galaxies that formed in the universe via the effect of their radiation on intergalactic hydrogen. This experiment presents many new challenges, including widefield imaging, non-tracking antennas, high data-rates, a large fractional bandwidth, and power-spectrum detection.


Download

If you have setuptools and numpy is already installed, then with root permissions, you can just type:

easy_install aipy
Otherwise, you may download from pypi.python.org, or from a local snapshot.

Dependencies

This is a *nix package. With some trouble it can install on MacOS, and it pretty certainly doesn't install on Windows. You need to have python >= 2.4. AIPY depends of the following python packages:

numpy >= 1.0.4
pyephem >= 3.7.2.3
pyfits >= 1.1
*matplotlib >= 0.91
*matplotlib-basemap >= 0.9
(* installation can occur without these, but some scripts will choke)
Luckily, much of this is now automated through setuptools dependencies, but you have to have network access to take advantage of it.
OPTION 1: Install the dependencies yourself.
OPTION 2: With network connectivity and root access, type:
install_dependencies.sh

Installation

If you used easy_install above, everything is taken care of. Otherwise, you may manually download the package above and then run (with root permission):

python setup.py install
If any of the dependencies fails to install, you should download the package source and build it manually. For instructions on installing without root permission, read the FAQ.

Resources

There is a Tutorial (PDF) available, as well as online code documentation. If you have an questions, you can try the FAQ before emailing me at: aparsons at astron berkeley edu.


Recommended Additional Packages

IPython Provides a slick interactive command-line interface.
SciPy Provides general-purpose math, signal processing, fitting, and general science stuff.

Information for Developers

The subpackage "optimize" was copied in from scipy-0.6.0, and then all code that depended on non-pure-python modules was removed. If these ever need to be updated, download scipy source and copy scipy/scipy/optimize into aipy, and then remove any code deemed unnecessary. Unfortunately, then you may need to crawl through the code and replace all "scipy" references with "aipy".

The miriad source code (aipy/miriad/mirsrc) was included from MIRIAD-4.0.5. To update, download miriad source and copy $MIR/src/subs/* and $MIR/src/inc/* into aipy/miriad/mirsrc. Not all files are used, but include them all anyway.

Healpix source code (aipy/healpix/cxx) was included from Healpix-2.01. To update, download healpix source and copy src/cxx into aipy/healpix.