suncasa.utils.mstools
Attributes
Functions
|
get center frequencies of all spectral windows for msfile |
|
get beamsize at frequencies definded by cfreq based on refbmsize at reffreq |
|
|
|
|
|
Clears history in the a measurement sets file |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Sort the polarization order in a measurement set to match the conventional order (XX, XY, YX, YY). |
Module Contents
- suncasa.utils.mstools.get_bandinfo(msfile, spw=None, returnbdinfo=False, verbose=False)[source]
get center frequencies of all spectral windows for msfile spw: [option] return the cfreq of spw. spw can be a a string or a list of string. The syntax of spw follows the standard spw Parameter in CASA if spw is not provided, return the cfreq of all spws in the msfile. return cfreqs is in GHz if returnbounds is True, return a dictionary including comprehensive freq information of the ms.
- suncasa.utils.mstools.get_bmsize(cfreq, refbmsize=70.0, reffreq=1.0, minbmsize=4.0)[source]
get beamsize at frequencies definded by cfreq based on refbmsize at reffreq cfreq: input frequencies at GHz refbmsize: reference beam size in arcsec reffreq: reference frequency in GHz minbmsize: minimum beam size in arcsec
- suncasa.utils.mstools.msclearhistory(msfile)[source]
Clears history in the a measurement sets file
- Parameters:
msfile – string The name of a measurement sets file
- Returns:
- suncasa.utils.mstools.clearflagrow(msfile, mode='clear')[source]
- Parameters:
msfile
mode – FLAG_ROW operation
- default: ‘clear’: (default) clear the FLAG_ROW
‘list’: to list existing FLAG_ROW
- Returns:
- suncasa.utils.mstools.gaincalXY(vis=None, caltable=None, pols='XXYY', msfileXY=None, gaintableXY=None, **kwargs)[source]
- suncasa.utils.mstools.sort_polarization_order(msfile, outputvis)[source]
Sort the polarization order in a measurement set to match the conventional order (XX, XY, YX, YY).
- Parameters:
msfile (str (optional)) – Path to the input measurement set file. defaults to None
outputvis (str (optional)) – Path to the output measurement set file where the sorted data will be stored. defaults to None
- Raises:
OSError – If the output file cannot be created or copying fails.
Exception – If an error occurs while processing the CASA tables.
- Returns:
None
- Return type:
None