Skip to main content

An interface layer for scripting the AMI-Reduce pipeline.

Project description

A python package for scripting the AMI-reduce pipeline.

For a full description, see Staley and Anderson (in prep). If you use drive-ami in work leading to a publication, we ask that you cite the paper above, and the relevant ASCL entry.

Rationale

From a radio astronomy point of view:

This package makes it trivial to script reduction of raw AMI data from python. What’s more, it provides tools to group the raw files into datasets, outputting the UVFITS for each dataset under a single folder. It does this by extracting the pointing information from the raw data, resulting in fairly reliable groupings (although you can edit these manually, see later).

When processing the data, all output from reduce is saved to an accompanying log-file, retaining all information that would normally be available to the user from the interactive interface. Meanwhile, all emulated commands passed to reduce are recorded in a separate log for each file processed, so it’s easy to re-run the script manually and tinker with the reduction process.

Additionally, when running commands listed in a script the interface quietly parses key information such as flagging percentages, rain modulation, and estimated noise, from the reduce output. These are then stored to disk alongside the UVFITs in easily machine readable JSON format. (These may also be added to the UVFITS header in future.)

From a software engineering point of view:

Written in Fortran, with an interactive terminal interface, the reduce pipeline takes a little coaxing to co-operate with calling scripts, making automated processing of large numbers of files tricky. Fortunately, the python library pexpect provides an easy mechanism to emulate human interaction, upon which I’ve built an interface class. Limitations such as a maximum path length of ~32 chars are circumvented with a few careful hacks. The python logging libraries then allow us provide the user with minimal progress information, whilst retaining all possible information for debugging and scientific evaluation.

Installation

Requirements:
  • You will need a working installation of AMI-reduce (naturally)

  • pexpect For interfacing with AMI-reduce. (Installed automatically as part of the python setup.)

  • astropy Used for calculating co-ordinate distances, etc. (Installed automatically as part of the python setup.)

From the command line (preferably within a virtualenv):

git clone git://github.com/timstaley/drive-ami.git
cd drive-ami
pip install numpy #Workaround for buggy scipy/numpy combined install.
pip install .

Usage

Command-line scripts are installed along with the package. Their sourcefiles can be found at https://github.com/timstaley/drive-ami/tree/master/bin. For full details, run e.g.:

driveami_list_rawfiles.py -h

Where -h is short for ‘help’.

Typical usage is to run driveami_list_rawfiles.py to build a full listing of available data, followed by driveami_filter_rawfile_listing.py to extract the entries on a desired target. Finally, driveami_calibrate_rawfiles.py actually does the processing using AMI-REDUCE.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

drive-ami-0.9.0.tar.gz (14.3 kB view details)

Uploaded Source

Built Distribution

drive-ami-0.9.0.linux-x86_64.tar.gz (23.4 kB view details)

Uploaded Source

File details

Details for the file drive-ami-0.9.0.tar.gz.

File metadata

  • Download URL: drive-ami-0.9.0.tar.gz
  • Upload date:
  • Size: 14.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for drive-ami-0.9.0.tar.gz
Algorithm Hash digest
SHA256 c93a732acb9d974f7882c6d7c42e77cc5ed36320fb4c0fe46cefcccb2291720f
MD5 6d9fbefebde53f4a3b10cda5fbb0a92f
BLAKE2b-256 cfc9927bc201e69ec5e5948882124d13d229018c247a30cf07ffedb08f743901

See more details on using hashes here.

File details

Details for the file drive-ami-0.9.0.linux-x86_64.tar.gz.

File metadata

File hashes

Hashes for drive-ami-0.9.0.linux-x86_64.tar.gz
Algorithm Hash digest
SHA256 59e3c4099f678197d7791fd04d22be02ca808d42e826d89d0563dd2afb4eeb99
MD5 d320a488fed81253a33042510bfb58d4
BLAKE2b-256 1db54f81b0d22c03b7a9976a4d3866d47e89d20d0f5d5a1e40dc7344b02f9cc1

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page