-
Notifications
You must be signed in to change notification settings - Fork 15
ContainmentSelecton_tool
David Caratelli edited this page Apr 3, 2019
·
1 revision
Selection which requires a fixed fiducialization to both the selected neutrino slice vertex, and to all track start/end points for tracks associated to PFParticles in the neutrino slice.
Configured as:
ContainmentSelection: {
tool_type: "ContainmentSelecton"
FV: 10
}
// save vertex to array
vtx.at(0)->XYZ(xyz);
nuvtx = TVector3(xyz[0],xyz[1],xyz[2]);
if (IsFiducial(nuvtx.X(), nuvtx.Y(), nuvtx.Z()) == false)
return false;
}// if neutrino PFP
else { // if not the neutrino PFP
auto ntrk = pfp_pxy.get<recob::Track>().size();
if (ntrk == 1) {
auto trk = pfp_pxy.get<recob::Track>().at(0);
auto trkstart = trk->Vertex();
auto trkend = trk->End();
if (IsFiducial(trkstart.X(), trkstart.Y(), trkstart.Z() ) == false)
return false;
if (IsFiducial(trkend.X(), trkend.Y(), trkend.Z() ) == false)
return false;
}// if associated to a track
}// if not the neurino PFP