AdV-COM›automation
#37549
Fixing uncorrect transitions and anticipating exit from SCIENCE Mode in ITF_STATUS
Bas spotted that, because of the ITF_STATUS transitions definition, in case of an unlock, ITF_STATUS was going from SCIENCE to LOCKED and then to NOT_LOCKED and not directly to NOT_LOCKED.
Also in case an unlock happening while in ADJUSTING, ITF_STATUS went via SCIENCE to LOCKED and then to NOT_LOCKED. This was creating a fake 2-second science mode segments, see Fig. 1 (90=adjusting, 40=science, 30=locked, 10=not_locked).
To solve those problems, direct edges from both ADJUSTING and SCIENCE to TRANSITING has been added in ITF_STATUS (See Fig. 2).
Also, as spotted by Dan, the DQ_META_ITF_Mode channel could take several seconds to respond to the overall state of the detector when there was an unlock.
To mitigate this issue (there will be always at least 1 sec delay because of the running rate of the automation nodes) a direct checking of LSC_ENABLE to recognize an unlock has been added directly inside the SCIENCE and ADJUSTING states (For the purpose the LSC_ENABLE_tripped() function has been used moving it from CARM_DARM_LOCK.py to META_library.py)
1 comment
To illustrate the bug that Franco was fixing, see the attached plot, which is a histogram of the difference in time between the end of a science segment in C8 (defined by DQ_META_ITF_Mode), and the time when the ITF lost lock (defined by the fast LSC_ENABLE channel). For nearly all of the segments, the transition of the DQ_META_ITF_Mode channel was about five seconds delayed compared to the real unlock time. We think this has been fixed, and we should be tagging at most 1-2 seconds of time following an unlock as science data. We'll have to see if this is the case in a future commissioning run (and, if the latency is still a problem for calibration or analysis).