[fitsbits] Inheritence diagram for FITS HDUs
William Pence
pence at tetra.gsfc.nasa.gov
Mon Mar 4 14:49:02 EST 2002
Paul Barrett wrote:
>
> This is a novel way of looking at FITS files, but what about the HDUs that don't
> fit into these common classes, e.g. Conforming Extensions which are valid HDUs,
> but are considered non-standard, or NonConforming HDUs which for illustration
> has the SIMPLE keyword set to FALSE, but the header still provides enough
> information to determine the size of the header and data areas. These
> situations don't appear to be covered in your example and the FITS standard
> seems to gloss over them. How would might they fit in?
Your first case, a non-standard, conforming extension, would by definition
be an extension that *does* have the mandatory keywords needed to determine
the length of the extension (BITPIX, NAXIS, NAXISn, PCOUNT, GCOUNT) but
whose organization and content are *not* specified in the FITS Standard
(i.e, it does not have XTENSION = 'TABLE', 'BINTABLE', or 'IMAGE'). Since
in general the FITS reading software will not know how to interpret the data
records in this case, there is probably very little it can do with the
extension other then a) operate on individual keyword values, b) skip over
the extension and try to read the next one, or c) copy the extension
verbatim to another FITS file. In the inheritance diagram, these
'non-standard, conforming' HDUs would be on a separate main branch, separate
from the 'standard, conforming' HDUs.
Your second case, a FITS file that begins with SIMPLE = F, is more difficult
to generalize because there is no a priori way to tell how severely the FITS
file deviates from the Standard. It could be a minor infraction of the
rules (e.g., the fill bytes following the last data record do not = 0), or
it could be so major that most FITS reading software would be unable to
parse the header at all. Rather than simply giving up when it finds SIMPLE
= F, general FITS readers should probably ignore this flag and continue to
read the file the same as if SIMPLE = T, and only abort if it finds
something else that it cannot understand. I think the value of the SIMPLE
keyword, by itself, should make no difference in where the HDU is located in
the inheritance diagram.
-Bill
--
____________________________________________________________________
Dr. William Pence pence at tetra.gsfc.nasa.gov
NASA/GSFC Code 662 HEASARC +1-301-286-4599 (voice)
Greenbelt MD 20771 +1-301-286-1684 (fax)
More information about the fitsbits
mailing list