-
Notifications
You must be signed in to change notification settings - Fork 59
New hit finding integration window, same as 2023 Gains Calibration #344
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Added another hit finding technique that reflects the same integration window used in the 2023 Gains calibration by Gian.
|
|
||
| if(verbosity>v_debug) { | ||
|
|
||
| std::cout << "Hit time [ns] " << hit_time * NS_PER_ADC_SAMPLE << std::endl; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please switch to Log
Replace std::cout with Log
|
Changed all instances of std::cout to Log |
jminock
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All looks good. No major bugs or breaks and all running sums are properly initialized.
Calling log within a const method raises errors, changing back to std:out
Is what this section of the hit finding code lives in. Apparently calling |
jminock
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Waiting for compilation before switching label to "ready to merge"
Describe your changes
The 2023 Gains calibration employed a different integration window than what is the default for our event building / physics data. To ensure we're using the same hit finding integration window, a new option ("Fixed_2023_Gains") has been added. The key difference is:
Default hit finding for event building ("dynamic"):
Pulse integration window defined by crossing and un-crossing threshold. The pulse_start is defined as 5 samples before the threshold (baseline + 7 dc) crossing point. The pulse_stop is defined when the pulse returns to the baseline + sigma crossing point.
Updated hit finding ("Fixed_2023_Gains"):
Pulse integration window defined by crossing and un-crossing baseline, rather than threshold. The pulse_start is defined as 5 samples before the baseline + sigma crossing point. The pulse_stop is defined as 5 samples after the pulse returns to the baseline + sigma crossing point.
The end result is we capture slightly more charge per hit, since the integration windows are extended to the left and right by at least 5 samples. Bob recommended we should use the same integration window as the Gains calibration, as our SPE factors depend on that calibration. Looking at individual ADC traces, it also seems like we consistently grab more of the whole "pulse" (see photo attached); we capture the main peak + the reflection peaks, where as in the old hit finding we would often miss some of the reflection peaks.
Both techniques still identify the pulse in the same way: threshold crossing (baseline + 7 dc).
Checklist before submitting your PR
newusage, there is a reason the data must be on the heapnewthere is adelete, unless I explicitly know why (e.g. ROOT or a BoostStore takes ownership)Additional Material
Attached photo below highlights the difference in the integration windows. The black curve is an average of 1000 SPE pulses taken from the data (Red is Andrew's new Waveform simulator, ignore for now). We can see the new pulse integration approach grabs the entirety of the pulse (including some of the reflection peaks). We should also use the same pulse integration approach in our physics data as what was used during calibration.

For a thorough breakdown of the differences used in the Gains calibration vs the (old) default event building hit finding, see here and here (Gian's calibration slides).