3.2 UVIS Data Calibration Steps

As of calwf3 v3.7.1, the pipeline processes all UVIS data twice, once with the CTE correction applied as the first step, and a second time without the CTE correction. Figure 3.1 shows a schematic representation of all the UVIS calibration steps, which are also briefly summarized below, in the order they are performed, with the corresponding calibration switch keyword in parentheses.

  • Calculate and correct for effects due to declining charge transfer efficiency (CTE) in the image (PCTECORR), for UVIS only 
  • Calculate and record uncertainty (noise) for each pixel (NOISCORR) in the error, ERR, array and update its associated headers. Initialize the data quality, DQ, array of the image (DQICORR). Note the (NOISCORR) calibration switch is inaccessible to the user i.e. it is not listed explicitly in the image header and the correction is always performed by default 
  • Initialize the data quality (DQ) array of the image based on BPIXTAB, flag A-to-D saturation, and potentially flag full-well saturation (DQICORR
  • Correct for A-to-D conversion errors where necessary, currently skipped (ATODCORR
  • Subtract bias level determined from overscan regions (BLEVCORR
  • Subtract the residual bias structure from the image (BIASCORR
  • If applicable, employ a full-well saturation image, SATUFILE, to flag affected pixels. 
  • Detect and record SINK pixels in the DQ mask (performed if DQICORR is set to PERFORM
  • Subtract the post-flash image, if applicable (FLSHCORR
  • Scale and subtract the dark image (DARKCORR
  • Divide by flat-field image(s) and apply gain conversion (FLATCORR
  • Perform shutter-shading correction where necessary, currently skipped (SHADCORR), for UVIS only 
  • Populate photometric header keywords (PHOTCORR
  • Correct chips to use the same zero point (FLUXCORR
  • Calculate basic pixel statistics for the image and store the values in relevant header keywords (no switch)

The ATODCORR step is currently skipped as WFC3 ground tests did not show a bias toward the assignment of certain DN values, so this correction is not needed. The SHADCORR step, which corrects the science image for differential exposure time across the detector caused by the amount of time it takes for the shutter to open and close completely, is always set to OMIT as shutter shading was found to be an insignificant effect.  

If BLEVCORR and BIASCORR are performed, a full-well 2-D saturation image (SATUFILE) is applied to flag affected pixels. This is the updated and preferred method of flagging such pixels. If the SATUFILE keyword is missing from the FITS header, then the flagging of full-well saturated pixels is done during the DQICORR step using a single constant value as the threshold. 

Figure 3.1: Flow diagram of the calwf3 pipeline for UVIS data.

The name of the reference files used at each step, as well as the calibration switches that control each step are indicated. NOISCORR is a calibration switch inaccessible to the user i.e. it is not listed explicitly in the image header and the correction is always performed by calwf3.


3.2.1 Correction For Charge Transfer Efficiency

  • Header switch: PCTECORR
  • Reference file: PCTETAB

The charge transfer (CTE) of the UVIS detector has been declining over time as on-orbit radiation damage creates charge traps in the CCDs. During the charge transfer in the CCD readout process, these traps capture photo-electrons generated in other “upstream” pixels, thus lowering the detected charge. Faint sources, in particular, can suffer large flux losses or even be lost entirely if observations are not planned and analyzed carefully. The CTE depends on the morphology of the source, the distribution of electrons in the field of view, and the population of charge traps in the detector column between the source and the transfer register. Further details of the our current understanding of the state of the WFC3/UVIS CTE are presented in Chapter 6, as well as on the WFC3 CTE web page. The PCTECORR step aims to mitigate the flux loss incurred from CTE. 

More information on this part of the pipeline can be found in Section 3.4.1, which details the functioning of the wf3cteroutine. 

3.2.2 Error Array Initialization

  • Header switch: NOISCORR (not listed explicitly in image header, see text)
  • Reference file: CCDTAB

In this step, the image error array is initialized and populated by the uncertainty signal measurement using the NOISCORR switch. The function examines the ERR extension of the input data to determine the state of the array. The input _raw image contains an empty ERR array. If the ERR array has already been expanded and contains values other than zero, then this function does nothing. Otherwise, it will initialize the ERR array by assigning pixel values based on a simple noise model for a CCD detector. The noise model uses the science (SCI) array and for each pixel calculates the uncertainty value σ in units of DN for each pixel. The NOISCORR calibration step keyword is not explicitly listed in the image header (i.e., it is not user-accessible), and it is always set to PERFORM

\sigma_{UVIS (e-/s)} = \frac{\sqrt{RN^2+(flux*pflat+dark+PF)+\sigma_{dark}^2+\sigma_{PF}^2+(\sigma_{pflat}*flux)^2}}{pflat*exptime}

where RN (readnoise), dark, PF (postflash), and flux are in units of electrons, and exptime (exposure time) is in units of seconds.

The CCD refers to the various quadrants of the detector that are read by the four readout amplifiers (see Chapter 5 of the WFC3 Instrument Handbook). The bias, gain and readnoise in the equation above for each quadrant is read from the CCDTAB reference file. The reference file is a FITS table that contains one row for each configuration that can be used during readout, and is uniquely identified by the list of amplifiers (replicated in the CCDAMP header keyword), the particular chip being read out (CCDCHIP), the commanded gain (CCDGAIN), the commanded bias offset level (CCDOFST) and the pixel bin size (BINAXIS). These commanded values are used to find the table row that matches the characteristics of the image that is being processed and reads each amplifiers characteristics, including readnoise (READNSE), A-to-D gain (ATODGN) and the mean bias level (CCDBIAS).

3.2.3 Data Quality Array Initialization

  • Header switch: DQICORR
  • Reference files: BPIXTAB

This step initializes the data quality array by reading a table of known bad pixels for the detector, as stored in the Bad Pixel reference table, BPIXTAB. In addition to the bad pixel types in the table, the types of bad pixels that can be flagged are:

Table 3.2: Data quality array flags for UVIS files

NAME

VALUE

DESCRIPTION

GOODPIXEL

0

OK

SOFTERR

1

Reed-Solomon decoding error

DATALOST

2

data replaced by fill value

DETECTORPROB

4

bad detector pixel or beyond aperture

DATAMASKED

8

unused

HOTPIX

16

hot pixel

CTETAIL

32

UVIS unstable pixel (post-November 2012)

WARMPIX

64

warm pixel

BADBIAS

128

bad pixel in bias

SATPIXEL

256

full-well saturated pixel

BADFLAT

512

bad or uncertain flatfield value

TRAP

1024

UVIS charge trap and sink pixels

ATODSAT

2048

a-to-d saturated pixel

CR hit

4096

reserved for Astrodrizzle CR rejection

DATAREJECT

8192

rejected during image combination UVIS, IR CR rejection

CROSSTALK

16384

not used

RESERVED2

32768

not used

In some cases, the DQ array may already have been populated with some values to flag pixels affected by telemetry problems during downlink. Other DQ values will only be marked during further processing (such as cosmic-ray rejection). This function potentially performs two checks to determine saturation. If the newer (mid-2023) SATUFILE FITS keyword is missing or invalid in the input image header, the fallback is to flag full-well saturated pixels during this step using a single scalar as the threshold. This value is located in the SATURATE column in the CCD parameters table (CCDTAB). Any SCI array pixel value that is greater than the SATURATE value will be assigned a flag value of 256 in the DQ array. However, the newer technique is to flag the full-well saturated pixels in a sub-step after BLEVCORR/BIASCORR using a full two-dimensional image as the threshold (see Section 3.2.7). Second, this function checks SCI array pixel values that have reached the limit of the detector’s 16-bit A-to-D converters, flagging any pixel with a value > 65534 DN with the ‘A-to-D saturation’ DQ value of 2048. If a pixel is flagged as A-to-D saturated pixels, then they are also flagged as full-well saturated, so their DQ is actually updated (bitwise) to 256+2048.

Full-well saturated pixels (but not A-to-D saturated) could still be used for aperture photometry, since charge keeps being created in saturated pixels though it’s no longer retained in the original pixel and spills over to the neighboring ones (bleeding, see also WFC3 ISR 2010-10). Users should be aware that the photometric apertures in this case should be defined as to include all the bled charge. Users can check Section 5.4.5 and Section 5.4.6 of the WFC3 Instrument Handbook for further details on full-well and A-to-D saturation.

DQICORR combines the DQ flags from preprocessing, BPIXTAB, SNKCFILE, and saturation tests into a single result for the particular observation. These values are combined using a bit-wise logical OR operation for each pixel. Thus, if a single pixel is affected by two DQ flags, those flag values will be added in the final DQ array. This array then becomes a mask of all pixels that had some problem coming into the calibrations, so that the calibration processing steps can ignore masked pixels during processing. The BPIXTAB reference file maintains a record of the pixel position (x,y) and the DQ values for all known bad pixels in each CCD chip for a given time period.

Descriptions of the bad pixels and their associated values that can be flagged are indicated in Table 3.2

3.2.4 Correct for Analog-to-Digital Conversion Errors

  • Header Switch: ATODCORR
  • Reference File: ATODTAB

An analog-to-digital conversion correction is applied if the CCD electronic circuitry, which performs the analog-to-digital conversion, is biased toward the assignment of certain DN values. WFC3 ground test results showed that this correction is not currently needed, so the ATODCORR switch is currently always set to ‘OMIT’ so that this function is not performed.

3.2.5 Overscan Bias Correction

  • Header Switch: BLEVCORR
  • Reference File: OSCNTAB

The overscan regions are used to monitor the instrument as well as provide a measure of the bias level at the time the detector was exposed (see Figure 3.2). BLEVCORR fits the bias level in the CCD overscan regions and subtracts it from the image data. The boundaries of the overscan regions are taken from the OSCNTAB reference file (Overscan Region Table). The OSCNTAB reference file describes the overscan regions for each chip along with the regions to be used for determining the actual bias level of the observation. Each row corresponds to a specific configuration, given by the gain, readout amplifier, charge injection, and binning.

The OSCNTAB columns BIASSECTAn and BIASSECTBn give the range of image columns to be used for determining the bias level in the leading and trailing regions, respectively, of the serial physical overscan regions, while columns BIASSECTCn and BIASSECTDn give the range of columns to be used for determining the bias level from the serial virtual overscan regions. The parallel virtual overscan regions are defined in the OSCNTAB in the VXn and VYn columns. To determine which overscan regions were actually used for measuring the bias level, check the OSCNTAB reference file. Users may modify the overscan region definitions in the reference table for manual calibration, but the TRIMXn and TRIMYn values must not be changed.

With these regions defined, the serial and parallel virtual overscans are analyzed to produce a two-dimensional linear fit to the bias level. The overscan level for each row of the input image is measured within the serial virtual overscan region, sigma-clipping is used to reject anomalous values (e.g., cosmic-ray hits that occur in the overscan) and a straight line is fit as a function of image line number. The same procedure is followed for the parallel overscan, resulting in a linear fit as a function of image column number. The parallel fit is computed in the form of a correction to be added to the serial fit result, in order to remove any gradient that may exist along the x-axis direction of the image. The serial fit and the parallel correction to it are then evaluated at the coordinates of each pixel and the computed bias value is subtracted from that pixel. This is done independently for each region of the image that was read out by one of the four CCD amplifiers. The mean bias value determined for each of the amplifier quadrants is recorded in the primary header keywords BIASLEV[ABCD] and the overall mean bias value is computed and written to the output SCI extension header as MEANBLEV.

Figure 3.2: Schematic view of the UVIS “raw” full frame, with overscan regions highlighted. See Section 6.7.2 of the WFC3 Instrument Handbook for further details.


Note: UVIS subarray images do not include virtual overscan, therefore the serial physical overscan will be used - if present - to perform the bias subtraction. If a subarray image does not include the physical overscan region of the detector, then the bias level cannot be determined. In this case a default value (CCDBIAS from the CCD parameters table) will be subtracted instead and a warning message is written to the processing trailer file.

The full bias level-subtracted image is retained in memory until the completion of all the processing steps in wf3ccd. The overscan regions will not be trimmed until the image is written to disk at the completion of wf3ccd.

3.2.6 Bias Structure Correction

  • Header Switch: BIASCORR
  • Reference File: BIASFILE

This step subtracts the two dimensional bias structure from the image using the superbias reference file listed in the header keyword BIASFILE. The dimensions of the input image are used to distinguish between full and subarray images. The BIASFILE has the same dimensions as a full-size science image, complete with overscan regions. The same superbias is used for full-frame and subarray input images; calwf3 will extract the matching region from the full-size superbias file and apply it to the subarray image.

3.2.7 Saturation Flagging and Sink Pixel Detection

  • Header Switch: DQICORR
  • Reference File: SATUFILE, SNKCFILE

Full-well saturation occurs in a charge-coupled device (CCD) when accumulating charge from a central pixel begins to spill into neighboring pixels.The depths at which saturation occurs varies spatially over both UVIS CCDs.  (WFC3 ISR 2010-10). Saturated pixels in UVIS images are identified by the calwf3 calibration pipeline in the DQICORR step and subsequently flagged in the image data quality (DQ) array of the calibrated flat-fielded (FLT) file. If both the BLEVCORR and BIASCORR steps are performed, and the input image contains a valid FITS SATUFILE keyword in the primary header, then the full-well saturation image identified by the SATUFILE keyword will be used to define a per-pixel saturation threshold for flagging at this stage. For details on the new reference file, see WFC3 ISR 2023-08 and Section 5.6.

Sink pixels are a detector defect. These pixels contain a number of charge traps and under-report the number of electrons that were generated in them during an exposure. These pixels can have an impact on nearby upstream or downstream pixels, though they often only impact one or two pixels when the background is high, they can impact up to 10 pixels if the background is low (see Section 6.7 for more information about sink pixels detection and flagging).

Flagging of sink pixels in the DQ extension of calibrated images is controlled with the DQICORR header keyword and happens after the bias correction has been performed. With DQICORR set to PERFORM, the sink pixels marked in the SNKCFILE reference image are flagged in the science image's DQ array. Given the SNKCFILE reference image, the procedure for flagging the sink pixel in the science data involves:

  • Extract the MJD of the science exposure
  • Examine the reference image, pixel by pixel, to find values greater than 999, which indicates that a given pixel is a sink pixel. The value of the reference file pixel corresponds to the date (in MJD format) at which this pixel started exhibiting sink pixel behavior.
  • If the turn-on date of the sink pixel is after the exposure date of the science image, then we ignore the sink pixel in this exposure.
  • If the turn-on date of the sink pixel is before the exposure date of the science image, then this science pixel was compromised at the time of the exposure. The corresponding pixel in the DQ extension of the science image is flagged with the "charge trap" value of 1024.
  • If the pixel “downstream” of the sink pixel, along the readout direction, has a value of -1 in the SNKCFILE reference image, then it is also flagged with the “charge trap” value in the DQ extension. We then proceed vertically “upstream” from the sink pixel and compare each pixel in the reference file to the value of the sink pixel in the science exposure at hand. The reference file contains –at the positions of the upstream pixels- estimates of the minimum charge a sink pixel has to contain, in order not to affect the nearby upstream pixel. If the value of the sink pixel in the exposure is below the value of the upstream pixel in the reference image, we flag that upstream pixel with the “charge trap” value in the DQ extension. We continue to flag upstream pixels until the value of the pixel in the reference image is zero or until the value of the sink pixel in the exposure is greater than the value of the upstream pixel in the reference image.

WFC3 ISR 2014-19 has a detailed analysis on detection of the sink pixels, while the strategy for flagging them is discussed in WFC3 ISR 2014-22

Sink pixels were originally only flagged in full frame science images, but since calwf3 v3.4 sink pixel flagging has also been done in subarray images. The pipeline flags pixels affected by sink pixels in the data quality extension; the pipeline does not change the science pixel values. 

3.2.8 Post-flash Correction

  • Header Switch: FLSHCORR
  • Reference File: FLSHFILE

WFC3 has post-flash capability to provide a means of mitigating the effects of Charge Transfer Efficiency (CTE) degradation (see WFC3 ISR 2013-12). When FLSHCORR=PERFORM, this routine subtracts the post-flash reference image, FLSHFILE, from the science image. This file has the same dimensions as a full-size science image complete with overscan regions. FLSHFILE is in units of electrons per second, scaled to an exposure time of 1 sec. The appropriate FLSHFILE is selected based on the values of the image header keywords: USEAFTER, DETECTORCCDAMPCCDGAINFLASHCURBINAXISi, and SHUTRPOS.

The success of the post-flash operation during the exposure is first verified by checking the keyword FLASHSTA (ABORTEDSUCCESSFULNOT PERFORMED). calwf3 selects the reference file which matches the science image’s binning (BINAXISi), shutter position (SHUTRPOS, either A or B, i.e. the blade used reflect the postflash LED's light into the optical path to illuminate the detector), and flash current level settings (LOWMEDHIGH, recorded in the FLASHCUR keyword). In addition, observation date is used for reference file selection as the FLSHFILEs are now time-dependent (WFC3 ISR 2023-01); observers with post-flashed data retrieved prior to 2023 can re-retrieve their observations from MAST to obtain the updated calibration. The calwf3 pipeline scales the reference file by the flash duration (stored in the FLASHDUR keyword) then subtracts it from the science image. The mean value of the scaled post-flash image is recorded in the MEANFLSH header keyword in units of DN. Since the blade used for post-flash typically alternates between exposures, different members of an association can have different values of SHUTRPOS. This does not constitute a problem for calibration as the reference files are populated separately for each exposure.

3.2.9 Dark Current Subtraction

  • Header Switch: DARKCORR
  • Reference File: DARKFILEDRKCFILE

The dark current correction step subtracts the estimate of the dark current from the science image. The reference file listed under the DARKFILE header keyword is used in the non-CTE corrected UVIS pipeline branch, DRKCFILE is instead used in the CTE-corrected branch. The dark image (in units of electrons/sec) is multiplied by the exposure time, and subtracted from the input image.

The mean dark value is computed from the scaled dark image and used to update the MEANDARK keyword in the SCI image header. The dark reference file is updated frequently to allow the tracking of hot pixels over time. The time by which the dark reference file gets multiplied is simply the exposure time in the science image; it does not include the idle time since the last flushing of the chip or the readout time. Any dark accumulation during readout time is included automatically in the BIASFILE.

The reference file for dark subtraction, DARKFILE (DRKCFILE), is selected based on the values of the keywords DETECTORCCDAMPCHINJECT, and BINAXISi in the image header. The dark correction is applied after the overscan regions are trimmed from the input science image. In a similar fashion to the BIASCORR step, calwf3 requires the binning factors of the DARKFILE (DRKCFILE) and science image to match. Sub-array UVIS science images use the same reference file as a full-sized DARKFILE (DRKCFILE), calwf3 simply extracts the appropriate region from the reference file and applies it to the sub-array input image.

3.2.10 Flat-field Correction

  • Header Switch: FLATCORR
  • Reference Files: PFLTFILELFLTFILEDFLTFILE

This routine corrects for pixel-to-pixel and large-scale sensitivity variations across the detector by dividing the overscan-trimmed and dark-subtracted science image by a flat-field image.

Because of geometric distortion effects, the area of the sky seen by different pixels is not constant and therefore observations of a constant surface brightness object will have counts per pixel that vary over the detector, even if every pixel were to have the same intrinsic sensitivity. In order to produce images that appear uniform for uniform illumination, the same counts per pixel variation across the field is left in place in the flat-field images, so that when a science image is divided by the flat it makes an implicit correction for the distortion effects on photometry. A consequence of this procedure is that two point-source objects of equal brightness will not have the same total counts after the flat-fielding step, thus point source photometry requires the application of a pixel area map (PAM) correction.

The flat-field correction generates images that appear uniform for uniform illumination. As a result, aperture photometry extracted from a flat-fielded image (flt, flc) must be multiplied by the effective pixel area map

The PAM correction is automatically included in pipeline processing by Astrodrizzle, which uses the geometric distortion solution to correct all pixels to equal areas. Photometry is therefore correct for both point and extended sources in drizzled (drz, drc) images.

Up to three separate flat-field reference files can be used: the pixel-to-pixel flat-field file (PFLTFILE), the low-order flat-field file (LFLTFILE), and the delta flat-field file (DFLTFILE). The most recent information about the various UVIS flats currently in the pipeline can be found in  ISR 2016-05 and ISR 2016-04. The PFLTFILE is a pixel-to-pixel flat-field correction file containing the small-scale flat-field variations. Unlike the other flat fields, the PFLTFILE is always used in the calibration pipeline. The LFLTFILE is a low-order flat that corrects for any large-scale sensitivity variations across each detector. This file can be stored as a binned image, which is then expanded when being applied by calwf3. Finally, the DFLTFILE is a delta-flat containing any needed changes to the small-scale PFLTFILE. If the LFLTFILE and DFLTFILE are not specified in the SCI header, only the PFLTFILE is used for the flat-field correction. If two or more reference files are specified, they are multiplied together to form a combined flat-field correction image. Currently the standard UVIS calwf3 image processing uses a single flat field image, indicated by the PFLTFILE keyword. This image, however, does not only contain pixel-to-pixel variations but includes low order polynomial corrections as well. All flat-field reference images must have detector, amplifier, filter, and binning modes that match the observation. A UVIS sub-array science image uses the same reference file as a full-size image; calwf3 extracts the appropriate region from the reference file and applies it to the subarray input image.

Gain Correction

After the flat fielding step, the image is divided by the gain to convert into units of electrons.

The units of some calibration reference files may be different than the units of the calibrated image at the stage when they are applied by calwf3. For example, SATUFILE and SINKCFILE are in units of electrons, FLSHFILE and DARKFILE are in units of electrons/sec, while the image prior to FLATCORR is still in units of DN. Before applying these reference files, calwf3 will use the gain to convert them to units of DN to ensure they are consistent with the input data. 

3.2.11 Shutter Shading Correction

  • Header Switch: SHADCORR
  • Reference Files: SHADFILE

This step corrects the science image for differential exposure time across the detector caused by the amount of time it takes for the shutter to completely open and close, which is a potentially significant effect only for images with very short exposure times (less than ~5 seconds). Pixels are corrected based on the exposure time using the relation:


corrected = uncorrected \times \frac{EXPTIME}{EXPTIME + SHADFILE}


WFC3 tests have shown that the shutter shading effect is insignificant (< 1%) for even for the shortest allowed UVIS exposure time of 0.5 seconds (WFC3 ISR 2007-17). As a consequence, this step is set to OMIT in calwf3 by default.

3.2.12 Photometry Keywords Calculation

  • Header Switch: PHOTCORR
  • Reference Files: IMPHTTAB

In order to extract calibrated magnitudes (or equivalently fluxes) directly from wfc3 images, a transformation to absolute flux units is necessary. Users who do not wish to use this feature should set the header keyword PHOTCORR to OMIT. However, users that intend to use the FLUXCORR step (see Section 3.2.13), must also set PHOTCORR to PERFORM as well.

The PHOTCORR step is performed using tables of precomputed values instead of calling synphot to compute keyword values on-the-fly as was done prior to November 2013. calwf3 version 3.1.6 and greater uses an Image Photometry reference table (IMPHTTAB) specific to each WFC3 detector (IR or UVIS). The PHOTMODE keyword string reflects the observing configuration for the exposure (e.g., ‘WFC3, UVIS1, F814W’). calwf3 uses that PHOTMODE to retrieve the photometric values from the appropriate row in the reference table and update the science data header keywords listed below.

  • PHOTFNU: the inverse sensitivity in units of: Jansky sec electron−1
  • PHOTFLAM: the inverse sensitivity in units of ergs cm−2 A−1 electron−1
  • PHOTPLAM: the bandpass pivot wavelength in Å
  • PHOTBW: the bandpass RMS width in Å
  • PHTFLAM1: the inverse sensitivity in units of ergs cm−2 A−1 electron−1 for infinite aperture (chip1)
  • PHTFLAM2: the inverse sensitivity in units of ergs cm−2 A−1 electron−1 for infinite aperture (chip2)

Mathematical definitions of the above keywords, are defined on the synphot ReadTheDocs page. For calwf3 version 3.3 and beyond, the value PHOTFNU is calculated for each UVIS chip separately (see also Section 3.2.13). The SCI headers for each chip contain the PHOTFNU keyword, which is valid for its respective chip, and is calculated as:

For UVIS 1:

photF_{nu} = 3.33564 \times 10^4 \times PHTFLAM1 \times PHOTPLAM^2

For UVIS 2:

photF_{nu} = 3.33564 \times 10^4 \times PHTFLAM2 \times PHOTPLAM^2

 
The IMPHTTAB file format for WFC3 UVIS has the following structure.

EXT#        FITSNAME          FILENAME        EXTVE         DIMENS         BITPI OBJECT
0 z7n21066i_imp z7n21066i_imp.fits 16
1 BINTABLE PHOTFLAM 1 5Fx256R
2 BINTABLE PHOTPLAM 1 5Fx256R
3 BINTABLE PHOTBW 1 5Fx256R
4 BINTABLE PHTFLAM1 1 5Fx256R
5 BINTABLE PHTFLAM2 1 5Fx256R

Each extension contains the photometry keyword information for that specific header keyword; rows are observation mode-dependent. 

3.2.13 Flux normalization for UVIS1 and UVIS2

  • Header Switch: FLUXCORR
  • Reference Files: None

The FLUXCORR step was implemented in calwf3 v3.3 on February 23, 2016 as part of the new UVIS chip-dependent photometric calibration (WFC3 ISR 2016-01). FLUXCORR multiplies the UVIS2 image (SCI, 1 in the data file) by the ratio of inverse sensitivities PHTFLAM2/PHTFLAM1 so that the same flux correction can be used for both chips. The ratio is stored for reference in the image header keyword PHTRATIO. By default, FLUXCORR is set to PERFORM during calwf3 processing, and in this case the keyword PHOTFLAM will be valid for both chips after the correction is applied. If users do not wish to perform the correction, the FLUXCORR keyword may be set to OMIT and the raw data reprocessed through calwf3. In this case, the keywords PHTFLAM1 and PHTFLAM2 may be used to convert to flux units in the respective chips.

Chip-dependent flat fields (from 2016 or later) must be used with calwf3 v3.3 onwards and should not be used with older versions of the pipeline, and vice versa, otherwise the data will be scaled incorrectly. For more details, see Section 9.1.

In order for FLUXCORR to work properly, the value of PHOTCORR must also be set to PERFORM since this populates the header of the data with the keywords FLUXCORR requires to compute the PHTRATIO.

3.2.14 Cosmic-ray Rejection

  • Header Switch: CRCORR
  • Reference Files: CCREJTAB

Associations with more than one member taken via CR-SPLIT or REPEAT-OBS will be combined using wf3rej (see Section 3.4.5 for more details). The task uses the same statistical detection algorithm developed for ACS (acsrej), STIS (ocrrj), and WFPC2 (crrej), providing a well-tested and robust procedure. For all associations (including dithered observations), the DRZ and DRC products are created by Astrodrizzle which performs both cosmic ray detection (in addition to wf3rej for CR-SPLIT or REPEAT-OBS observations) and corrects for geometric distortion.

3.2.15 UVIS Image Statistics Calculation

  • Header Switch: None
  • Reference File: None

This routine computes several statistics for data values that are flagged as ‘good’ in the data quality array. These quantities are updated in the SCI image header: the minimum (GOODMIN), mean (GOODMEAN), and maximum (GOODMAX) values, as well as the minimum (SNRMIN), mean (SNRMEAN), and maximum (SNRMAX) signal-to-noise ratio (the ratio of the SCI and ERR pixel values). The number of good pixel is recorded in NGOODPIX. The minimum, mean, and maximum statistics are also computed for the ERR array.