The task tvflag
is akin to the AIPS SPFLG: it
displays, on a TV device, one baseline at a time, the amplitude or phase
(or amplitude or phase difference from a running average computed over
some time). Task tvflag
will cycle over the set of baselines
present, displaying each one, and giving you the opportunity to flag each
Interactive Channel/Baseline Flagging - TVFLAG
is the last useful remnant of the ``TV'' suite of software
(an old package of display software within Miriad), which uses two X-windows based tools,
xpanel, for displaying. You will need to start up
these tools before using tvflag. To start these, use commands
% xmtv &
% xpanel &
in a terminal window of your local workstation (which need not be the machine
that you are running tvflag
To use these, you first have to ensure that you are correctly
setup to use X-windows programs - see Chapter 3 for more
information on using X-windows. Using xmtv and xpanel is simple
enough when you can run them on your local workstation.
If you have to run
xmtv and xpanel from a compute server (e.g. the situation in
Narrabri, when using kaputar via an NT workstation), then there can be problems
arising from multiple users attempting to allocate a given TCP/IP port. See
Appendix E for more information.
The input parameters to tvflag
are pretty straightforward. We
mention only the more useful ones:
- vis: The name of the visibility data-set to be flagged.
- server: The TV server parameter. This may seem a rather redundant
parameter. It is a parameter of the form
Here host is
the host name of the workstation running xmtv and xpanel
indicates that xmtv and xpanel are running on the machine
There is no default to this parameter, however a value of
will be adequate when you are running tvflag, xmtv and xpanel
all on the one machine.
- select: The usual visibility data selection parameter. One of
tvflag's odd characteristics is in its handling of different
polarizations. Task tvflag
can deal with only a single polarization
per run. If it finds that the input data-set contains several polarizations,
it will average these together when forming its display. While unusual, this
is moderately useful. Assuming the data-set contains all four linear
will produce a Stokes-I display. On the other hand, no selection (i.e.
to average XX, YY, XY and YX)
will produce a quantity which is not physically meaningful, but will still
allow you to make a quick check for interference and outliers.
- line: The normal visibility linetype parameter. Task tvflag
does not support spectral averaging.
- mode: This determines the quantity to be displayed. Possibilities
are amplitude, phase, real and imaginary.
- taver: This gives a time interval used for the running mean
calculation when displaying in ``DIFF'' mode (see below). This parameter
takes two values, both in minutes. The first gives the maximum amount of time
in an averaging interval, whereas the second gives the time gap between records
which causes an averaging interval to be ended. The default is 5 minutes for
both of these.
Typical inputs are:
||Specify visibility dataset
||Specify TV server
||Unset is channel 1 else specify
||Unset for intensity auto-scale
||Unset to centre the image
||Unset for all channels
||Controls the computation of the
||running mean for the DIFF command.
After invoking tvflag, a control panel will pop up
and a baseline of data will be
displayed on the TV. The display shows channels along the x-direction and time
along the y-direction. A gap in time in the data is shown by a dark gap.
A wedge is displayed both above and to the right of the data. The top
wedge is the data averaged over time, whereas the wedge to the right is
the data averaged over the channels.
You now perform flagging operations by pressing ``buttons'' on the
control panel. We review the meaning of some of the buttons:
- SELECT, SLCT CHAN and SLCT TIME: The first thing that you
will normally do is to select some set of data, with one of the three ``select''
buttons. SELECT selects a rectangular region on the display (i.e. some
range of times and channels), whereas SLCT CHAN selects all times
for a particular range of channels, and SLCT TIME selects all channels
for a particular range of times. After pressing the appropriate ``select''
- move the mouse so that the cursor is at one corner of the region to
- depress the left mouse button,
- drag the cursor to the other corner of the region to be selected,
- release the mouse button.
- FLAGOOD and FLAGBAD: Having selected some set of data with
the previous commands, this data can be either flagged as good or bad with
the FLAGOOD and FLAGBAD buttons respectively.
- UNDO: The undo button causes the last flagging command to be undone
- RESCALE: The rescale button changes the display scaling, so that
the data occupies the full greyscale or colour range. If you have some bad data
which has an extremely high amplitude, for example, you will want to flag
this and then rescale the display range so that you can see the detail in the
- DIFF: The ``diff'' button causes a running mean to be subtracted
off the data.
- EXIT, QUIT and ABORT: The ``exit'' button causes the next
baseline to be loaded. The ``quit'' button also causes the next baseline
to be loaded, but discards any flagging commands performed on the current
baseline. Normally tvflag
will terminate when it has gone
through all the baselines. It is only at this stage that it applies
the flagging operations to the actual data-set. Alternately the
``abort'' button causes tvflag
to terminate at any time, and not
to apply any of the flagging operations to the data-set.
- LIST: This button lists the flagging operations that have been
performed to the current baseline.
- VALUE: This button allows you to find the value of pixels
on the display. It is somewhat cumbersome - after pressing the ``value''
button, you move the mouse cursor to the pixel of interest, and press the
[F3] function key. You continue to move the cursor and
[F3] until you have exhausted the pixels of interest. Then
[F6] to return back to tvflag's normal mode.
There are other buttons on the control panel - but we do not suggest that you
use these. They reproduce (rather crudely) buttons on the TV display window.
The useful buttons on the TV display are:
- Panner: Pressing this pops up a window that allows you to pan around the
displayed image, and to fiddle the colour lookup table. The panner window that it
pops up has one of two states - pan and fiddle.
- Luts: This allows you to select a colour lookup table from a small
number of palettes.
- + and -: These allow you to zoom in and out. For mysterious reasons,
these buttons are disabled when the Panner window is in the fiddle state.
- Reset: Reset the zooming, the lookup tables, etc.
- Resize: This allows the size of the display window to be toggled between
full-screen and a more modest size.
- Quit: Hopefully its use is obvious enough!
One shortcoming of tvflag
is that it averages the data in time so that
it will fit on the
display. Unfortunately full time resolution display cannot be recovered. To
display the data at full time resolution, you may need to select the
data in chunks (with select=time()).