The visir_util_repack recipe

visir_util_repack

Synopsis

Conversion of raw CUBE2 or BURST images to on- and off-cubes

Description

The files listed in the Set Of Frames (sof-file) must be tagged: VISIR-CUBE2-raw-file.fits CUBE2 or VISIR-BURST-raw-file.fits BURST VISIR-BURST-bpm-file.fits STATIC_MASK For BURST data it will remove planes where the chopper switched from on <-> off based on the timestamps in the header.

The product(s) will have a FITS card ‘HIERARCH ESO PRO CATG’ with a value of one of: IMG_REPACKED_A_ON (NodPos: A, ChopPos: on) IMG_REPACKED_A_OFF (NodPos: A, ChopPos: off) IMG_REPACKED_B_ON (NodPos: B, ChopPos: on) IMG_REPACKED_B_OFF (NodPos: B, ChopPos: off) For CUBE2, the recipe will produce a static bad-pixel map, it will have a FITS card ‘HIERARCH ESO PRO CATG’ with a value of: STATIC_MASK

Constructor

cpl.Recipe("visir_util_repack")

Create an object for the recipe visir_util_repack.

import cpl
visir_util_repack = cpl.Recipe("visir_util_repack")

Parameters

visir_util_repack.param.planestart

Plane number to start repacking from in each nod cycle,earlier planes are skipped. (int; default: 0) [default=0].

visir_util_repack.param.planelimit

Limit number of processed inputplanes. It will repack until at least this number of input images have been processed or the full dataset has been repacked. Always full chop cycles need to be repacked so the number is adjusted upward to the next multiple of images per chop cycle. <= 0 for no limit. (int; default: -1) [default=-1].

visir_util_repack.param.ncycles

Number of full on-off cycles to repack per nod cycles. <= 0 for all. (int; default: -1) [default=-1].

visir_util_repack.param.trimlow

Burst data only. Number of additional planes to cut from before each plane with chopper movement. (int; default: 0) [default=0].

visir_util_repack.param.trimhigh

Burst data only. Number of additional planes to cut from after each plane with chopper movement. A value of -1 does not skip the plane of the movement. (int; default: 0) [default=0].

visir_util_repack.param.bkgcorrect

Output background corrected planes by subtracting chop (on/off) and nod (A/B) planes Options: none: no correction chop: on - off chopnod: (Aon - Aoff) - (Bon - Boff) (str; default: ‘none’) [default=”none”].

visir_util_repack.param.normalize

Normalize planes by DIT (bool; default: True) [default=True].

visir_util_repack.param.compress

Apply lossless compression on output files. Can only be done for integer type results. (bool; default: False) [default=False].

visir_util_repack.param.lincorrect

Apply linearity correction. Should only be enabled on high flux observations, may degrade results otherwise. (bool; default: False) [default=False].

The following code snippet shows the default settings for the available parameters.

import cpl
visir_util_repack = cpl.Recipe("visir_util_repack")

visir_util_repack.param.planestart = 0
visir_util_repack.param.planelimit = -1
visir_util_repack.param.ncycles = -1
visir_util_repack.param.trimlow = 0
visir_util_repack.param.trimhigh = 0
visir_util_repack.param.bkgcorrect = "none"
visir_util_repack.param.normalize = True
visir_util_repack.param.compress = False
visir_util_repack.param.lincorrect = False

You may also set or overwrite some or all parameters by the recipe parameter param, as shown in the following example:

import cpl
visir_util_repack = cpl.Recipe("visir_util_repack")
[...]
res = visir_util_repack( ..., param = {"planestart":0, "planelimit":-1})

See also

cpl.Recipe for more information about the recipe object.

Bug reports

Please report any problems to Lars Lundin. Alternatively, you may send a report to the ESO User Support Department.