Closed noeroy closed 10 months ago
After some discussion with François, we came to the conclusion that the only real viable path forward is to make
a way to pass through the Genie ID inside MLReco
This is not super hard, but will require some more plumbing...
This seems to do the trick. If @noeroy can confirm, we'll merge and consider this fixed.
In MLNDLArRecoBranchFiller.cxx, line 515,
srTruePart = &truthMatch->GetTrueParticle(sr, srTrueInt, srPartCmp, true, false);
doesn't find the True primary associated to the trajectory, so a secondary trajectory is created instead of doing the matching.This seems to be due to the
track_id
variable in MLRecoh5
file that links to a unique ID of the trajectory and not the initial Genie ID (this is calledtraj_id
in that wiki contrary tolocal_traj_id
that should correspond to the initial Genie ID). This ID is not unique per Edepsim file, as several Genie files are merged per Edepsim fiile and each of them have independent trajectory ID.I think we would either need a map linking the unique ID to the original Genie trajectory IDs, a way to pass through the Genie ID inside MLReco or a way to rebuild this unique ID in the NDCafMaker.
Note: In MINERvA Reco we do not have access to that unique ID, we internally work with one unique id that we build ourselves that is not used in the truth Matching of the CAFMaking afterwards.