JeffersonLab / hpstr

Heavy Photon Search Toolkit for Reconstruction
2 stars 19 forks source link

Add raw hits on Si clusters in Tracker2DHitProcessor #170

Open rodwyer100 opened 1 year ago

rodwyer100 commented 1 year ago

Similarly to the problem observed in the creation of the FSPParticle object, if we want to include clusters in an ntupple for our analysis the asssociated processor, Trcker2DHitProcessor, has empty pointers to the rawhits inside of the cluster object it puts in your output root file. Cam wanted to do a speed run of how fast he could write it :), so now we have this version of the Tracker2DHitProcessor with populated clusters. I will include in this push request below a record of the validation tests I performed to see if it was worthy to be put into master.

rodwyer100 commented 1 year ago

First my SvtRawDataAnaProcessor.cxx (the code we use to analyze pulse times) was geared to check whether a hit existed within a cluster so that we can clean up some plots (and only plot distributions for hits that could possibly be associated with a track). I put a couple print statements in the portion that opened clusters and raw hits. These print statements looked like "Do I go here" and "Do I go here" indicating that the processor could access a cluster collection, and then for each associated cluster whether it could access the raw hits therein. Before Cam's work I only saw this first one, and after the second. That second can only occur if the pointers to raw hits in each cluster was populated with a raw hit, so this should be sufficient evidence that it is doing what it should be doing.

image

I was also asked to run valgrind on this piece of code. I will comment its output in the next comment.

rodwyer100 commented 1 year ago

Here is that result: image