Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes for bounding box units #554

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

WilliamJamieson
Copy link
Collaborator

This PR attempts to fix some issues related to having bounding boxes with units in GWCS. In particular it fixes the WCS.invert failing in this case and WCS.to_fits.

Resolves #408.

CC @pllim, @bmorris3

@WilliamJamieson WilliamJamieson requested a review from a team as a code owner January 31, 2025 16:42
Copy link

codecov bot commented Jan 31, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 85.96%. Comparing base (877716d) to head (f391f14).
Report is 8 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #554      +/-   ##
==========================================
+ Coverage   85.41%   85.96%   +0.54%     
==========================================
  Files          22       27       +5     
  Lines        3957     4025      +68     
==========================================
+ Hits         3380     3460      +80     
+ Misses        577      565      -12     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@WilliamJamieson WilliamJamieson requested a review from nden January 31, 2025 16:45
@WilliamJamieson
Copy link
Collaborator Author

This is a bit of a hack job, especially in the to_fits. However, I don't think the to_fits code was ever designed to work with units to begin with, so I was just patching things so that when units are required or not the appropriate casting took place

@pllim
Copy link
Contributor

pllim commented Jan 31, 2025

I have no recollection of the issue I opened 3 years ago. 😆

But I did test this branch downstream at spacetelescope/jdaviz#3417 and it was satisfactory. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

BUG: to_fits bounding_box does not work with units
2 participants