Vertex Reconstruction Update#385
Open
flemmons wants to merge 21 commits into
Open
Conversation
…ClusterFinder's corresponding functions --Added some extra features, such as hit LAPPD count and strip-by-strip LAPPD hits. -Added ClusterSearcher to replace ClusterFinder using RecoDigit and RecoCluster classes -Updated RecoDigit and RecoCluster classes for corresponding use and new features, such as various cluster parameters -Added NeutronCheck tool as output for RecoCluster information -Added sample toolchain configfolder for using the new tools
-Changed RecoCluster and RecoDigit lists in several tools to be vectors of objects, rather than vectors of pointers, to avoid memory complications -removed unused convex hull function from RecoCluster class -simplified CalcAS function in RecoCluster class by consolidating for loops -removed several instances of commented-out code from older versions -removed several debug outputs -altered hard-coded time window values in several instances to rely on configuration input -added use of the true Q2 value from the GenieInfo store to NeutronCheck's output. -removed several uncontrolled cout lines, and replaced useful ones with Log. -Tidied the Instance() function of ClusterSearcher -Added vertex information to NeutronCheck
… nor memory-safe with recent changes to RecoDigit storage.
…ctorConfig -removed unhelpful forced loop end from single-pe gains extraction in ClusterSearcher::Initialize() -changed Genie version in ClusterSearcher/LoadGenieEventConfig to 1
-replaced all instances of fClusterList with fRecoClusters in ClusterSearcher -changed ClusterSearcher::RecoClusters() to a void function, since it was returning a member pointer to itself -removed ClusterSearcher::SelectByClusters(), which is not used
…stimation based on reconstructed vertex and MRD track. Also highlights the reconstructed transverse momentum.
marc1uk
requested changes
May 14, 2026
Collaborator
marc1uk
left a comment
There was a problem hiding this comment.
Not bad overall, a few things to fix. Please do double check those two PRs aren't being clobbered accidentally.
Collaborator
There was a problem hiding this comment.
this seems like a data file that should be stored externally and referenced by path
|
|
||
|
|
||
| bool ClassicalEnergyReco::Execute(){ | ||
| cout<<"ClassicCheck"<<endl; |
| for (int i = 0; i < fClusterList->size(); i++) { | ||
| if (fClusterList->at(i).GetClusterMode() == 1 && fClusterList->at(i).GetTime() < 10000 && fClusterList->at(i).GetNDigits() > 0) { //Todo: Set Time Window in config | ||
| max_pe=fClusterList->at(i).GetCharge(); | ||
| muonClusterIndex = i; |
Collaborator
There was a problem hiding this comment.
do these variables neeed to be reset before this loop? How do you prevent values from a previous Execute getting carried over if no clusters in this event pass this criteria?
| return false; | ||
| } | ||
|
|
||
| recoVtxX=recoVertex->GetPosition().X()/152; |
Collaborator
There was a problem hiding this comment.
what is 152? can we define a named constant rather than use magic number? i'm guessing its tank radius - in which case it ought to be retrieved from the geomtery.
|
|
||
|
|
||
| double a=pow(recoDirX,2)+pow(recoDirZ,2); | ||
| cout<<"Classica: "<<a<<endl; |
| cout<<"check1"<<fClusterList->at(i).GetNDigits()<<", "<<fClusterList->at(i).GetDigitList().size() << endl; | ||
| fClusterList->at(i).Print(); | ||
| if(fClusterList->at(i).GetClusterMode()==1 && fClusterList->at(i).GetTime()<10000 && fClusterList->at(i).GetNDigits()>0) { //Todo: Set Time Window in config | ||
| cout<<"check2 "<<fClusterList->at(i).GetDigitList().size()<<endl; |
| } | ||
| vector<RecoDigit> tempDigitList; | ||
| for (int i = 0; i < fClusterList->size(); i++) { | ||
| cout << "check1" << fClusterList->at(i).GetNDigits() << ", " << fClusterList->at(i).GetDigitList().size() << endl; |
| int currentLAPPD = 0; | ||
|
|
||
| int iStripHit = 0; | ||
| std::cout << "VGCheck entering for loop\n"; |
| Log("VGCheck: Digit's time, delta, ltrack, lphoton: "+to_string(digitT)+", "+to_string(myvtxgeo->GetDelta(n))+", "+to_string(myvtxgeo->GetDistTrack(n))+", "+to_string(myvtxgeo->GetDistPhoton(n)),v_debug,verbosity); | ||
| if (myvtxgeo->GetDigitType(n) == RecoDigit::lappd_v0) flappdtimesmear->Fill(Parameters::TimeResolution(RecoDigit::lappd_v0, myvtxgeo->GetDigitQ(n))); | ||
| if (myvtxgeo->GetDigitType(n) == RecoDigit::PMT8inch) fpmttimesmear->Fill(Parameters::TimeResolution(RecoDigit::PMT8inch, myvtxgeo->GetDigitQ(n))); | ||
| std::cout << "VGCheck " << n << endl; |
| } | ||
| StripHits1->Fill(fDigitList->at(n).GetPosition().X(), fDigitList->at(n).GetCalTime() * 1000/*, fDigitList->at(n).GetCalCharge()*/); | ||
| iStripHit++; | ||
| std::cout << "VGCheck striphit"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Describe your changes
-Removed some experimental functions from FoMCalculator, which are no longer needed.
-Simplified the flow slightly of FoMCalculator's vtxtime handling
-fixed a typo in Position class, which returned a double-cosine, rather than the angle as intended
-Added parent-particle handling in RecoDigit class and corresponding tools, for when parent information is available
-Added ClassicalEnergyReco tool
-expanded hit collection in DigitBuilder for use with a variable window.
-Added waveform simulation handling in DigitBuilder tool
-Added second-run handling in EventSelector, so different cuts can be made at different points in the toolchain when needed
-Added ClusterSingleRing and LAPPDMult cuts to EventSelector tool
-fixed RecoMRDCut in EventSelectorTool
-Added ability to change LikelihoodFitterCheck between position- and direction- sweep modes to check different vertexing variable behaviors
-Updated NeutronCheck tool with more cluster parameters, along with true neutron capture information
-allowed handling of inactive PMTs in PMTWaveformsim. Currently ignores them, and records the number of active detectors
-Added some event selection and RecoCluster handling in VtxSeedFineGrid tool
-Removed redundant finegrid creation in VtxSeedGenerator tool
-Added energy reconstruction to MC neutron multiplicity toolchain using ClassicalEnergyReco tool
-Added PMT waveform simulator to MC neutron multiplicity toolchain
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
Attach any validation or demonstration files here. You may also link to relavant docdb articles.