accor
- accor(vis, caltable='', field='', spw='', intent='', selectdata=True, timerange='', antenna='', scan='', observation='', msselect='', solint='inf', combine='', corrdepflags=False, append=False, docallib=False, callib='', gaintable='', gainfield='', interp='', spwmap='')[source]
Normalize visibilities based on auto-correlations
[Description] [Examples] [Development] [Details]
- Parameters
vis (path) - Name of input visibility file
caltable (string=’’) - Name of output gain calibration table
field (string=’’) - Select field using field id(s) or field name(s)
spw (string=’’) - Select spectral window/channels
intent (string=’’) - Select observing intent
selectdata (bool=True) - Other data selection parameters
selectdata = True
timerange (string=’’) - Select data based on time range
antenna (string=’’) - Select data based on antenna/baseline
scan (string=’’) - Scan number range
observation ({string, int}=’’) - Select by observation ID(s)
msselect (string=’’) - Optional complex data selection (ignore for now)
solint (variant=’inf’) - Solution interval: egs. 'inf', '60s' (see help)
combine (string=’’) - Data axes which to combine for solve (obs, scan, spw, and/or field)
corrdepflags (bool=False) - Respect correlation-dependent flags
append (bool=False) - Append solutions to the (existing) table
docallib (bool=False) - Use callib or traditional cal apply parameters
docallib = False
gaintable (stringVec=’’) - Gain calibration table(s) to apply on the fly
gainfield (stringVec=’’) - Select a subset of calibrators from gaintable(s)
interp (stringVec=’’) - Interpolation parameters for each gaintable, as a list
spwmap (any=’’) - Spectral windows combinations to form for gaintables(s)
docallib = True
callib (string=’’) - Cal Library filename
- Description
accor determines the amplitude calibration from auto-correlations.
The accor task determines the amplitude corrections from the apparent normalization of the mean autocorrelation spectra. Mis-normalization of the autocorrelations (and thus also the cross-correlations) is caused by errors in sampler thresholds during an observation. This correction is typically required for data correlated with the DiFX correlator (such as VLBA data). Other correlators (such as the SFXC correlator, which is used to correlate EVN data at JIVE) may already apply this correction at the correlator. In these cases, running this task is not necessary (but shouldn’t hurt).
The accor task should be run with a solution interval (solint) adequate to track variations in effective sampler level optimization (including resets), typically on timescales of seconds to minutes.
See Solving for Calibration for more information on the task parameters accor shares with all calibration solving tasks, including data selection, general solving properties, and arranging prior calibration (i.e., specifying other caltables to pre-apply before solving). In most cases, no prior calibration is required, since the raw mis-normalization of the autocorrelations is essentially the calibration sought from accor.
- Examples
The following example creates a caltable with accor solutions on a 30s timescale.
accor(vis='data.ms', caltable='cal.A', solint='30s')
- Development
No additional development details
- Parameter Details
Detailed descriptions of each function parameter
vis (path)
- Name of input visibility filedefault: noneexample: vis=’ngc5921.ms’caltable (string='')
- Name of output gain calibration tabledefault: noneexample: caltable=’ngc5921.gcal’field (string='')
- Select field using field id(s) or field name(s)default: ‘’ –> all fieldsUse ‘go listobs’ to obtain the list id’s ornames. If field string is a non-negative integer,it is assumed a field index, otherwise, it isassumed a field name.Examples:field=’0~2’; field ids 0,1,2field=’0,4,5~7’; field ids 0,4,5,6,7field=’3C286,3C295’; field named 3C286 and3C295field = ‘3,4C*’; field id 3, all namesstarting with 4CNote: do not forget to include the flux densitycalibrator if you have one!spw (string='')
- Select spectral window/channelsExamples:spw=’0~2,4’; spectral windows 0,1,2,4 (allchannels)spw=’<2’; spectral windows less than 2(i.e. 0,1)spw=’0:5~61’; spw 0, channels 5 to 61,INCLUSIVEspw=’*:5~61’; all spw with channels 5 to 61spw=’0,10,3:3~45’; spw 0,10 all channels, spw3, channels 3 to 45.spw=’0~2:2~6’; spw 0,1,2 with channels 2through 6 in each.spw=’0:0~10;15~60’; spectral window 0 withchannels 0-10,15-60. (NOTE ‘;’ to separatechannel selections)spw=’0:0~10^2,1:20~30^5’; spw 0, channels0,2,4,6,8,10, spw 1, channels 20,25,30type ‘help par.selection’ for more examples.intent (string='')
- Select observing intentdefault: ‘’ (no selection by intent)Example: intent=’*BANDPASS*’ (selects datalabelled with BANDPASS intent)selectdata (bool=True)
- Other data selection parametersdefault: True (Must set selectdata=True to selectother selection parameters.)timerange (string='')
- Select data based on time rangeSubparameter of selectdata=Truedefault = ‘’ (all)Examples:timerange =‘YYYY/MM/DD/hh:mm:ss~YYYY/MM/DD/hh:mm:ss’(Note: if YYYY/MM/DD is missing date defaultsto first day in data set.)timerange=’09:14:0~09:54:0’ picks 40 min onfirst daytimerange= ‘25:00:00~27:30:00’ picks 1 hr to 3hr 30min on NEXT daytimerange=’09:44:00’ pick data within oneintegration of timetimerange=’>10:24:00’ data after this timeantenna (string='')
- Select data based on antenna/baselineSubparameter of selectdata=Truedefault: ‘’ (all)Examples:antenna=’5&6’; baseline between antennaindex 5 and index 6.antenna=’VA05&VA06’; baseline between VLAantenna 5 and 6.antenna=’5&6;7&8’; baselines withindices 5-6 and 7-8antenna=’5’; all baselines with antenna index5antenna=’05’; all baselines with antennanumber 05 (VLA old name)antenna=’5,6,10’; all baselines with antennas5,6,10 index numbersNote: just for antenna selection, an integer (orinteger list) is converted to a string andmatched against the antenna ‘name’ first. Only ifthat fails, the integer is matched with theantenna ID. The latter is the case for mostobservatories, where the antenna name is notstrictly an integer.scan (string='')
- Scan number rangeSubparameter of selectdata=Truedefault: ‘’ = allCheck ‘go listobs’ to insure the scan numbers arein order.observation ({string, int}='')
- Select by observation ID(s)Subparameter of selectdata=Truedefault: ‘’ = allExample: observation=’0~2,4’msselect (string='')
- Optional complex data selection (ignore for now)solint (variant='inf')
- Solution interval (units optional)default: ‘inf’ (~infinite, up to boundariescontrolled by combine)Options: ‘inf’ (~infinite), ‘int’ (perintegration), any float or integer value with orwithout unitsExamples: solint=’1min’; solint=’60s’;solint=60 –> 1 minutesolint=’0s’; solint=0; solint=’int’ –> perintegrationsolint-‘-1s’; solint=’inf’ –> ~infinite, upto boundaries -interacts with combinecombine (string='')
- Data axes which to combine for solvedefault: ‘’ (solutions will break at obs, scan,field, and spw)Options: ‘’,’obs’,’scan’,’spw’,field’, or anycomma-separated combination in a single stringFor gaintype=’K’, if combine includes ‘spw’,multi-band delays will be determined; otherwise,(per-spw) single-band delays will be determined.Example: combine=’scan,spw’ (extend solutionsover scan boundaries)corrdepflags (bool=False)
- If False (default), if any correlation is flagged, treat all correlations inthe visibility vector as flagged when solving (per channel, per baseline).If True, use unflagged correlations in a visibility vector, even if one or moreother correlations are flagged.Default: False (treat correlation vectors with one or more correlations flagged as entirely flagged)Traditionally, CASA has observed a strict interpretation ofcorrelation-dependent flags: if one or more correlations(for any baseline and channel) is flagged, then all availablecorrelations for the same baseline and channel aretreated as flagged. However, it is desirable in somecircumstances to relax this stricture, e.g., to preserve useof data from antennas with only one good polarization (e.g., one polarizationis bad or entirely absent). Solutions for the bad or missing polarizationwill be rendered as flagged.append (bool=False)
- Append solutions to the (existing) tabledefault: False (overwrite existing table or makenew table)Appended solutions must be derived from the sameMS as the existing caltable, and solution spwsmust have the same meta-info (according to spwselection and solint) or be non-overlapping.docallib (bool=False)
- Control means of specifying the caltablesdefault: False –> Use gaintable, gainfield,interp, spwmap, calwt.If True, specify a file containing cal library incallibcallib (string='')
- Cal Library filenameSubparameter of callib=TrueIf docallib=True, specify a file containing callibrary directivesgaintable (stringVec='')
- Gain calibration table(s) to apply on the flySubparameter of callib=Falsedefault: ‘’ (none)Examples: gaintable=’ngc5921.gcal’gaintable=[‘ngc5921.ampcal’,’ngc5921.phcal’]gainfield (stringVec='')
- Select a subset of calibrators from gaintable(s)Subparameter of callib=Falsedefault:’’ –> all sources in tablegaintable=’nearest’ –> nearest (on sky)available field in table. Otherwise, same syntaxas fieldExamples:gainfield=’0~2,5’ means use fields 0,1,2,5from gaintablegainfield=[‘0~3’,’4~6’] means use field 0through 3 from first gain file, field 4through 6 for second.interp (stringVec='')
- Interpolation parmameters (in time[,freq]) for each gaintable, as a list of strings.Default: ‘’ –> ‘linear,linear’ for all gaintable(s)Options: Time: ‘nearest’, ‘linear’Freq: ‘nearest’, ‘linear’, ‘cubic’,‘spline’Specify a list of strings, aligned with the list of caltable specifiedin gaintable, that contain the required interpolation parametersfor each caltable.- When frequency interpolation is relevant (B, Df,Xf), separate time-dependent and freq-dependentinterp types with a comma (freq_after_ thecomma).- Specifications for frequency are ignored when thecalibration table has no channel-dependence.- Time-dependent interp options ending in ‘PD’enable a “phase delay” correction per spw fornon-channel-dependent calibration types.- For multi-obsId datasets, ‘perobs’ can beappended to the time-dependent interpolationspecification to enforce obsId boundaries wheninterpolating in time.- For multi-scan datasets, ‘perscan’ can beappended to the time-dependent interpolationspecification to enforce scan boundaries wheninterpolating in time.- Freq-dependent interp options can have ‘flag’ appendedto enforce channel-dependent flagging, and/or ‘rel’appended to invoke relative frequency interpolationExamples:interp=’nearest’ (in time, freq-dep will belinear, if relevant)interp=’linear,cubic’ (linear in time, cubicin freq)interp=’linearperobs,splineflag’ (linear intime per obsId, spline in freq withchannelized flagging)interp=’nearest,linearflagrel’ (nearest intime, linear in freq with with channelizedflagging and relative-frequency interpolation)interp=’,spline’ (spline in freq; linear intime by default)interp=[‘nearest,spline’,’linear’] (formultiple gaintables)spwmap (any='')
- Spectral windows combinations to form for gaintables(s)Subparameter of callib=Falsedefault: [] (apply solutions from each spw tothat spw only)Examples:spwmap=[0,0,1,1] means apply the caltablesolutions from spw = 0 to the spw 0,1 and spw1 to spw 2,3.spwmap=[[0,0,1,1],[0,1,0,1]]