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

RAD-92: Update visit, l1, and l2 attribute information #481

Closed
wants to merge 2 commits into from

Conversation

PaulHuwe
Copy link
Collaborator

@PaulHuwe PaulHuwe commented Oct 10, 2024

Resolves RAD-92

Closes #184

This PR updates visit, l1, and l2 attribute information

Tasks

  • Update or add relevant rad tests.
  • Update relevant docstrings and / or docs/ page.
  • Does this PR change any schema files?
    • Schema changes were discussed at RAD Review Board meeting.
  • Does this PR change any API used downstream? (If not, label with no-changelog-entry-needed.)
News fragment change types:
  • changes/<PR#>.feature.rst: new feature
  • changes/<PR#>.bugfix.rst: fixes an issue
  • changes/<PR#>.doc.rst: documentation change
  • changes/<PR#>.removal.rst: deprecation or removal of public API
  • changes/<PR#>.misc.rst: infrastructure or miscellaneous change

Copy link

codecov bot commented Oct 10, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 95.81%. Comparing base (af9de57) to head (b5056b6).
Report is 3 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #481   +/-   ##
=======================================
  Coverage   95.81%   95.81%           
=======================================
  Files           4        4           
  Lines         215      215           
=======================================
  Hits          206      206           
  Misses          9        9           

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

@PaulHuwe PaulHuwe marked this pull request as ready for review October 11, 2024 01:57
tag: tag:stsci.edu:asdf/unit/quantity-1.*
properties:
value:
tag: tag:stsci.edu:asdf/core/ndarray-1.*
datatype: float32
datatype: uint16
Copy link
Collaborator

Choose a reason for hiding this comment

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

@tddesjardins , I hadn't appreciated we were changing the type of these. Presently the 4k by 4k pixels get converted to floats and treated ~the same up until ramp fitting, when these are separated from the science data. That means treating them like floats for the purposes of this image.

That seems like the right behavior to me, and I read this change as saying we shouldn't do that and should instead ignore these pixels for dark subtraction, linearity correction, etc.. That would require more work in the pipeline and I wouldn't do it here.

@PaulHuwe , I'm writing this comment in the context of border_ref_pix_left, but it applies to the other border_pix as well.

It's also true that we treat the amp33 and other pixels differently. The amp33 pixels do not get the same dark subtraction, etc., that the other pixels do, since they're not actual pixels and it's not clear we could do anything meaningful here. I think that's the right treatment as well, but it is awkward that the different reference pixels have different data types.

Choose a reason for hiding this comment

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

I thought we were holding on to a version of the reference pixels that are uncalibrated, i.e., they have not been dark subtracted, linearity corrected, etc.? The IRRC is before any other calibration step, and the intent was that these arrays are copies of the untouched reference pixels (this was a request from specific science teams via the calibration working group). So I think these are supposed to be uint16 pixels in DN. You're right we carry them around a little longer and chop them off of the image after the classical linearity correction, but these are copies of the originals not the ones we chopped off.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Ah! Correct, indeed, thanks. Okay, this looks fine, sorry! I guess I register that I think carrying these on uncalibrated is somewhat silly but that's water under the bridge.

Copy link
Collaborator

Choose a reason for hiding this comment

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

That sounds reasonable. Looking at that code raises a few questions in my mind
https://github.com/spacetelescope/jwst_backgrounds/blob/master/jwst_backgrounds/jbt.py#L180
but we should defer that conversation to later.

@PaulHuwe
Copy link
Collaborator Author

Closing as all changes already merged.

@PaulHuwe PaulHuwe closed this Oct 29, 2024
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.

Add/Update visit attribute information
4 participants