gnuastro-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[gnuastro-devel] [sr #109223] Change default WCS formalism from PCi_j to


From: Mohammad Akhlaghi
Subject: [gnuastro-devel] [sr #109223] Change default WCS formalism from PCi_j to CDi_j
Date: Wed, 18 Jan 2017 02:39:57 +0000 (UTC)
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:50.0) Gecko/20100101 Firefox/50.0

Follow-up Comment #1, sr #109223 (project gnuastro):

Thanks for this very intriguing suggestion. Indeed the `CDi_j' formalism is
the most common in most imaging archives. 

This is what the WCSLIB manual says under `wcsprm::altin':

"These alternate specifications of the linear transformation matrix are
translated immediately to PCi_ja by wcsset() and are invisible to the
lower-level WCSLIB routines. In particular, wcsset() resets wcsprm::cdelt to
unity if CDi_ja is present (and no PCi_ja )."

I couldn't find any better explanation. I would guess that since WCSLIB is
intended for any kind of data (not just 2D images), for example spectra, 3D
data cubes, wide full-sky surveys, and etc, it has chosen this formalism since
the scale is separate and more clearly defined. I should just add that with
the fix to bug #50073, the `CDELTi's in the `PCi_j' formalism are corrected. 

Ultimately, if its not possible to tell WCSLIB to print the CD matrix, it is
not hard to manually change the `PCi_j' and `CDELTi' key words to `CDi_j'
immediately before saving then in the FITS. I am just slightly concerned
because WCSLIB has already been written to be the most general library for the
job, taking the most general applications in mind. But here, we are only
focused on 2D imaging surveys. This is also the type of data I deal with most,
but we don't want to limit Gnuastro to this type of data.

Just for reference the conversion from `wcsprm' to text is done by the call to
`wcshdo' in `lib/fits.c' and `gal_fits_add_wcs_to_header' is in charge of
writing that text into the output FITS header. Some corrections can be done in
either of these two steps (before writing into the FITS or after it).

So, let's keep this discussion going on here (not in the task tracker, so
everyone can easily post comments). Please share your thoughts on what the
best way forward can be.

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/support/?109223>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]