Subject: FITS error test files

From: bschlesinger at nssdca.gsfc.nasa.gov (Barry Schlesinger)
Date: Mon, 20 Jul 1992 21:40:00 GMT

In response to the requests at the Columbus meeting of the
WGAS, a number of "FITS" files originally created to test the NOST
FITS Product Conformance Tester (FPCT) are now available.  These files
provide an opportunity to test the ability of FITS readers to cope
with errors in primary headers of the input files. All the files
except one are variations on a theme; they are the same except that
different kinds of errors have been introduced.  Some types of errors
included are improper keyword order, incorrect card image syntax, and
incorrect values.  The remaining file is designed to test the response
of software to a file that doesn't even resemble FITS, as might occur
if the software were used by mistake on the wrong file. 

	These files are available from nssdca.gsfc.nasa.gov by anonymous
ftp or by DECnet copy from NSSDCA. They are in the FITS directory,
ERRTEST subdirectory.  NSSDCA is a VAX; case is not significant.  The
README.FIRST file describes the others in more detail. 

	Answers to any questions, and copies of the prototype FPCT
itself, can be obtained from the FITS Support Office: 

	Internet: fits at nssdca.gsfc.nasa.gov
	DECnet NCF::FITS
	Telephone: (301)513-1634 

				Barry Schlesinger
				Coordinator
				FITS Support Office

---

From: bhill at stars.gsfc.nasa.gov (Robert S. Hill)
Date: Mon, 20 Jul 1992 21:52:00 GMT

In article <20JUL199216405756 at nssdca.gsfc.nasa.gov>, 
bschlesinger at nssdca.gsfc.nasa.gov (Barry Schlesinger) writes...
>FITS Product Conformance Tester (FPCT) are now available.  These files

Inquiring minds want to know:  is the FPCT itself available?

------------------------------------------------------------------------
Robert S. Hill                  | Internet:  BHILL at STARS.GSFC.NASA.GOV
Hughes STX Corp.                | Phone:     301/286-3624
------------------------------------------------------------------------

---

From: bschlesinger at nssdca.gsfc.nasa.gov (Barry Schlesinger)
Date: 21 Jul 92 19:04:00 GMT

In article <20JUL199216523472 at stars.gsfc.nasa.gov>, bhill at stars.gsfc.nasa.gov (Robert S. Hill) writes...
>Inquiring minds want to know:  is the FPCT itself available?

	A prototype of the first build is available for testing, to check for 
portability and errors.  The first build is limited to 

	Primary HDU
	Integer data
	Twos complement

	Copies can be obtained from the FITS Support Office

					Barry Schlesinger

---

From: pence at heawk1.gsfc.nasa.gov ( William Pence)
Date: 22 Jul 92 17:36:45 GMT

I tried reading the test defective FITS files  generated by Barry
Schlesinger (see previous post to this newsgroup) to see if the FITSIO
subroutine package detected the errors.   I tried reading each pseudo
FITS file with a simple program that just lists the header of a FITS
file.  The following list shows the error message that was returned by
FITSIO for each file.   FITSIO did very well and found all the errors,
except one:  it didn't complain if the first keyword was 'SIMPLE =
W';  it just assumed that if SIMPLE was not true, then it must be false.
I'll add this check to the next version of FITSIO.

-Bill Pence
--------------------------------------------------------------------------

List of error responses generated by FITSIO when trying to read test defective
FITS files generated by Barry Schlesinger

FILENAME       FITSIO RESPONSE
--------       ---------------
good.tst
        No errors detected; OK since this is a legal FITS file

different.tst:
	Error Status Returned :  210
	Missing "= " in cols 9-10

nosimple.tst
	Error Status Returned :  221
	SIMPLE keyword not found

simplew.tst
        No errors detected;  didn't detect SIMPLE = W;  FITSIO should
        have complained about this.

simplef.tst
        No errors detected;  didn't complain about SIMPLE = F; OK

bitpixq2
	Error Status Returned :  211
	Illegal BITPIX keyword value

bitpix13
	Error Status Returned :  211
	Illegal BITPIX keyword value

noequal.tst
	Error Status Returned :  210
	Missing "= " in cols 9-10

qin10.tst
	Error Status Returned :  210
	Missing "= " in cols 9-10

extraxis.tst
	No errors detected;  OK since this is a legal FITS file

missaxis.tst
	Error Status Returned :  224
	NAXISnnn keywords not found

simple2nd.tst
	Error Status Returned :  210
	Missing "= " in cols 9-10

shuffle.tst
	Error Status Returned :  222
	BITPIX keyword not found

latenaxis.tst
	Error Status Returned :  223
	NAXIS  keyword not found

endequal.tst
	No errors detected;  OK since this is a legal FITS file (?).

---

From: bschlesinger at nssdca.gsfc.nasa.gov (Barry Schlesinger)
Date: 23 Jul 92 13:59:00 GMT

In article <pence.711826605 at heawk1>, pence at heawk1.gsfc.nasa.gov ( William Pence) writes...
>I'll add this check to the next version of FITSIO.

This is something of an understatement, as the file isn't close to 
FITS.

> ... [results for other files] ...
.
>	Error Status Returned :  222

Actually there is a BITPIX keyword in the file, just in the wrong 
place.  But a reader shouldn't be expected to find it.

>	Error Status Returned :  223

As above.

>	No errors detected;  OK since this is a legal FITS file (?).

Not exactly.  The = in column 9 of the END card image shouldn't be
there.  Readers probably should provide a warning.  Validation
software certainly should.  As is noted in the README.FIRST, Don Wells
reports that some readers have crashed on this syntax. 

				Barry Schlesinger
				FITS Support Office