Remove np.nan assignment to uint array and remove unneeded uint32 conversion
A bug was discovered during deployment of 3.6.0 when LPD dark tries to assign np.nan
to uint32
array.
Description
- Remove np.nan element assignment. No clear reason why this is needed for plotting.
- Remove unneeded data conversion for the badpixels constants.
- Refactor the lines of code where old badpixels constant are data converted to uint32
How Has This Been Tested?
Tested against the reference dark runs 145, 146, 147
Relevant Documents (optional)
Types of changes
Checklist:
Reviewers
Merge request reports
Activity
Oops, my mistake, sorry that I didn't catch this when I changed the dtype.
I think the nan assignment does make sense for the plotting. It's making a plot like this:
Without replacing 0, all the white arrays on that plot would be dark blue, making it much harder to see the bad pixels. NaN is handled specially for plotting. So I think we might want to convert the data back to float specifically for plotting.
I swear I tested this yesterday and I haven't seen a difference.
Thanks a lot for rechecking @kluyvert. Yes, you are right. Converting it back for the plot would be the only way.
Edited by Karim AhmedThanks @kluyvert
mentioned in commit ce5c420c
changed milestone to %3.6.0