Source
1
-
<casaxml xsi:schemaLocation="http://casa.nrao.edu/schema/casa.xsd file:///opt/casa/code/xmlcasa/xml/casa.xsd" xmlns="http://casa.nrao.edu/schema/psetTypes.html" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
2
-
3
-
<task type="function" name="initweights" category="calibration">
4
-
<shortdescription>Initializes weight information in the MS</shortdescription>
5
-
6
-
<input>
7
-
<param type="path" name="vis" mustexist="true"><shortdescription>Name of input visibility file (MS)</shortdescription><description>Name of input visibility file (MS)</description>
8
-
9
-
<value/>
10
-
</param>
11
-
<param type="string" name="wtmode"><shortdescription>Initialization mode</shortdescription><description>Initialization mode</description>
12
-
13
-
<value>nyq</value>
14
-
<allowed kind="enum">
15
-
<value>nyq</value>
16
-
<value>sigma</value>
17
-
<value>weight</value>
18
-
<value>ones</value>
19
-
<value>delwtsp</value>
20
-
<value>delsigsp</value>
21
-
<value>tsys</value>
22
-
<value>tinttsys</value>
23
-
</allowed>
24
-
</param>
25
-
<param type="path" name="tsystable" mustexist="false" subparam="true"><shortdescription>Tsys calibration table to apply on the fly</shortdescription><description>Tsys calibration table to apply on the fly</description>
26
-
27
-
<value/>
28
-
</param>
29
-
30
-
<param type="string" name="gainfield" subparam="true"><shortdescription>Select a subset of calibrators from Tsys table</shortdescription><description>Select a subset of calibrators from Tsys table</description>
31
-
32
-
<value/>
33
-
</param>
34
-
35
-
<param type="string" name="interp" subparam="true"><shortdescription>Interpolation type in time[,freq]. default==\'linear,linear\'</shortdescription><description>Interpolation type in time[,freq]. default==\'linear,linear\'</description>
36
-
37
-
<value/>
38
-
</param>
39
-
40
-
<param type="intVec" name="spwmap" subparam="true"><shortdescription>Spectral windows combinations to form for gaintable(s)</shortdescription><description>Spectral windows combinations to form for gaintable(s)</description>
41
-
42
-
<value/>
43
-
</param>
44
-
45
-
<param type="bool" name="dowtsp"><shortdescription>Initialize the WEIGHT_SPECTRUM column</shortdescription><description>Initialize the WEIGHT_SPECTRUM column</description>
46
-
47
-
<value>False</value>
48
-
</param>
49
-
50
-
<constraints>
51
-
<when param="wtmode">
52
-
<equals value="nyq"/>
53
-
<equals value="sigma"/>
54
-
<equals value="weight"/>
55
-
<equals value="ones"/>
56
-
<equals value="delwtsp"/>
57
-
<equals value="delsigsp"/>
58
-
<equals value="tsys">
59
-
<default param="tsystable"><value type="string"/></default>
60
-
<default param="gainfield"><value type="string"/></default>
61
-
<default param="interp"><value type="string"/></default>
62
-
<default param="spwmap"><value type="intVec"/></default>
63
-
</equals>
64
-
<equals value="tinttsys">
65
-
<default param="tsystable"><value type="string"/></default>
66
-
<default param="gainfield"><value type="string"/></default>
67
-
<default param="interp"><value type="string"/></default>
68
-
<default param="spwmap"><value type="intVec"/></default>
69
-
</equals>
70
-
</when>
71
-
</constraints>
72
-
</input>
73
-
<returns type="void"/>
74
-
75
-
<example>
76
-
77
-
This task provides for initialization of the weight information
78
-
in the MS. For ALMA interferometry and EVLA data, it should not
79
-
generally be necessary to use this task, as the per-spectral window
80
-
weight information should have been initialized properly at
81
-
fill time (v4.2.2 and later). To set per-channel weights, use
82
-
initweights(vis=finalvis,wtmode='weight',dowtsp=True)
83
-
84
-
Several initialization modes are supported via the wtmode parameter.
85
-
86
-
If wtmode='nyq' (the default), SIGMA and WEIGHT will be
87
-
initialized according to bandwidth and integration time. This
88
-
is the theoretically correct mode for raw normalized visibilities.
89
-
(e.g., ALMA). For the EVLA, this is correct if switched-power
90
-
and bandpass calibration will later be applied.
91
-
92
-
If wtmode='sigma', WEIGHT will be initialized according to the
93
-
existing SIGMA column.
94
-
95
-
If wtmode='weight', WEIGHT_SPECTRUM will be initialized according
96
-
to the existing WEIGHT column; dowtspec=T must be specified in
97
-
this case.
98
-
99
-
If wtmode='ones', SIGMA and WEIGHT will be initialized with 1.0,
100
-
globally. This is a traditional means of initializing weight
101
-
information, and is adequate when the integration time and
102
-
bandwidth are uniform. It is not recommended for modern
103
-
instruments (ALMA, EVLA), where variety in observational setups
104
-
is common, and properly initialized and calibrated weights
105
-
will be used for imaging sensitivity estimates.
106
-
107
-
There are two EXPERIMENTAL modes, wtmode='tsys' and 'tinttsys'.
108
-
In the modes, SIGMA and WEIGHT will be initialized according to
109
-
Tsys, bandwidth, and integration time (used only in 'tinttsys'),
110
-
i.e.,
111
-
tsys : weight=bw/Tsys^2
112
-
tinttsys: weight=bw*t_int/Tsys^2
113
-
These modes use Tsys values to calculate weight as is done in
114
-
Tsys calibration. Tsys values are taken from a tsys calibration
115
-
table given as tsystable. Selection of gain field (gainfield),
116
-
interpolation method (interp), and spectral window mapping (spwmap)
117
-
are supported, too.
118
-
Available types of interpolation are,
119
-
Time: 'nearest', 'linear', the variation of those with 'perobs',
120
-
e.g., 'linearperobs' (enforce obsId boundaries in interpolation)
121
-
Freq: 'nearest', 'linear', 'cubic', 'spline', and the variation
122
-
of those with 'flag', e.g., 'linearflag' (with
123
-
channelized flag).
124
-
See the help of applycal for details of interpolations.
125
-
Note if the weight in an MS is initialized with these modes and
126
-
Tsys calibration table is applied with calwt=True after that, the
127
-
weight would be contaminated by being devided by square of Tsys
128
-
twice.
129
-
!!! USERS ARE ADVISED TO USE THESE EXPERIMENTAL MODES WITH CARE !!!
130
-
131
-
For the above wtmodes, if dowtsp=T (or if the WEIGHT_SPECTRUM
132
-
column already exists), the WEIGHT_SPECTRUM column will be
133
-
initialized (uniformly in channel in wtmode='nyq', 'sigma',
134
-
'weight', and 'ones'), in a manner consistent with the
135
-
disposition of the WEIGHT column. If the WEIGHT_SPECTRUM
136
-
column does not exist, dowtsp=T will force its creation.
137
-
Use of the WEIGHT_SPECTRUM column is only meaningful
138
-
for ALMA data which will be calibrated with channelized
139
-
Tsys information, or if the weights will become channelized
140
-
after calibration, e.g., via averaging over time- and
141
-
channel-dependent flagging. (A task for channel-dependent
142
-
weight estimation from the data itself is also currently under
143
-
development).
144
-
In non-channelized modes (wtmode='nyq', 'sigma', 'weight', and
145
-
'ones') or when dowtsp=F, SIGMA_SPECTRUM column will be removed
146
-
from MS. On the other hand, SIGMA_SPECTRUM column is added and
147
-
initialized in channelized modes (wtmode='tsys' and 'tinttsys')
148
-
if dowtsp=T or WEIGHT_SPECTRUM already column exists.
149
-
150
-
Two additional modes are available for managing the spectral
151
-
weight info columns; these should be used with extreme care: If
152
-
wtmode='delwtsp', the WEIGHT_SPECTRUM column will be deleted (if
153
-
it exists). If wtmode='delsigsp', the SIGMA_SPECTRUM column
154
-
will be deleted (if it exists). Note that creation of
155
-
SIGMA_SPECTRUM is not supported via this method.
156
-
157
-
Note that this task does not support any prior selection.
158
-
Intialization of the weight information must currently be done
159
-
globally or not at all. This is to maintain consistency.
160
-
161
-
</example>
162
-
</task>
163
-
</casaxml>