woden_uv2ms.py¶
Helper script to convert uvfits files to measurement sets using pyuvdata.
Command line running options¶
Script to transform uvfits filesinto measurement sets. Uses same name of uvfits for the output measurement set
usage: woden_uv2ms.py [-h] [--single_uvfits SINGLE_UVFITS]
[--uvfits_prepend UVFITS_PREPEND]
[--band_nums BAND_NUMS] [--no_delete]
Named Arguments¶
- --single_uvfits
Convert this single uvfits file into a measurement set e.g. –single_uvfits=./data/nice_uvfits_band01.uvfits
Default:
False- --uvfits_prepend
- Use in conjunction with –band_nums to process multiple uvfits files, where ‘{:02d}.uvfits’.format(band_num) is tacked onto the end of –uvfits_prepend. For example, setting:
–uvfits_prepend=example_band –band_nums=1,2
will tranform both example_band01.uvfits and example_band02.uvfits
Default:
False- --band_nums
Add these numbers to the end of –uvfits_prepend to convert multiple uvfits files. Alternatively, enter required numbers delineated by commas, e.g. –band_nums=1,7,9
Default:
'all'- --no_delete
Defaults to deleting a measurement set with the destination name of the measurement set to be written. by commas, e.g. –band_nums=1,7,9
Default:
False
Function documentation¶
Script to use pyuvdata to convert uvfits files to measurement sets`
- woden_uv2ms.get_parser()[source]¶
Runs the argument parser to get command line inputs - used by sphinx and argparse extension to unpack the help below into the online readthedocs documentation.
- Returns:
parser – The populated argument parser used by uv2ms.py
- Return type:
argparse.ArgumentParser
- woden_uv2ms.main()[source]¶
Converts UVFITS files to Measurement Sets (MS) using WODEN.
Usage: python woden_uv2ms.py –single_uvfits <filename> [–no_delete] python woden_uv2ms.py –uvfits_prepend <filename_prefix> –band_nums <band_numbers> [–no_delete]
Arguments: –single_uvfits <filename> : Convert a single UVFITS file to an MS. –uvfits_prepend <filename_prefix> : Convert multiple UVFITS files to MSs, where <filename_prefix> is the prefix of the UVFITS files. –band_nums <band_numbers> : Comma-separated list of band numbers to convert. Default is all bands (1-24). –no_delete : Do not delete intermediate files.
Example usage: python woden_uv2ms.py –single_uvfits example.uvfits python woden_uv2ms.py –uvfits_prepend example_ –band_nums 1,3,5 –no_delete