Astro-TIFF specification 1.0.  Dated 2022-06-21
 

Introduction

This specification describes for astronomy a standardised method to store the full FITS file information including the header inside a standard TIFF file.


Purpose

Guaranteed interchangeability between astronomical applications. Conversion between FITS and TIFF files is possible without loosing the FITS header information.


Benefits
  1. The TIFF compression algorithm makes the files smaller
  2. The files are readable by almost any image viewer.


Specification
  1. Files are following the TIFF 6.0 specification including supplement 2 fully.
  2. The FITS header is written to the TIFF baseline tag "Image Description". Code 270, Hex 010E.
  3. The header is following the FITS specification except that that the lines can be shorter then 80 characters and lines are ending with either CR+LF (0D0A) or LF (0A).
  4. First line in the description is the first header line and starts with SIMPLE. The last line of the header starts with END.


Recommendations
  1. TIFFtag_orientation=1  (left-top)  Orientation is following the conventions. Pixel FITS_image[1,1] is left-bottom. TIFF_image[0,0] is left-top. These pixels are first written or read from the file. So when writing a FITS image into TIFF preserving the orientation for the user, the first pixel to write is FITS_image[1,NAXIS2].
  2. TIFFtag_compression=8 (Deflate) or 5 (LZW)
  3. For greyscale images TIFFtag_PhotometricInterpretation = 1 (minimum value is black, maximum is white)
  4. Write all available header keywords.


Sample files

Astro-TIFF file M96 including the astrometric (plate) solution with CR+LF

Astro-TIFF file M96 including the astrometric (plate) solution with only LF

Astro-TIFF file M65 M66 with minimal header only, no keywords BITPIX, NAXIS, NAXIS1, NAXIS2, BZERO


Astro-TIFF file of an IC434 OSC image with key BAYERPAT='RGGB'  and solution in the header

Astro-TIFF file of a M81 OSC image with key BAYERPAT='GBRG' and solution in the header

Astro-TIFF file NGC2024, rare example of 3x16 = 48 bit colour usage



Notes

This use of TIFF format is intended for 16 bit lights, darks, flats and flat-darks (astronomical images).

It is possible to convert FITS to TIFF and backwards but the application programmer can decide to export only (write) or only import (read) in Astro-TIFF format.

If an astrometrical (plate) solution is included then it should match with the image orientation.

Some header keywords are redundant like NAXIS1, NAXIS2, BZERO and BITPIX and not required. TIFF image dimensions and type are leading.

The de-mosaic pattern specified in the header should match with the image orientation.

The header will be visible in many image manipulation programs:



Some image programs could crop the description when saved again.


External links:

Astro-TIFF project: https://sourceforge.net/projects/astro-tiff/

FITS:  https://fits.gsfc.nasa.gov/fits_standard.html
TIFF:  https://en.wikipedia.org/wiki/TIFF
TIFF documentation: http://download.osgeo.org/libtiff/doc/


History

2022-02-19, First draft.
2022-03-15, Some cosmetic corrections.
2022-06-21, Final v1.0. No changes.


Programs compatible with Astro-TIFF:

These programs will be in the near future or are already supporting ASTRO-TIFF:
 

This page:
https://astro-tiff.sourceforge.io/

Feedback, comments contact: this forum or email