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

Dark correction needs to check ref file params more thoroughly #178

Closed
hbushouse opened this issue Aug 23, 2016 · 0 comments
Closed

Dark correction needs to check ref file params more thoroughly #178

hbushouse opened this issue Aug 23, 2016 · 0 comments

Comments

@hbushouse
Copy link
Collaborator

I've found a case where the dark current step inadvertently applies data from a dark reference file that's totally inappropriate. Right now the step first checks to see if NFRAMES and GROUPGAP in the science and reference files are an exact match. If they're an exact match, it applies the dark ref data directly. If they aren't an exact match, it grabs and averages frames out of the ref file. The way the code is constructed, it contains an implicit assumption that the science data will always have NFRAMES and GROUPGAP values that are greater than the reference data. I've discovered a case where the selected ref file has NFRAMES=4, while the science data have NFRAMES=1, and the code blindly goes ahead and tries to apply it. This is incorrect.

A check needs to be added to the dark correction step to make sure that the values of NFRAMES and GROUPGAP for the ref data are always at least equal to or greater than the values for the science data. If not, a warning should be issued and the step skipped.

@hbushouse hbushouse added this to the Build 7 milestone Aug 23, 2016
hbushouse added a commit to hbushouse/jwst that referenced this issue Sep 10, 2016
hbushouse added a commit that referenced this issue Sep 10, 2016
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