Skip to content

JP-4196: Update NIS_WFSS exptype to expect per-wavelength units in photom ref file#10199

Open
emolter wants to merge 15 commits intospacetelescope:mainfrom
emolter:JP-4196
Open

JP-4196: Update NIS_WFSS exptype to expect per-wavelength units in photom ref file#10199
emolter wants to merge 15 commits intospacetelescope:mainfrom
emolter:JP-4196

Conversation

@emolter
Copy link
Collaborator

@emolter emolter commented Jan 29, 2026

Resolves JP-4196

Closes #10058

This PR updates the photom and wfss_contam steps to expect per-wavelength units in NIRISS WFSS photometric reference file data, similar to what is already done for NIRCam.

Please note that this requires a coordinated reference file delivery.

https://github.com/spacetelescope/RegressionTests/actions/runs/21487386050
Regression tests are expected to have very large differences for all NIRISS WFSS data downstream of the photom step, and for tests where wfss_contam is turned on. I'd expect the differences to be much smaller (say, a few percent or less) when pointed to the new ref file.
These tests are useful to show that only the products we'd expect to change have changed.

Tasks

  • If you have a specific reviewer in mind, tag them.
  • add a build milestone, i.e. Build 12.0 (use the latest build if not sure)
  • Does this PR change user-facing code / API? (if not, label with no-changelog-entry-needed)
    • write news fragment(s) in changes/: echo "changed something" > changes/<PR#>.<changetype>.rst (see changelog readme for instructions)
      • if your change breaks step-level or public API (as defined in the docs), also add a changes/<PR#>.breaking.rst news fragment
    • update or add relevant tests
    • update relevant docstrings and / or docs/ page
    • start a regression test and include a link to the running job (click here for instructions)
      • Do truth files need to be updated ("okified")?
        • after the reviewer has approved these changes, run okify_regtests to update the truth files
  • if a JIRA ticket exists, make sure it is resolved properly

@codecov
Copy link

codecov bot commented Jan 29, 2026

Codecov Report

❌ Patch coverage is 83.33333% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 84.66%. Comparing base (bbf1e5f) to head (3d22354).
⚠️ Report is 75 commits behind head on main.

Files with missing lines Patch % Lines
jwst/wfss_contam/sens1d.py 71.42% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #10199      +/-   ##
==========================================
- Coverage   85.98%   84.66%   -1.33%     
==========================================
  Files         368      366       -2     
  Lines       38457    38463       +6     
==========================================
- Hits        33066    32563     -503     
- Misses       5391     5900     +509     

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.


# check for regression by hard-coding one value of slit.data
assert np.isclose(slit.data[5, 60], 20.996877670288086)
assert np.isclose(slit.data[5, 60], 0.09994397)
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the mock photom ref file sensitivities are all set to unity for this test, so it stands to reason that the value we are checking would change substantially.

@emolter emolter added this to the Build 12.3 milestone Jan 29, 2026
@emolter emolter marked this pull request as ready for review February 12, 2026 15:33
@emolter emolter requested a review from a team February 12, 2026 15:33
@emolter emolter requested a review from tapastro as a code owner February 12, 2026 15:33
@emolter
Copy link
Collaborator Author

emolter commented Feb 12, 2026

@KevinVolkSTScI is still doing some analysis of the new photom output values with this PR, but they're within 1% of the old values so if there's any code issue, it's almost certainly due to some pre-existing issue, not the code changes here. Therefore I'm marking this ready for review now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Update NIRISS WFSS photom units to per wavelength from per pixel

1 participant