simonsobs / sotodlib

Simons Observatory: Time-Ordered Data processing library.
MIT License
16 stars 19 forks source link

update_smurf_caldbs fails when bias_lines >= 12 voltages are not nan #1012

Closed jlashner closed 1 month ago

jlashner commented 1 month ago

Carlos noticed that the obs-id obs_1727406001_satp3_1111111 does not have det_cal info, while the observations before and after (for instance obs_1727409259_satp3_1111111) do.

In prefect we see the error: Failed on obs_1727406001_satp3_1111111: 'ufm_mv35_b12' which occurs when trying to check bias-line consistency in this loop.

I checked the bias step analysis files for the failing and working observations, and found that for the failing observation, Vbias is not nan for bias lines >= 12, while for the successful observations Vbias is nan for bias lines >= 12:

>>> bsa['Vbias']
array([  2.72476807,   2.76213257,   6.86217651,   6.88730469,
         2.99964844,   3.14976196,   6.94957886,   6.9996167 ,
         2.82462524,   2.82462524,   6.9996167 ,   6.94957886,
        22.84063599, -70.05560059,  42.25859619, -15.48594727])

I'm not sure exactly what is causing this in the data, but we need to change the existing update_smurf_caldbs script to skip bias lines >=12, rather than just checking for nans.