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-1693: Fix extract_1d for SourceContainer with 1 slit #5439

Merged
merged 2 commits into from Oct 28, 2020

Conversation

hbushouse
Copy link
Collaborator

Updated the branch of extract_1d that loops over slit models in an input SourceContainerModel to handle the case where there's only 1 SlitModel and hence it's not in the form of a list. This can occur in level 3 processing of WFSS observations, for example, when there's only 1 instance of a given source in all of the input exposures.

Fixes #5331 / JP-1693

@codecov
Copy link

codecov bot commented Oct 28, 2020

Codecov Report

Merging #5439 into master will decrease coverage by 0.40%.
The diff coverage is 50.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #5439      +/-   ##
==========================================
- Coverage   71.74%   71.33%   -0.41%     
==========================================
  Files         414      414              
  Lines       37744    37985     +241     
  Branches     5842     5960     +118     
==========================================
+ Hits        27079    27098      +19     
- Misses       8946     9160     +214     
- Partials     1719     1727       +8     
Flag Coverage Δ *Carryforward flag
#nightly 71.73% <66.66%> (ø) Carriedforward from ae5e686
#unit 52.46% <0.00%> (-0.01%) ⬇️

*This pull request uses carry forward flags. Click here to find out more.

Impacted Files Coverage Δ
jwst/extract_1d/extract.py 52.72% <50.00%> (-7.47%) ⬇️
jwst/regtest/conftest.py 70.77% <0.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ae5e686...6a2340f. Read the comment docs.

Copy link
Collaborator

@jdavies-st jdavies-st left a comment

Choose a reason for hiding this comment

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

Would be nice at some point to refactor this (and elsewhere) to have more generic checks if they are a container type or not. This will require a small refactor of ModelContainer and our other container types, but that might be a better check rather than relying on the specific model classes for these checks. I.e. it will be more compatible with Roman which will have different DataModel subclasses.

@hbushouse hbushouse merged commit 933f19a into spacetelescope:master Oct 28, 2020
@hbushouse hbushouse deleted the jp-1693 branch October 28, 2020 13:54
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.

Error in calwebb_spec3 extract_1d for NIRCam WFSS association
2 participants