Execute and options reference¶
The formal specification for the
is as follows.
This is the main flagging function that is to be implemented by the flagging script. AOFlagger will look for the global
executefunction, and call this when data is available to be flagged. It is possible to give this function a different name, or have multiple functions by changing the defaults in
On input, the
dataoption contains the visibility data and the current flag mask. The object’s interface is described by the
Dataclass. The task of the
executefunction is to modify this data object.
The command line aoflagger program will go through a measurement set, call
executefor each baseline and save the resulting flag mask. The visibilities themselves are not written back to the measurement set, so any changes to them (e.g. by
low_pass_filter()) will not change the data on disk.
It is fine for the
executefunction to set global parameters. Note however that, when
executeis called by
aoflagger, different calls to
executemight run within a different Lua context. Every thread is assigned its own Lua context.
Data) – Single-baseline data to be flagged
This special function is called by
aoflaggerto obtain options that are relevant for the strategy (or strategies).
It should return a table for which each entry in the table maps a label to an option list. An option list is a table itself, mapping option names to their values. Any option that is not set, is left to its default.
Options on the command line override options that are set by the strategy for all runs defined. The
optionsfunction is optional: if it is not defined, all options are left to their defaults. Available options can be found on the list of options.
An option list
- Return type: