bug-gnuastro
[Top][All Lists]
Advanced

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

Re: wcscoordsys to eq-j2000 does not work


From: Mohammad Akhlaghi
Subject: Re: wcscoordsys to eq-j2000 does not work
Date: Fri, 11 Nov 2022 20:10:24 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.4.2

Hi Alex,

Thanks a lot for reporting this problem, it has been fixed (by updating the 'EQUINOX' keyword, see below) in the following commit:

https://git.savannah.gnu.org/cgit/gnuastro.git/commit/?id=470d4434ab

You can get the latest Gnuastro version with this bug fix from http://akhlaghi.org/gnuastro-latest.tar.lz

The keywords of the output files had indeed changed (here I am running 'astfits' on the two files that you had uploaded). To visually see this change better, we'll first write the header keywords in plain-text files:

$ astfits NGC6946_scaled.fits -h1 > NGC6946_scaled.txt

$ astfits NGC6946_scaled-eq-j2000.fits -h1 > NGC6946_scaled-eq-j2000.txt

Then we can look at the differing lines between the two files. You see that the 'CRVAL1' (RA of reference point), 'CRVAL2' (Dec of reference point), 'LONPOLE' (longitude of the pole) and 'LATPOLE' (latitute of pole) have indeed changed significantly (on the scale of half a degree in some cases!). You also see that 'RADESYS' (RA/Dec System) has also been changed from 'FK4' to 'FK5'.



$ diff NGC6946_scaled.txt NGC6946_scaled-eq-j2000.txt
22,25c22,25
< CRVAL1 = 308.45 / [deg] Coordinate value at reference point < CRVAL2 = 59.98333333 / [deg] Coordinate value at reference point < LONPOLE = 180.0 / [deg] Native longitude of celestial pole < LATPOLE = 59.98333333 / [deg] Native latitude of celestial pole
---
> CRVAL1 = 308.702781271596 / [deg] Coordinate value at reference point > CRVAL2 = 60.1568349215312 / [deg] Coordinate value at reference point > LONPOLE = 179.564003507 / [deg] Native longitude of celestial pole > LATPOLE = 60.1568349215 / [deg] Native latitude of celestial pole
29c29
< RADESYS = 'FK4' / Equatorial coordinate system
---
> RADESYS = 'FK5'                / Equatorial coordinate system



The confusion was caused by the 'EQUINOX' keyword not being changed (the output still had a vale of '1950.0'). So with the commit above, Gnuastro now also updates that (as it should have).

Once you install the latest version you will notice that the only difference is in the value of 'EQUINOX' (all the other numbers will be the same as the output you sent). This is because the main keyword in this aspect is the 'RADESYS' one (which was correctly set before also: so in case of conflict 'RADESYS' has priority over 'EQUINOX').

Cheers,
Mohammad



reply via email to

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