desihub / desispec

DESI spectral pipeline
BSD 3-Clause "New" or "Revised" License
33 stars 24 forks source link

only count bad readnoise on amps not already flagged as bad #2234

Closed sbailey closed 2 months ago

sbailey commented 2 months ago

This PR fixes another badamp related conceptual bug: PSF fitting rejects CCDs with >12.5% of the pixels flagged as having bad readnoise. But now that we have better handling of bad amps that are pre-flagged as bad, we don't care what the readnoise is on those amps.

And example is night 20231205 where b5A and b5C are flagged as bad due to high readnoise. desi_proc was discarding the b5 arcs (without actually counting it as a fatal error) and then the psfnight was failing due to missing individual exposure psfs.

With this PR

I've tested this on the j1 production with this branch. I intended to self merge so that I can update and we can proceed with this Jura testing production.