Документ взят из кэша поисковой машины. Адрес
оригинального документа
: http://www.stsci.edu/documents/dhb/web/c02_datafiles.fm3.html
Дата изменения: Wed Jul 1 20:35:18 1998 Дата индексирования: Sat Dec 22 15:35:33 2007 Кодировка: Поисковые слова: chandra |
The binary content of GEIS files is machine dependent. Copying GEIS files
directly from one platform to another (e.g., from a VAX to a Sun) may result in
unreadable data.
Figure 2.3: GEIS File Structure
2.3.1 Converting FITS to GEIS
The STScI archive stores and distributes datasets from FOC, FOS, FGS, GHRS, HSP, WF/PC-1, and WFPC2 in a special archival FITS format. We highly recommend that users convert these datasets back into their native GEIS format before working with them. Your data must be in GEIS format for you to use many of the STSDAS software tools developed specifically for analysis of these data. It is important to use the strfits task found in stsdas.fitsio or in tables.fitsio to perform the conversion from archival FITS format to the GEIS format because the data-processing pipeline employs a special convention for mapping GEIS files to FITS format. While other FITS readers may be able to read portions of the data correctly, they are unlikely to reconstruct the entire data file properly.
cl> set imtype=hhhThis command tells IRAF to write output files in GEIS format. You then need to set the strfits parameters xdimtogf and oldirafname both to "yes". For example, after you have set imtype = hhh, you can convert the FITS file *_hhf.fits into the GEIS format files *.hhh and *.hhd by typing:
cl> strfits *_hhf.fits iraf_fil="" xdim=yes oldiraf=yes
The number of groups produced by a given observation depends upon the instrument configuration, the observing mode, and the observing parameters. Table 2.1 lists the contents and the number of groups in the final calibrated image for the most commonly-used modes of each instrument.
2.3.3 Working with GEIS Files
This section briefly explains how to work with information in GEIS header and data files. GEIS Headers
Header keyword information relevant to each group of a GEIS file resides in two places, the header file itself and the parameter block associated with the group. Because GEIS header files are composed solely of ASCII text, they are easy to print using standard Unix or VMS text-handling facilities. However, the group parameters are stored in the binary data file. To access them you need to use a task such as imheader, as shown on page 2-13.
You can use the IRAF hedit task to edit the keywords in GEIS headers. While it it possible to edit GEIS header files using standard Unix and VMS text editors, you must maintain their standard 80-character line length. The hedit task automatically preserves this line length. If you need to add or delete group parameters, you can use the STSDAS groupmod task in the stsdas.hst_calib.ctools package. The STSDAS chcalpar task, described in more detail in the Calibration chapters for each instrument, is useful for updating header keywords containing calibration switches and calibration reference files.
Always edit headers using tasks like hedit, eheader, and chcalpar. Editing headers
with a standard text editor may corrupt the files by creating incorrect line
lengths.
GEIS Data Files
Numerous IRAF/STSDAS tasks exist for working with GEIS images (see Chapter 3). Most of these tasks operate on only one image at a time, so you usually need to specify which group of a GEIS file is to be processed. If you do not specify a group, your task will choose the first group by default. Specifying a Group
To specify a particular group in a GEIS file, append the desired group number in square brackets to the file name (e.g., z2bd010ft.d0h[10]). For example, to apply the imarith task to group 10 of a GEIS image, type the following:
cl> imarith indata.hhh[10] + 77.0 outdata.hhhThis command will add 77.0 to the data in group 10 of the file indata.hhh, and will write the output to a new single-group file called outdata.hhh. Any operation performed on a single group of a multigroup GEIS file results in an output file containing a single group.
cl> imarith indata.hhh[2][100:199,200:399] * 32.0 outdata.hhhThis command extracts a 100 by 200 pixel subsection of the image in the second group of the file indata.hhh, multiplies this data by a factor of 32.0, and stores the result in a new output file, outdata.hhh, which is a 100 by 200 pixel single group GEIS file.
cl> imhead indata.hhhThe output line indicates that indata.hhh is a multigroup GEIS file which contains 64 groups of images, each consisting of a spectral array 500 pixels in length. The data type of the values is real (floating point). Note that since no group designation was provided, the task defaulted to the first group. To reveal more information regarding group 10, you can type:
indata.hhh[1/64][500][real]: INDATA[1/64]
cl> imhead indata.hhh[10] long+ | pagewhich will generate a long listing of both the ASCII header parameters in the *.hhh file and the specific GPB parameters for group 10 from the *.hhd file.
stevens@stsci.edu Copyright © 1997, Association of Universities for Research in Astronomy. All rights reserved. Last updated: 07/01/98 08:36:06