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

JP-3588: Implement new reference file datamodel for PASTASOSS transformations #320

Merged
merged 10 commits into from
Sep 16, 2024

Conversation

tapastro
Copy link
Collaborator

Partially resolves JP-3588

This PR adds a new reference file datamodel for the PASTASOSS algorithm, replacing the existing ATOCA transformation algorithm. This effectively deprecates the spectrace and wavemap datamodels - TBD on how best to remove them from here and/or CRDS.

Checklist

  • added entry in CHANGES.rst (either in Bug Fixes or Changes to API)
  • updated relevant tests
  • updated relevant documentation
  • updated relevant milestone(s)
  • added relevant label(s)

@tapastro tapastro requested a review from a team as a code owner August 23, 2024 14:24
@braingram
Copy link
Collaborator

🍝

Copy link

codecov bot commented Aug 23, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 66.44%. Comparing base (8a63a5f) to head (f78fb11).
Report is 12 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #320      +/-   ##
==========================================
+ Coverage   66.41%   66.44%   +0.03%     
==========================================
  Files         101      102       +1     
  Lines        5434     5439       +5     
==========================================
+ Hits         3609     3614       +5     
  Misses       1825     1825              

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

@braingram
Copy link
Collaborator

The suggestions I added don't yet account for the ndim validators. I assume these properties are arrays? If so, the schema will have to be updated to accommodate that.

Would you add a unit test that makes an instance of the new model with expected junk data? That would help me understand what should go in those spots.

Copy link
Collaborator

@braingram braingram left a comment

Choose a reason for hiding this comment

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

There one item in the schema that causes the following to fail (which I think is worth adding as a generic test-all-model-schemas test):

import asdf
import stdatamodels.jwst.datamodels as dm
s = dm.PastasossModel()
asdf.schema.check_schema(s.schema)

Otherwise looks good to me.

Note that by default all ndim validation is disabled due to validate_arrays being default False. I have a hunch this is off as an attempt to avoid data loading or something but it is suprising to me that this disables ndim validation.

Copy link
Collaborator

@braingram braingram left a comment

Choose a reason for hiding this comment

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

LGTM!

@tapastro tapastro merged commit bebc1d5 into spacetelescope:main Sep 16, 2024
21 checks passed
@tapastro tapastro deleted the jp-3588-pastasoss branch September 16, 2024 18:23
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.

2 participants