Skip to the navigation links
Last modified: 4 November 2010

URL: http://cxc.harvard.edu/caldb/about_CALDB/indexing.html

Indexing System


The most vital characteristic of the CALDB structure is the indexing system. The index works with the header specifications in the various data files to ensure unambiguous file selection.

Special FITS files named caldb.indx contain the lists of CALDB keywords for the principle header data unit (HDU) of each calibration file; there is one index file for each instrumental branch. The caldb.indx files are actually links to the latest versioned files in the appropriate index directory; see the Versioning page for more information.

The index file format is prescribed in the HEASARC reference "Calibration Index Files" (CAL/GEN/92-008).

Index File Columns

The columns included in each index file are listed in Table 1. There is one line in the table for each data set (each HDU) that has been entered into the index. Some files have only one HDU indexed; others, such as the ACIS bad pixel files, have one extension for each detector chip.

Table 1: CALDB index file columns.

Name

Format and length

Source/Description

TELESCOP 10A TELESCOP header keyword
INSTRUME 10A INSTRUME header keyword
DETNAM 20A DETNAM header keyword
FILTER 10A FILTER header keyword
CAL_DEV 20A Logical link necessary for CALDB access
CAL_DIR 70A Subdirectory location of file
CAL_FILE 80A CALDB filename being indexed
CAL_CLASS 3A CCLS0001 keyword value
CAL_DTYP 4A CDTP0001 keyword value
CAL_CNAM 20A CCNM0001 keyword value
CAL_CBD 630A70 CBDn0001 keyword values
CAL_XNO I Extension number within the fits file of the dataset
CAL_VSD 10A CVSD0001 keyword value (date only)
CAL_VST 8A CVST0001 keyword value
REF_TIME 8-byte double (D) CVSD0001 converted into modified Julian date
CAL_QUAL I Calibration quality value, 0=good, 5=bad;
see the Quality Keyword section.
CAL_DATE 10A Date the HDU was indexed in the CALDB
CAL_DESC 70A CDES0001 keyword value

Quality Keyword

Only two values of the quality keyword, CAL_QUAL, are currently used in the Chandra CALDB: 0 and 5. Good quality is indicated by the value 0. A value of 5 indicates that the calibration data has been replaced by better dataset.

Only the good files can be retrieved by a CALDB query. There must be only one good file for a given full specification, otherwise multiple datasets would be returned. Files marked as bad are kept as options for custom processing requests or for manual selection by the user.

Adding & Removing Files

Adding new files to the database is the responsibility of the Chandra CALDB manager. These files will be announced in an official patch to the CALDB and will be posted on the Download page. When you install the update, it will automatically write the calibration files, create a new versioned index file, and update the caldb.indx link for each affected branch.

You should not attempt to index your own files. If the local index files are changed, updates from the download page may not occur properly. Additionally, your internal changes will be overwritten by the CALDB upgrade.

It is also the responsibility of the CALDB manager to inform users when files have been retired from the CALDB. In general, it is unnecessary to remove files from the database unless there are disk space issues; files are simply marked as bad instead (see the Quality Keyword section). Retired files will be removed from the CALDB tarfiles on integral version updates (e.g. 3.0, 4.0).