Every photon event in a COS corrtag file has a Data Quality (DQ) flag. Each flagged condition sets a specific bit in the 16-bit DQ word, thus allowing each event during an exposure to be flagged with multiple conditions using the bitwise logical OR operation. The DQ flag values are listed in the table below. These flags can be divided into four types:
Spatial flags mark events which fall on a detector region which may be questionable. The BPIXTAB reference file marks the corners of each region on the detector which falls into each of these categories. Separate BPIXTAB files are used for the FUV and NUV detectors. These regions were determined by visual inspection of a set of science data files.For FUV data, the GSAGTAB is applied along with the BPIXTAB. The GSAGTAB is used to flag regions that are severely gain sagged
The DQICORR step of calcos maps these spatial regions to the individual photon events, and the X1DCORR module (extraction step) uses these flags and the value of SDQFLAGS (Serious Data Quality FLAGS) header keyword to create the DQ and DQ_WGT arrays, and ultimately which events to include in the final (x1dsum) spectrum (Section 3.4.13). The SDQFLAG default values corresponding to the different configurations are displayed in the table at the end of this section.
The spatial flags include:
- Detector shadows (4) include the locations of the grid wires for the FUV detector, and the vignetted region on the NUV detector.
- Poorly calibrated regions(8) these include areas near the edge of the detector which may be suspect.
- Very low response regions (16) are regions on the detector where the response presents a >80% depression.
- Background features (32) are regions on the detector where the background count rate has been observed to be higher than the surrounding region and/or unstable.
- The Pixel out of bounds (128) flag marks regions outside of the active area of the detector.
- Low response regions (1024) are areas on the detector where the response presents a >50% depression.
- Low PHA feature (4096) are regions in which unusual features have been identified in long background exposures. These features may have an effect when the count rate is very low or the background is higher than normal.
- Gain-Sag hole (8192) are regions on the FUV detector where the gain is low enough that the calibration may be affected
Temporal flags mark photons that occur during time spans in which the data quality is suspect. Events flagged in this way will be discarded by calcos at the extraction step, and the exposure time will be adjusted accordingly. Two types of temporal flags are used:
- FUV event bursts (64), which are flagged by the BRSTCORR module of calcos. As of this writing, no bursts have been seen on orbit, so the BRSTCORR step has been set to OMIT by default. If bursts are seen at some point, it is likely that the parameters in the BRSTTAB reference table will have to be adjusted before using BRSTCORR.
- Other Bad Time Intervals (2048) can be defined in the BADTTAB reference file, for time ranges that are known to be problematic. At present, STScI has not defined any bad time intervals, but users running calcos on their own may wish to define their own intervals in order to exclude times with high background, etc.
Event flags are set by calcos if a photon event falls outside defined thresholds. Currently, two flags fall into this category:
- FUV Pulse Height too low Flag (512) - All FUV events with pulse heights falling above or below the range specified in the PHATAB reference file will have this flag set, and the data will be excluded by the DQICORR module. This flag is not used for NUV data.
Lost Data flags occur if data is missing or corrupt for some reason, such as errors in transmitting the data from the instrument to the ground. Data marked with these flags is always excluded from the final products. There are two flags in this category:
- Reed-Solomon errors (1)
- Fill Data (256)
COS Data Quality Flags
|Flag Value||Quality Condition||Type||FUV or NUV|
|0||No anomalous condition noted||N/A||Both|
|1||Reed-Solomon error||Lost Data||Both|
|8||Poorly calibrated region (including detector edge)||Spatial||Both|
|128||Pixel out of bounds||Spatial||Both|
|256||Fill Data||Lost Data||Both|
|512||Pulse height out of bounds||Event||FUV|
|1024||Low response region (>50% depression)||Spatial||Both|
|2048||Bad time interval||Temporal||Both|
|4096||Low PHA feature||Spatial||Both|
COS Serious Data Quality Flags (SDQFLAGS)