fix WCS computation, cdelt should not be sorted

fix rebase display on main
This commit is contained in:
2025-04-01 17:02:31 +02:00
parent 8bfaee25fb
commit 1193b2b091
2 changed files with 2 additions and 2 deletions

View File

@@ -16,7 +16,7 @@ from astropy.io import fits
from astropy.wcs import WCS
from .convex_hull import clean_ROI
from .utils import wcs_PA
from .utils import wcs_PA, princ_angle
def get_obs_data(infiles, data_folder="", compute_flux=False):

View File

@@ -177,4 +177,4 @@ def wcs_PA(PC21, PC22):
orient = np.arccos(PC22) * 180.0 / np.pi
elif (abs(PC21) < abs(PC22)) and (PC22 < 0):
orient = -np.arccos(PC22) * 180.0 / np.pi
return orient
return princ_angle(orient)