Next: Identifying Foreign Encodings on Input
Up: Using Foreign FITS Encodings
Previous: The Foreign FITS Encodings
The foreign encodings available for storing WCS information in FITS
headers have a number of limitations when compared with the native
encoding of AST Objects (
). The main ones are:
- 1.
- Only one class of AST Object, the FrameSet, may be represented
using a foreign FITS encoding. This should not come as a surprise,
because the purpose of storing WCS information in FITS headers is to
attach coordinate systems to an associated array of data. Since the
FrameSet is the AST Object designed for the same purpose
(
), there is a natural correspondence.
The way in which a FrameSet is translated to and from the foreign
encoding also follows from this correspondence. The FrameSet's base
Frame identifies the data grid coordinates of the associated FITS
data. These are the same as FITS pixel coordinates, in which the first
pixel (in 2 dimensions) has coordinates (1,1) at its
centre. Similarly, the current Frame of the FrameSet identifies the
FITS world coordinate system associated with the data.
- 2.
- You may store a representation of only a single FrameSet in any
individual set of FITS header cards (i.e. in a single
FitsChan) at one time. If you attempt to store more than one, you may
over-write the previous one or generate an invalid representation of
your WCS information.
This is mainly a consequence of the use of fixed FITS keywords by
foreign encodings and the fact that you cannot, in general, have
multiple FITS cards with the same keyword.
- 3.
- In general, it will not be possible to store every possible
FrameSet that you might construct. Depending on the encoding, only
certain FrameSets that conform to particular restrictions can be
represented and, even then, some of their information may be lost. See
the description of the Encoding attribute in
for more details of these
limitations.
It should be understood that using foreign encodings to read and write
information held in AST Objects is essentially a process of converting
the data format. As such, it potentially suffers from the same
problems faced by all such processes, i.e. differences between
the AST data model and that of the foreign encoding may cause some
information to be lost. Because the AST model is extremely flexible,
however, any data loss can largely be eliminated when reading.
Instead, this effect manifests itself in the form of the above
encoding-dependent restrictions on the kind of AST Objects which may
be written.
One of the aims of the AST library, of course, is to insulate you from
the details of these foreign encodings and the restrictions they
impose. We will see shortly, therefore, how AST provides a mechanism
for determining whether your WCS information satisfies the necessary
conditions and allows you to make an automatic choice of which
encoding to use.
Next: Identifying Foreign Encodings on Input
Up: Using Foreign FITS Encodings
Previous: The Foreign FITS Encodings
AST A Library for Handling World Coordinate Systems in Astronomy
Starlink User Note 210
R.F. Warren-Smith & D.S. Berry
30th April 2003
E-mail:ussc@star.rl.ac.uk
Copyright (C) 2003 Central Laboratory of the Research Councils