-
Notifications
You must be signed in to change notification settings - Fork 32
Rescale resample kernels by pixel scale ratio #2009
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
base: main
Are you sure you want to change the base?
Conversation
|
Regression tests: https://github.com/spacetelescope/RegressionTests/actions/runs/18666992170 Tests are passing |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2009 +/- ##
==========================================
- Coverage 78.92% 76.11% -2.81%
==========================================
Files 138 138
Lines 8224 8224
==========================================
- Hits 6491 6260 -231
- Misses 1733 1964 +231 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Unit tests will fail unless I modify |
| exptime=1.0, | ||
| scale=1.0, | ||
| iscale=1.0, | ||
| pixel_scale_ratio=1.0, |
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.
iscale = 1.0 is definitely right.
Formerly we were not setting pixel_scale_ratio. I understand this to be one of input_pixel_scale / output_pixel_scale or its reciprocal. For our usual case that's going to be 0.5 or 2 at the moment. I feel awkward setting it to 1 here as it seems wrong. Is 1 what is needed?
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.
1 is needed to get regression tests pass although they will likely pass regardless since pipeline does not use any of the affected kernels by default (lanczos, turbo, or gaussian). I will be happy to change this to a more sensible value.
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.
Okay, I think I understand that with this set up, things will work for now but if we ever selected a different kernel things would break. I think the right procedure would be to add pixel_scale_ratio to the dictionary following this example
romancal/romancal/resample/resample.py
Line 200 in b6b8f79
| "effective_exposure_time": model.meta.exposure.effective_exposure_time, |
from roman.meta.resample.pixel_scale_ratio. And then setting pixel_scale_ratio = model['pixel_scale_ratio'] here so that the right value is passed. But it won't make a difference now since our kernel doesn't use pixel_scale_ratio.
629566d to
1c8ac46
Compare
Prepares
romancalcode for the upcoming release ofdrizzle 3.0. This PR should not be merged until spacetelescope/stcal#418 is merged and either the dependency is set tostcal@mainor a new release is made that contains changes required for this to work withdrizzle 3.0.NOTE: although
drizzle 3.0will be backwards compatible, tests injwstandromancalare set to fail even on deprecation warnings, unfortunately.I do not think this PR makes any user-facing API changes but do let me know if a changelog is needed.
Tasks
24Q4_B15(use the latest build if not sure)no-changelog-entry-needed)changes/:echo "changed something" > changes/<PR#>.<changetype>.rst(see below for change types)docs/pageokify_regteststo update the truth filesnews fragment change types...
changes/<PR#>.general.rst: infrastructure or miscellaneous changechanges/<PR#>.docs.rstchanges/<PR#>.stpipe.rstchanges/<PR#>.associations.rstchanges/<PR#>.scripts.rstchanges/<PR#>.mosaic_pipeline.rstchanges/<PR#>.skycell.rststeps
changes/<PR#>.dq_init.rstchanges/<PR#>.saturation.rstchanges/<PR#>.refpix.rstchanges/<PR#>.linearity.rstchanges/<PR#>.dark_current.rstchanges/<PR#>.jump_detection.rstchanges/<PR#>.ramp_fitting.rstchanges/<PR#>.assign_wcs.rstchanges/<PR#>.flatfield.rstchanges/<PR#>.photom.rstchanges/<PR#>.flux.rstchanges/<PR#>.source_detection.rstchanges/<PR#>.tweakreg.rstchanges/<PR#>.skymatch.rstchanges/<PR#>.outlier_detection.rstchanges/<PR#>.resample.rstchanges/<PR#>.source_catalog.rst