Removing the instrumental signature from the raw MegaCam frames taken at CFHT
under the Queued Service Observing system falls under the responsibility of the
Elixir9
pipeline at CFHT. Correcting that signature is called “detrending” in Elixir parlance since it goes beyond what
basic pre-processing usually encompasses. The steps involve, in a single pass, applying a bad pixel mask,
correcting for the two-dimensional structures of the overscan, subtracting a master bias frame, and applying a
flat-field including the illumination correction that makes the photometric zero point uniform across the entire
image at the better than 1% level. The i and z images go through an extra step to subtract a scaled master fringe
pattern. Finally the images are astrometrically calibrated on a per-CCD basis and photometric zero points
information is fed into the final MEF (36 extensions) file based on the observing run global photometric
analysis. The following paragraph cover some details of these operations in the context of the T0007
release.
At the end of each MegaCam run, master twilight flat-field frames and master fringe frames are built from selected exposures taken during the run, including non-CFHTLS data (which represents about half of the total dataset over the acquisition phase of the survey, 2003-2009). Elixir builds master flat-fields for each filter by stacking the individual twilight flat-field frames. Individual frames inadvertently contaminated by clouds or nearby moon light are rejected. They are identified by dividing each individual flat field exposure by the master flat, and inspecting the result visually. Typically, no more than one iteration is needed to reject the outliers and ensure consistent quality of this key calibration frame over the years. In order to mitigate possible non-linearity residuals at the sub-percent level, individual flat field images are acquired in the 10,000 to 15,000 ADU range. After two weeks, the typical length for a MegaCam run, there are typically 40 to 60 usable frames that can be stacked into a final normalized frame equivalent to a single 400,000 ADU counts per pixels, reducing photon noise to negligible levels.
![]()
|
If one measures the photometry of the same star on an image flat-fielded from the basic twilight flat-fields, the flux varies by about 15% in the u band and 10% in the g-, r-, i-, and z-bands when moving the star from center to edges of the field of view. The variation is monotonic and essentially follows a circular pattern. It is caused by scattered light in the optics (a combination of indirect illumination and light reflections) and the inherent geometrical distortion of the image. A photometric flat-field, which ought to deliver uniform photometry across the field of view is then created by multiplying the master flat-field frame by the maps of the imager photometric response non-uniformities. This composite flat-field is the one used for flattening the science images of the entire run, and allows for all multiplicative effects in the image to be corrected at once.
The data released by CFHT for the six previous Terapix releases of the CFHTLS were based on photometric flat-fields which were affected by 4% peak-to-peak residuals. While this was adequate for most science goals of the CFHTLS, it was not satisfactory for the SuperNova Legacy Survey (?). As a consequence, the SNLS team and CFHT have collaborated since 2005 to realize precision photometric measurements using MegaCam. The effort was instrumental in unlocking the potential of the SNLS survey (?, Betoule et al, submitted).
This new recipe makes possible better than 1% peak-to-peak radial residuals within an image in all filters. This
Elixir recipe version is named “B5”(or “B5/SNLS” in reference to its origins). All individual Elixir processed
frames, available at CADC, used to build the Terapix T0007 release have a header indicating the
photometric recipe used (in general the newly processed images indicate an Elixir version 3.0 or
higher).
Fringe patterns are built by processing all i and z-band images corrected by the final flat-field. First the sky background is mapped at a large scale (100 pixels) and subtracted. Then, the exposures are scaled according to the fringe amplitudes measured on one hundred peak-valley pairs on each CCD. Since all CCDs see the same sky and since the photometric zero-point is uniform across the entire field of view, a single scaling factor is derived from the 36 CCDs. The scaled exposures are stacked, and an iterative process similar to the one described above is carried out, with a visual control allowing the rejection of frames containing extended astrophysical sources such as large galaxies. The fringe correction is challenging at times in the z-band and some images get only partially corrected due to the extreme behavior of the OH emission lines in the upper atmosphere which cause a signature too different from the run master fringe frame. (A different observing strategy such as the one adopted for the MegaCam Next Generation Virgo Survey would have helped but was not available during CFHTLS observations.) Consequently the defringing recipe is unchanged for the T0007 data collection. All fringe patterns were however re-created since they must include the signature of the new photometric B5/SNLS flat-fields.
After these detrending steps, Elixir processes all the images of the run, and derives an astrometric solution per CCD only, at the pixel scale level (0.2′′). The goal at the Elixir level is to provide the users with a first order astrometric solution and no global solution over the mosaic is computed; this is a task handled by Terapix.
Following this step, all the frames containing ? photometric standards (the CFHT QSO “Q97” program. Please refer to the description of the Observing Programs Identificators10 ) are identified and processed using SExtractor. A median zero-point for the entire run is derived for each filter, since not enough observing time is available to derive enough standard star observations per night to derive solid zero-point solutions. Again, the intention is to provide MegaCam users with a reliable photometric scaling, offering a precision at the 4% level in absolute. But then again, since this default calibration was clearly not precise enough for their needs, the SNLS team developed in collaboration with CFHT new procedures to calibrate the images. This vast undertaking is the key to major improvements in T0007 compared to T0006: all knowledge acquired for the SNLS survey has been passed to the Deep and the Wide surveys. This calibration effort is described in detail in Section 3.7.