[iaufwg] Final FITS review comments

Mark Calabretta mcalabre at atnf.csiro.au
Tue Apr 15 21:04:23 EDT 2008


On Tue 2008/04/15 13:38:30 -0400, William Pence wrote
in a message to: IAU-FWG <iaufwg at nrao.edu>

Dear Bill,

>software developers.  I think Mark originally had in mind simply 
>flagging any previous changes to the FITS syntax that software 
>developers should be aware of when write FITS reading software.  This 
>would presumably be a very short list.

That is correct.

What I had in mind is a practical guide for intending authors of FITS
reading software of anomalies (compared to the current standard) that
might be found in historical FITS files.  This list will be short and,
in the first instance, need not be exhaustive because in practice such
anomalies should occur rarely if at all.

In fact, much of the work has already been done.  It is presented in
Appendix E of FITS 2.1b.  However, this contains much of incidental
interest only since it lists extensions as well as restrictions of the
standard.

Of the latter, which is what concern us, I note the following examples:

   8. §5.1.2.1 Keyword (as header component)
      The specification of permissible keyword characters is new.  The
      FITS papers do not precisely define the permissible characters for
      keywords.

Wells, Greisen & Harten (1981) states "The keyword is an 8-character
ASCII string ... Lower case ASCII characters may not appear in the
keyword and value fields" which may reasonably be inferred to mean that
keywords must only contain upper-case letters.  In fact, though, it does
not preclude keywords containing digits, punctuation characters or even
unprintable characters (indeed, digits and hyphens are shown in the
example headers).  It is therefore possible that archival FITS files
might contain keywords such as "POL%".  It would be noted that this
usage is unknown in practice.

  10. §5.1.2.3 Value/Comment (bytes 11–80)
      In the FITS papers, the slash between the value and comment is
      optional.  This standard requires the slash, consistent with the
      prescription of FORTRAN-77 list-directed input.

The example often cited.  It would be noted that this usage is unknown
in practice.

  11. §5.2 Value, including its subsections
      [...]  The FITS papers permit the value field to
      contain an array of values.  This standard specifies that there
      shall be only one value in the value field.  [...]

I don't think that this is true.  If it is, it needs to be referenced
and recorded.

  15. §5.2.5 Complex Integer Number
      The standard does not support the fixed format for complex
      integers defined in the FITS papers but is consistent with
      FORTRAN-77 list-directed read as required in the FITS papers for
      free format.  Because the fixed format of the FITS papers did not
      conform to the rules for FORTRAN-77 list-directed I/O, consistency
      with both was impossible. There are no known FITS files that use
      the fixed format for complex integers that was defined in the FITS
      papers.

  16. §5.2.6 Complex Floating Point Number
      The standard does not support the fixed format for complex
      floating point numbers defined in the FITS papers but is
      consistent with FORTRAN-77 list-directed read as required in the
      FITS papers for free format. Because the fixed format of the FITS
      papers did not conform to the rules for FORTRAN-77 list-directed
      I/O, consistency with both was impossible.  There are no known
      FITS files that use the fixed format for complex floating point
      numbers that was defined in the FITS papers.

These observations should be preserved.

  18. §5.4.1.1 Principal (mandatory keywords)
      (a) SIMPLE keyword — The explicit prohibition against the
          appearance of the SIMPLE keyword in extensions does not appear
          in the FITS papers.

      (b) NAXIS keyword — The requirement that the NAXIS keyword may not
          be negative is not explicitly specified in the FITS papers.

      (c) NAXISn keyword — The requirement that the NAXISn keyword may
          not be negative is not explicitly specified in the FITS
          papers.

There is a reasonable likelihood that (a) has been violated in some
archival FITS files.  Points (b) and (c) are interesting in the current
context; though the original FITS papers did not define a meaning for
negative NAXIS they did not preclude it either, and in FITS anything
that is not forbidden is allowed.  Therefore, what was once implicitly
allowed is now explicitly forbidden.  This is being pedantic, of course,
but there is no reason not to preserve this observation together with a
comment on the unlikelihood of its occurence.

The above list is not exhaustive, however it's likely to comprise a good
fraction of what I would expect to see in the desired appendix - and it
only took one person 30min to produce.  (BTW, I'm not volunteering for
this effort as I feel that my time is better spent on FITS WCS related
matters.)

I believe the notes should be in an appendix, though specific points
should be referenced at the appropriate place in the text.

Regards, Mark





More information about the iaufwg mailing list