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

Fix minor bugs in MIRI LRS spec3 master_background #8928

Closed
stscijgbot-jp opened this issue Oct 28, 2024 · 5 comments
Closed

Fix minor bugs in MIRI LRS spec3 master_background #8928

stscijgbot-jp opened this issue Oct 28, 2024 · 5 comments

Comments

@stscijgbot-jp
Copy link
Collaborator

stscijgbot-jp commented Oct 28, 2024

Issue JP-3792 was created on JIRA by Melanie Clarke:

While updating some MIRI LRS regression tests for JP-2928, I noticed a few small bugs in the master background correction step in spec3:

  1. If a single spectrum is passed to combine1d, the wavelength array for the input spectrum is sorted in place instead of being copied for the output spectrum, then sorted. For MIRI, this has the effect of reversing the order of the wavelength array compared to the order of the data, which corrupts the spectrum in the output "combined" product.

  2. The 'mbsub' suffix is used in calwebb_spec3 for the master background output, but it is not recorded as a known suffix, so it does not get properly removed for the next product in the pipeline.

  3. In the master_background step, when a user background is provided, there are a couple small bugs relating to changes to the ModelContainer in JP-3721. There was an overlooked container.update call that crashed if the input was also a ModelContainer, since ModelContainers no longer have their own metadata (so no update function exists). There was also a place where a single model was passed to a function that expected a container when {}save_background=True{}, also causing a crash.

@stscijgbot-jp
Copy link
Collaborator Author

stscijgbot-jp commented Oct 28, 2024

Comment by Melanie Clarke on JIRA:

Proposed fixes are in PR https://github.com/spacetelescope/jwst/pull/8927](https://github.com/spacetelescope/jwst/pull/8927), along with the updates to the regression tests.

@stscijgbot-jp
Copy link
Collaborator Author

Comment by David Law on JIRA:

Tagging Greg Sloan and Andreea Petric

@stscijgbot-jp
Copy link
Collaborator Author

Comment by David Law on JIRA:

Remove the extra trailing character from the link

@stscijgbot-jp
Copy link
Collaborator Author

Comment by Melanie Clarke on JIRA:

Sorry about that! I fixed the link in the message above.

@stscijgbot-jp
Copy link
Collaborator Author

Comment by Melanie Clarke on JIRA:

Fixed by #8927

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

No branches or pull requests

1 participant