[QUANTIT] Use-cases, role in larger scheme

David Berry dsb at ast.man.ac.uk
Mon Nov 17 07:48:07 PST 2003


Jonathan,

> > Also, it seems obvious to me that a Quantity will need to carry around
> > information about the location of the data values in any relevant
> > coordinate systems (i.e. "WCS" in the broadest sense). Without this how
> > are we going to compare Quantities (for instance, to re-project a set of
> > images onto a common projection)?
> >
>
> I don't find this obvious at all. It's only obvious if
> Quantity == 'image', but in all our earlier discussion Quantity << 'image'.
> There are many operations on data arrays which don't require the
> coordinate systems. I think the Quantity-with-other-physical-things-along
> -its-axes should be a higher level object (the one we've been calling
> Measurement).

I agree that not all Quantities will need WCS (a Quantity holding a list
of (RA,Dec) pairs would be an example). But unless you can say that *no*
Quantities will need WCS, it at least needs to be in there as an option.

I suppose there are two approaches. One would be to define a separate
class for each combination of components. If a basic Quantity was simply
an N-d array (or similar structure), we could define classes
QuantityWithUnits, QuantityWithWCS, QuantityWithUnitsAndWcs, etc. The
other approach is to say that the Quantity class encapsulates all
these extra components, but that any of these components may be null.

I think the second approach would be the easiest and most flexible in the
long run.

David

----------------------------------------------------------------------
Dr David S. Berry    (dsb at ast.man.ac.uk)

STARLINK project		 |	Centre for Astrophysics
(http://www.starlink.ac.uk/)	 |	University of Central Lancashire
Rutherford Appleton Laboratory	 |	PRESTON
DIDCOT				 |	United Kingdom
United Kingdom			 |	PR1 2HE
OX11 0QX



More information about the dm mailing list