Skip to content
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

Off-timing combos are seen when using "dComboBeamWrapper->Get_IsGenerator()" selection #166

Open
keigo-miz opened this issue Jan 20, 2023 · 5 comments

Comments

@keigo-miz
Copy link

keigo-miz commented Jan 20, 2023

Screenshot 2023-01-20 at 3 11 56 PM

In the above figure, DeltaT_RF distributions for MC analysis are shown.

The black histogram is for all combos without any cuts in DSelector.
The red one is for combos which satisfy "dComboBeamWrapper->Get_IsGenerator() == true".

To my understanding, only on-timing peak should be seen when the true beam photons are selected using Get_IsGenerator method, but small off-timing peaks are seen only in left-hand side. Does this imply bugs are lurking around Get_IsGenerator function?

@jonzarling
Copy link
Contributor

Hi Keigo,

I did a deep dive into this maybe a year ago, hopefully I can save you some time here. This isn't really directly a gluex_root_analysis issue: the step where combos are incorrectly labeled "IsGenerator" happens far upstream. If I remember right, it actually originates as far back as hdgeant4, not even halld_recon. Perhaps a catch could be implemented in gluex_root_analysis to prevent any future confusion.

The Get_IsGenerator function is more of a "best guess" than anything. The algorithm for 'IsGenerator" first picks out beam photons that hit the correct tagger channel. Usually there is only one, but if there are multiple it picks out the one closest to 0 in the Delta t shown in the plot above. It doesn't use any timing cut, so it will pick out wrong beam photons like you show. I never figured out why they only show up on one side of the distribution, but I saw the same behavior.

This also means that there are accidentals under the peak around 0, where the true photon is inefficient but another lucky photon happens to be in-time and hit the correct tagger channel. So using IsGenerator in an analysis will overestimate the true efficiency.

@jonzarling
Copy link
Contributor

jonzarling commented Jan 21, 2023

The potentially scary bit is that the same logic applies to the mcthrown_tree plugin that I think most people rely on for efficiency determination. I suggest we close the issue here and reopen an issue in halld_recon mentioning the mcthrown_tree.

For what it's worth, here's what it looks like for me. In my analysis it was a 0.5% overcount with Spring 2017 conditions. It might be higher for later run periods running at higher rate.
image

@keigo-miz
Copy link
Author

Hi Jon, thank you very much for your explanation.
I agree with your suggestion, but can you open an issue in halld_recon for me? (I've never used mcthrown_tree plugin.)
I'm gonna close this issue after the issue is reopened in halld_recon.

@sdobbs
Copy link
Contributor

sdobbs commented Oct 22, 2024

I wonder if there's some cross over with this issue - JeffersonLab/halld_recon#810

@lihaoahil
Copy link
Contributor

Are those the simulations with or without random triggers? I took a quick look at my some of my recent simulation result but I don't see this happen.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants