As a result of the decision to operate both an online PL and an off-line PL the filename specification of Section 4.2.2 has been redefined and updated to include a 3 level PL processing flag:
where the off-line PL will only run on those files with p=1.
The online LT PL has been written in collaboration with Dr. Iain Steele (IAS) and Dr. Robert Smith (RJS), and was initiated to remove overlap of the CS and original PL. IAS coded the initial online PL infrastructure and the software libraries which perform the basic data reduction (e.g., de-biasing, flat-fielding and de-fringing etc.) using CFITSIO (see Section 3.1.1 and Section 5.9.2) and algorithms presented in Section 2.4. Additional functions were then added as described below with a re-write of the online PL necessary to take advantage of the algorithm structure previously determined by functions which were written to be part of the off-line PL. The online PL’s final architecture was the responsibility of RJS.
The online PL carries out de-biasing, flat-fielding and de-fringing of every image which the LT observes, using library images which are stable for a period of at least one week at the LT site (Irwin and Lewis, 2001). The library frames are to be updated at set intervals which is to be decided upon during commissioning. The name of the calibration files used are recorded to the FITS header.
The online PL also enables several data quality checks by feeding data back to the CS: A background intensity is calculated using algorithms similar to those used by KAPPA in Section 4.2.5 and recorded to the FITS header. As a measure of the image seeing the Full Width at Half Maximum (FWHM) of those objects known to be stars, in practice this is only performed on the photometric standards (as defined by the LT photometric catalogue see Section 5.9.4), is calculated. These data are extracted from the FITS header by (i) the CS to implement changes to the observation scheduler, thereby performing those observations that have the best chance of being successful and to aid the telescope focus, (ii) the off-line PL to aid in the photometry calculations.
If an integer FITS file is read using floating point variables the amount of memory needed to store the file is increased for no reason (i.e., 256 is read as 256.0). To solve this each file is read in as a “char”, the data type is then iteratively tested to ascertain its actual data type, the keywords remain as “chars” unless their data is required.
To enable fast manipulation of FITS files keywords exists which scale the primary data, these are: (i) BSCALE, the ratio of the physical value to the array value at zero offset. (ii) BZERO, a floating point number which represents the physical value corresponding to an array value of zero. The default values are 1.0 and 0.0 respectively. The true value of any pixel in a FITS frame can be determined from these two keywords thus;
![]() | (5.5) |
The reading/writing of the FITS file is achieved by strictly following the structure setout in NOST (1999) and any LT local features. Having created a new set of data to be stored as a FITS file (e.g., after flat-fielding) a new set of header files must be generated. With information taken from both the original file and newly generated data. This process involves detailed “string” manipulation which needs to be done efficiently with out altering the original-memory-held copy of the FITS file in case it has to be re-accessed. The primary data is then rescaled using Equation (5.5), byteswapped and written out.
The second moments are then convenient for measuring the spatial spread of the source profile. These are calculated using algorithms presented by Draper and Eaton (1999):
The basic shape parameters, the semi-major (a) and semi-minor (b) axes of the detected object, represent the maximum and minimum spatial profile of the object in any direction and are calculated by Draper and Eaton (1999) thus:
From these parameters the orientation of the object can be determined. The ratio of a and b determines whether or not the object is circular and therefore stellar; if the object is circular it is included in the calculation for the frame FWHM. The tolerance value on this ratio is to be set during commissioning.The calculation of the FWHM for the online PL must be performed quickly so as not to increase off-line telescope time, the systems which use the computed value need only a rough value and for this reason a 2D FWHM is not calculated.
The FWHM of the seeing spatial profile is therefore determined in a 1D manner in both the x and y directions and the mean result is used as the object FWHM. This is performed for every stellar object in the frame with the mean value being the frame FWHM. The FWHM is calculated from the derivation below;
A Gaussian profile is used as a model of the detected object. In 1D, a Gaussian has the form
![]() | (5.13) |
is the standard deviation of the data.