|
|
Matching CIAO and CALDB VersionsCALDB 3.5.0 should not be used unless you are running CIAO 3.4 or CIAO 4.0. Are your versions mismatched? Time to update CIAO and CALDB!
23 Jun 2008 23 Jun 2008 CalDB 3.4.5, an upgrade to CalDB 3.3.0 or later versions, which includes only ACIS -120C EPOCH 33 (Feb - Apr 08) T_GAIN updates, has been released to the public. See the CalDB 3.4.5 release notes for more information on this upgrade.31 Mar 2008 CalDB 3.4.3, an upgrade to CalDB 3.3.0 or later versions, which introduces ACIS -110C "Epoch 0" T_GAINs for ACIS-S1 and -S3, and ACIS -120C EPOCH 32 (Nov 07 - Jan 08) T_GAIN updates, has been released to the public. See the CalDB 3.4.3 release notes for more information on this upgrade.14 Dec 2007 CalDB 3.4.2, an upgrade to CalDB 3.3.0 or later versions, which updates ACIS T_GAINs for Aug - Oct 2007, has been released to the public. See the CalDB 3.4.2 release notes for more information on this upgrade.14 Sep 2007 CalDB 3.4.1, an upgrade to CalDB 3.3.0 or later versions, which introduces new and finalized ACIS blank sky, T_GAIN, and HRC-I DEGAP files, has been released to the public. See the CalDB 3.4.1 release notes for more information on this upgrade.16 May 2007 CalDB 3.4.0, an upgrade to CalDB 3.3.0/3.3.0.1, which introduces new ACIS T_GAIN, grating mask files, as well as upgrades to HRC-I GMAPS and HRC-S QE, has been released to the public. See the CalDB 3.4.0 release notes for more information on this upgrade. |
Querying the CALDBMany of the CIAO tools - such as acis_process_events, mkwarf, and tg_resolve_events - access the CALDB in order to obtain calibration files to apply to the data. Instead of requiring the user to specify the exact filename and path, the tools use header information and other parameter values to find the necessary files from the CALDB. It is also possible to query the CALDB directly. There are three pieces of information that are needed:
The sections below descibe three methods you can use to access the CALDB: quizcaldbThe quizcaldb tool allows you to query the CALDB for a file from the command line. The parameters of the tool are used to set up the information needed by CALDB, and the matching file - if there is one - is printed to the screen and stored in the outfile parameter of the tool. For example, to find the ACIS gainmap for an observation taken on 15 December 2001:
unix% quizcaldb infile="none" mission="chandra" instrument="ACIS" \
detector="-" date="2001-12-15" time="00:00:00" filter="-" \
codename="DET_GAIN" expr="-"
/soft/ciao/CALDB/data/chandra/acis/bcf/gain/acisD2000-08-12gainN0003.fits[AXAF_DETGAIN]
unix% pget quizcaldb outfile
/soft/ciao/CALDB/data/chandra/acis/bcf/gain/acisD2000-08-12gainN0003.fits[AXAF_DETGAIN]
The path to the file begins with the contents of the $CALDB environment variable; for this example this is /soft/ciao/CALDB. Note that specifying the instrument automatically selects the branch index file in which to search for the desired file and extension. The extension (AXAF_DETGAIN in this example) is included with the output filename and path of the requested calibration file. The quizcaldb help file has more examples, including using a file as input and specifying boundary conditions. S-Lang InterfaceThe "caldb" module is a S-Lang interface to the CALDB library. The caldb ahelp page describes how the module can be used, and there are also ahelp pages for the individual functions in the module. One way to use the module to find the ACIS-S gainmap for an observation taken on 15 December 2001 is:
chips> import("caldb")
chips> cal = calCreateInfo()
chips> calSetTelescope( cal, "Chandra" )
chips> calSetInstrument( cal, "ACIS" )
chips> calSetData( cal, "DET_GAIN" )
chips> calSetDate( cal, "2001-12-15T00:00:00" )
chips> calFindFile( cal )
/soft/ciao/CALDB/data/chandra/acis/bcf/gain/acisD2000-08-12gainN0003.fits[AXAF_DETGAIN]
FTOOLSThe FTOOLS commands for the CALDB can be seen using the command "fhelp caltools". The commands of interest for a user include quzcif and caldbinfo. In order to use the CALDB, you must have the environment variables $CALDB, $CALDBALIAS, and $CALDBCONFIG defined. If your copy of the CALDB exists under /data/CALDB, then sourcing the script /data/CALDB/software/tools/caldbinit.unix will set up those environment variables and enable you to access files with the FTOOL quzcif. quzcif is the basic routine used for selecting a file from the CALDB index. You can learn about the full form of this command, including how to invoke a bounded coordinate value, by using the fhelp quzcif command. The general form for the command is: unix% quzcif telescop instrume detnam filter ccname yyyy-mm-dd hh:mm:ss boundaries To omit searching on a given element, substitute a dash (-). For example, to get the gain file for an observation taken on Sept 30, 1999, you would enter: unix% quzcif chandra acis - - det_gain 1999-09-30 00:00:00 - /data/CALDB/data/chandra/acis/bcf/gain/acisD1999-09-16gainN0004.fits 1 The tool returns the file it located which matches the requested conditions, as well as the extension number (1) of the dataset. |
![]() |
The Chandra X-Ray
Center (CXC) is operated for NASA by the Smithsonian Astrophysical Observatory. 60 Garden Street, Cambridge, MA 02138 USA. Email: cxcweb@head.cfa.harvard.edu Smithsonian Institution, Copyright © 1998-2004. All rights reserved. |