No project description provided
Project description
FixMS
WARNING FOR USERS: These scripts are still being verified for complete correctness. Please use at your own risk.
ASKAP utilities for updating MeasurementSets for external imagers.
ASKAP MSs are produced in a way that breaks compatibility with most other imagers (e.g. CASA, WSclean). Here we provide two modules (with CLI hooks) that perform the fixes that need to be applied in order to produce astronomically correct imagers with non-YandaSoft imagers:
-
fix_ms_dir
: ASKAP MeasurementSets are phased towards the centre of field, but not the centre of its given beam. This utility reads the appropriate offsets to the beam centre from theBEAM_OFFSET
and updates theFIELD
table, as well as the phase and delay reference columns. An option is also available to restore theFIELD
table directions to the original directions iffix_ms_dir
has already been run.BEAM_OFFSET
is also restored with this option. -
fix_ms_corrs
: ASKAP MeasurementSets, as calibrated by the obervatory, provide correlations in the instrument frame. ASKAP has a unique 'roll' axis which means, in principle, the instrument frame can be at any arbitrary rotation on the sky. This utility applies the appropriate rotation matrix to the visibilities such the 'X' is aligned North-South and 'Y' is aligned East-West (IAU convention). Further, ASKAPsoft defines Stokes I as $I=XX+YY$, whereas most other telescopes use $I=\frac{1}{2}(XX+YY)$ (note this also applies to all other Stokes paramters). This factor is also corrected for here at the same time as the rotation. If you have calibrated with non-ASKAPsoft tools, you may need to use the--no-fix-stokes-factor
option, which will disable the factor of two correction and just do a rotation.
For convenience, we also provide fix_ms
which does both of the above!
Full documentation on Read The Docs.
Installation
Obtain and install Python 3 (I recommend Miniforge or Miniconda).
Install the Python scripts:
Latest:
pip install git+https://github.com/AlecThomson/FixMS.git
Stable:
pip install FixMS
Usage
❯ fix_ms -h
usage: fix_ms [-h] [--chunksize CHUNKSIZE] [--data-column DATA_COLUMN] [--corrected-data-column CORRECTED_DATA_COLUMN] [ms]
Utility to correct the ASKAP beam positions and apply a rotation to apply a change of the reference frame of the visibilities
positional arguments:
ms Measurement set to update (default: None)
options:
-h, --help show this help message and exit
--chunksize CHUNKSIZE
The chunksize to use when reading the MS (default: 1000)
--data-column DATA_COLUMN
The column to fix (default: DATA)
--corrected-data-column CORRECTED_DATA_COLUMN
The column to write the corrected data to (default: CORRECTED_DATA)
❯ fix_ms_corrs -h
usage: fix_ms_corrs [-h] [--chunksize CHUNKSIZE] [--data-column DATA_COLUMN] [--corrected-data-column CORRECTED_DATA_COLUMN] ms
Fix the correlation rotation of ASKAP MSs. Converts the ASKAP standard correlations to the 'standard' correlations This will make them compatible with most imagers (e.g. wsclean, CASA) The new correlations are placed in a new column called 'CORRECTED_DATA'
positional arguments:
ms The MS to fix
options:
-h, --help show this help message and exit
--chunksize CHUNKSIZE
The chunksize to use when reading the MS (default: 1000)
--data-column DATA_COLUMN
The column to fix (default: DATA)
--corrected-data-column CORRECTED_DATA_COLUMN
The column to write the corrected data to (default: CORRECTED_DATA)
❯ fix_ms_dir -h
usage: fix_ms_dir [-h] [ms]
ASKAP utility - update the pointing centre of a beam in an MS. - Allows imaging by CASA or wsclean.
positional arguments:
ms Measurement set to update (default: None)
options:
-h, --help show this help message and exit
-r, --restore Switch to restore direction to the original ASKAPsoft pipeline direction. (default: False)
Contribution
Contributions are very welcome! Please open an issue first to discuss any bugs or updates you might have.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file fixms-0.2.2.tar.gz
.
File metadata
- Download URL: fixms-0.2.2.tar.gz
- Upload date:
- Size: 14.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.7.1 CPython/3.11.0 Linux/6.2.0-1019-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c9f2252c8adfaed8c7833251c24e1deea8eef35803c30b5708753edc1f90df26 |
|
MD5 | 567be5042dbd69e7eabdc655d1642579 |
|
BLAKE2b-256 | 4da50feaadc8f41d379642ca7873a55ef05240df365b14ed585bbea802e7c3a1 |
File details
Details for the file fixms-0.2.2-py3-none-any.whl
.
File metadata
- Download URL: fixms-0.2.2-py3-none-any.whl
- Upload date:
- Size: 16.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.7.1 CPython/3.11.0 Linux/6.2.0-1019-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3ed847311856c0d30e8ebd83de865a5b512d8cb9e46684c295fd4df4580b15dc |
|
MD5 | 171c9e91ebc18c46d5e4c9fdf0754f6b |
|
BLAKE2b-256 | 90e4d24240e15eeb1062ad180d68c97848cfd7421dbee49e0528fc571d0379ba |