-
Notifications
You must be signed in to change notification settings - Fork 75
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
Fix unit conversion of limits from Fnu to Flam #2889
Merged
gibsongreen
merged 4 commits into
spacetelescope:main
from
astrofrog:fix-limits-fnu-flam
May 31, 2024
Merged
Fix unit conversion of limits from Fnu to Flam #2889
gibsongreen
merged 4 commits into
spacetelescope:main
from
astrofrog:fix-limits-fnu-flam
May 31, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
astrofrog
requested review from
rosteen,
javerbukh,
pllim,
kecnry,
bmorris3,
haticekaratay,
cshanahan1 and
gibsongreen
as code owners
May 22, 2024 11:44
astrofrog
force-pushed
the
fix-limits-fnu-flam
branch
from
May 22, 2024 11:46
99f67ed
to
1f60685
Compare
Draft
9 tasks
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #2889 +/- ##
=======================================
Coverage 88.70% 88.70%
=======================================
Files 111 111
Lines 17132 17134 +2
=======================================
+ Hits 15197 15199 +2
Misses 1935 1935 ☔ View full report in Codecov by Sentry. |
pllim
reviewed
May 22, 2024
pllim
reviewed
May 22, 2024
9 tasks
gibsongreen
force-pushed
the
fix-limits-fnu-flam
branch
from
May 30, 2024 20:08
1f60685
to
d599b31
Compare
gibsongreen
force-pushed
the
fix-limits-fnu-flam
branch
from
May 31, 2024 18:27
d599b31
to
77fe6db
Compare
gibsongreen
approved these changes
May 31, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note:
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
I have expanded the test suite for
to_unit
and found that an error occurred when converting limits from Fnu to Flam. The issue in this specific case was thatif '_pixel_scale_factor' in spec.meta:
wasTrue
so the clause relating tolen(values)==2
was never invoked, resulting in an issue with incompatible dimensions.In addition to fixing this logic, I have made it so that we just use one wavelength/frequency in this case for the conversion, as it doesn't specifically make sense to use the first and last spectral axis value. When converting limits we are probably interested in the values being right at the start of the spectral axis.
This builds on top of #2888 and should be rebased once #2888 is merged.
Change log entry
CHANGES.rst
? If you want to avoid merge conflicts,list the proposed change log here for review and add to
CHANGES.rst
before merge. If no, maintainershould add a
no-changelog-entry-needed
label.Checklist for package maintainer(s)
This checklist is meant to remind the package maintainer(s) who will review this pull request of some common things to look for. This list is not exhaustive.
trivial
label.