pcdshub / lcls-plc-las-bts

Laser Hall Beam Transport vacuum and shutter control
https://pcdshub.github.io/lcls-plc-las-bts/
Other
0 stars 4 forks source link

Centroid position -> image sum #9

Closed klauer closed 2 years ago

klauer commented 2 years ago

Replace centroid position checking with image sum checks. The reasoning is as follows (per Tyler):

The laser group suggested that the centroid may not be the best parameter to validate a new camera image. They thought the camera image sum would be better. The reasoning is that when the laser and all the mechanics are working properly, the system should be quite stable, so it wouldn't be surprising to have sub-pixel stability. Eric Cunningham has implemented his own code that does something similar, and found that the image sum was more robust than centroid noise.

klauer commented 2 years ago

AreaDetector stats plugin has the following:

Parameter index variable asyn interface Access Description drvInfo string EPICS record name EPICS record type
NDPluginStats Total asynFloat64 r/o Sum (total) of all elements in the array. This is available as an ai record. The total counts are also available as epicsInt32 values in an mca record via callbacks to the drvFastSweep driver. The mca record is very useful for on-the-fly data acquisition of the total counts in the detector or in an ROI. TOTAL $(P)$(R)Total_RBV $(P)$(R)TotalArray ai mca