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-3147 Treat PSF exposures as science for Level 2 association processing #7508

Merged

Conversation

stscieisenhamer
Copy link
Collaborator

@stscieisenhamer stscieisenhamer commented Mar 24, 2023

Resolves JP-3147

This PR addresses and issue with coronographic observations found while investigating JWSTDMS-770 and documented in JP-3147. The issue is that the PSF observations Level 2 associations were not including their linked background observations. Technically, this is because PSF Image 2 associations were being processed by the rule {{Asn_Lv2ImageSpecial}}, which specifically disallows background candidates.

The solution is that, for Level 2 associations, PSF observations can be treated as normal science, which is handled by the rule {{Asn_Lv2Image}}. This is done by changing the exposure type from "psf" to "science".

Checklist for maintainers

  • added entry in CHANGES.rst within the relevant release section
  • updated or added relevant tests
  • updated relevant documentation
  • added relevant milestone
  • added relevant label(s)
  • ran regression tests, post a link to the Jenkins job below.
    How to run regression tests on a PR
  • Make sure the JIRA ticket is resolved properly

@stscieisenhamer
Copy link
Collaborator Author

@hbushouse The new set of associations have been uploaded into the below folder for examination

/grp/jwst/ssb/chartreuse/dms_bugs/jwstdms-770/all_candidates_fixed

This set of associations was created with the command, using the PR version of the code:

$ asn_generate jw01194_20230115t113819_pool.csv --all-candidates

@stscieisenhamer
Copy link
Collaborator Author

stscieisenhamer commented Mar 24, 2023

Regression run

Note: This run is doing only the association tests.

The job is hung, but examination of the log shows no errors.

@codecov
Copy link

codecov bot commented Mar 24, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: -27.32 ⚠️

Comparison is base (af63faf) 77.49% compared to head (7f24a16) 50.17%.

❗ Current head 7f24a16 differs from pull request most recent head dd6442b. Consider uploading reports for the commit dd6442b to get more accurate results

Additional details and impacted files
@@             Coverage Diff             @@
##           master    #7508       +/-   ##
===========================================
- Coverage   77.49%   50.17%   -27.32%     
===========================================
  Files         452      452               
  Lines       36193    36198        +5     
===========================================
- Hits        28047    18163     -9884     
- Misses       8146    18035     +9889     
Flag Coverage Δ
nightly 19.30% <100.00%> (-58.18%) ⬇️
Impacted Files Coverage Δ
jwst/associations/lib/rules_level2_base.py 85.23% <100.00%> (+0.19%) ⬆️

... and 157 files with indirect coverage changes

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

Copy link
Collaborator

@hbushouse hbushouse left a comment

Choose a reason for hiding this comment

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

Looks good to me, but just one question. It looks like there are now multiple definitions of get_exposure_type in different classes. Is that kosher?

@stscieisenhamer
Copy link
Collaborator Author

That is using standard method overriding as part of the OO approach used by the generated. This is kosher and should be expected.

@stscieisenhamer stscieisenhamer merged commit 2508e29 into spacetelescope:master Mar 28, 2023
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.

3 participants