318 timeStamp=timingHandle->at(0).GetTimeStamp();
332 std::vector<art::Ptr<recob::OpFlash> > opHitList;
333 auto opListHandle =
event.getHandle< std::vector<recob::OpFlash> >(
fopModuleLabel);
339 auto const* SCE = lar::providerFrom<spacecharge::SpaceChargeService>();
353 const auto & triggers =
event.getValidHandle < std::vector < CRT::Trigger >> (
fCRTLabel);
355 art::FindManyP < sim::AuxDetSimChannel > trigToSim(triggers,
event,
fCRTLabel);
361 std::unordered_map < size_t, double > prevTimes;
367 for (
const auto &
trigger: * triggers) {
368 const auto & hits =
trigger.Hits();
369 for (
const auto &
hit: hits) {
376 tHits.module =
trigger.Channel();
377 tHits.channel=
hit.Channel();
378 tHits.adc =
hit.ADC();
382 tHits.module =
trigger.Channel();
383 tHits.channel=
hit.Channel();
384 tHits.adc =
hit.ADC();
385 tHits.triggerTime=
trigger.Timestamp();
389 tHits.triggerNumber=trigID;
390 const auto & trigGeo = geom -> AuxDet(
trigger.Channel());
391 const auto & csens = trigGeo.SensitiveVolume(
hit.Channel());
392 const auto center = csens.GetCenter();
401 cout <<
"Hits compiled for event: " <<
nEvents <<
endl;
402 cout <<
"Number of Hits above Threshold: " << hitID <<
endl;
405 for (
unsigned int f_test = 0; f_test <
tempHits_F.size(); f_test++) {
407 const auto & trigGeo = geom -> AuxDet(
tempHits_F[
f].module);
408 const auto & trigGeo2 = geom -> AuxDet(
tempHits_F[f_test].module);
411 const auto hit1Center = hit1Geo.GetCenter();
413 const auto & hit2Geo = trigGeo2.SensitiveVolume(
tempHits_F[f_test].channel);
414 const auto hit2Center = hit2Geo.GetCenter();
419 double hitX = hit1Center.X();
424 double hitYPrelim=hit2Center.Y();
432 double hitY=hitYPrelim;
433 double hitZ = (hit1Center.Z() + hit2Center.Z()) / 2.
f;
436 rHits.hitPositionX = hitX;
437 rHits.hitPositionY = hitY;
438 rHits.hitPositionZ = hitZ;
447 rHits.trigNumberY=
tempHits_F[f_test].triggerNumber;
454 for (
unsigned int f_test = 0; f_test <
tempHits_B.size(); f_test++) {
457 const auto & trigGeo = geom -> AuxDet(
tempHits_B[
f].module);
458 const auto & trigGeo2 = geom -> AuxDet(
tempHits_B[f_test].module);
459 const auto & hit1Geo = trigGeo.SensitiveVolume(
tempHits_B[
f].channel);
460 const auto hit1Center = hit1Geo.GetCenter();
462 const auto & hit2Geo = trigGeo2.SensitiveVolume(
tempHits_B[f_test].channel);
463 const auto hit2Center = hit2Geo.GetCenter();
468 double hitX = hit1Center.X();
476 double hitYPrelim = hit2Center.Y();
482 double hitY=hitYPrelim;
485 double hitZ = (hit1Center.Z() + hit2Center.Z()) / 2.
f;
488 rHits.hitPositionX = hitX;
489 rHits.hitPositionY = hitY;
490 rHits.hitPositionZ = hitZ;
498 rHits.trigNumberY=
tempHits_B[f_test].triggerNumber;
507 vector < art::Ptr < recob::Track > > trackList;
508 vector<art::Ptr<recob::PFParticle> > pfplist;
509 auto PFPListHandle =
event.getHandle< std::vector<recob::PFParticle> >(
fTrackModuleLabel);
510 if (trackListHandle) {
514 auto PFPListHandle2 =
event.getHandle< std::vector<recob::PFParticle> >(
"pandora");
517 art::FindManyP<anab::T0> trk_t0_assn_v(PFPListHandle2,
event ,
"pandora");
518 art::FindManyP<recob::PFParticle> pfp_trk_assn(trackListHandle,
event,
"pandoraTrack");
519 art::FindManyP<recob::Hit> trackHits(trackListHandle,
event,
"pandoraTrack");
521 int nTracksReco = trackList.size();
524 for (
int iRecoTrack = 0; iRecoTrack < nTracksReco; ++iRecoTrack) {
525 double mccX=-999;
double mccY=-999;
double mccZ=-999;
528 std::vector< art::Ptr<recob::Hit> > allHits = hitsFromTrack.at(iRecoTrack);
532 std::vector<art::Ptr<recob::PFParticle>> pfps=pfp_trk_assn.at(iRecoTrack);
533 if(!pfps.size())
continue;
534 std::vector<art::Ptr<anab::T0>> t0s=trk_t0_assn_v.at(pfps[0].
key());
542 int lastHit=allHits.size()-2;
547 double trackStartPositionZ_noSCE = trackList[iRecoTrack]->Vertex().Z();
548 double trackEndPositionZ_noSCE = trackList[iRecoTrack] ->
End().Z();
550 double trackStartPositionX_noSCE = trackList[iRecoTrack]->Vertex().X();
551 double trackStartPositionY_noSCE = trackList[iRecoTrack]->Vertex().Y();
554 double trackEndPositionX_noSCE = trackList[iRecoTrack] ->
End().X();
555 double trackEndPositionY_noSCE = trackList[iRecoTrack] ->
End().Y();
556 if (trackStartPositionZ_noSCE>trackEndPositionZ_noSCE){
557 trackEndPositionZ_noSCE = trackList[iRecoTrack]->Vertex().Z();
558 trackStartPositionZ_noSCE = trackList[iRecoTrack] ->
End().Z();
559 trackEndPositionX_noSCE = trackList[iRecoTrack]->Vertex().X();
560 trackEndPositionY_noSCE = trackList[iRecoTrack]->Vertex().Y();
563 trackStartPositionX_noSCE = trackList[iRecoTrack] ->
End().X();
564 trackStartPositionY_noSCE = trackList[iRecoTrack] ->
End().Y();
568 if ((trackEndPositionZ_noSCE>90 && trackEndPositionZ_noSCE < 660 && trackStartPositionZ_noSCE <50 && trackStartPositionZ_noSCE<660) || (trackStartPositionZ_noSCE>90 && trackStartPositionZ_noSCE < 660 && trackEndPositionZ_noSCE <50 && trackEndPositionZ_noSCE<660)) {
571 double min_delta = DBL_MAX;
573 double best_dotProductCos = DBL_MAX;
574 double best_deltaXF = DBL_MAX;
575 double best_deltaYF = DBL_MAX;
576 double best_T=DBL_MAX;
577 double best_trackX1=DBL_MAX;
578 double best_trackX2=DBL_MAX;
579 double best_xOffset=DBL_MAX;
580 int bestHitIndex_F=0;
588 std::vector<art::Ptr<recob::Hit>> allHits=trackHits.at(iRecoTrack);
590 std::map<int,double> trkide;
591 std::map<int,double> trknumelec;
594 for(
size_t h=0;
h<allHits.size();
h++){
596 std::vector<sim::TrackIDE> eveIDs = backTracker->
HitToTrackIDEs(clockData, hit);
597 for(
size_t e=0;
e<eveIDs.size(); ++
e){
598 trkide[eveIDs[
e].trackID] += eveIDs[
e].energy;
605 if((ii->second)>maxe){
616 auto const startPos=particle->
Position(0);
625 for (
int i=0; i<nTrajectory-2; i++){
630 for (
int i=0; i<nTrajectory-2; i++){
637 else if (beamLeft!=-1){
643 mccX=particle->
Position(beamRight).X();
644 mccY=particle->
Position(beamRight).Y();
645 mccZ=particle->
Position(beamRight).Z();}
648 mccX=particle->
Position(beamLeft).X();
649 mccY=particle->
Position(beamLeft).Y();
650 mccZ=particle->
Position(beamLeft).Z();}
652 if (beamLeft!=-1 || beamRight!=-1){
654 for (
unsigned int iHit_F = 0; iHit_F <
primaryHits_F.size(); iHit_F++) {
662 double mccHitY=(endPos.Y()-startPos.Y())/(endPos.Z()-startPos.Z())*(Z1-startPos.Z())+startPos.Y();
663 double mccHitX=(endPos.X()-startPos.X())/(endPos.Z()-startPos.Z())*(Z1-startPos.Z())+startPos.X();
665 if (fabs(X1-mccHitX)<60 && fabs(Y1-mccHitY)<60) {
mccTruthCheck=1;
701 for (
unsigned int iHit_F = 0; iHit_F <
primaryHits_F.size(); iHit_F++) {
704 double trackStartPositionX_notCorrected=trackStartPositionX_noSCE;
705 double trackEndPositionX_notCorrected=trackEndPositionX_noSCE;
707 if (
event.isRealData() && fabs(t_zero-(
primaryHits_F[iHit_F].timeAvg*20.
f))>100000)
continue;
708 if (!
event.isRealData() && fabs(t_zero-
primaryHits_F[iHit_F].timeAvg)>100000)
continue;
714 double ticksOffset=0;
717 if (!
fMCCSwitch) ticksOffset = (
primaryHits_F[iHit_F].timeAvg+RDOffset)/25.
f+detProp.GetXTicksOffset(allHits[firstHit]->WireID().Plane, allHits[firstHit]->WireID().TPC, allHits[firstHit]->WireID().Cryostat);
719 else if (
fMCCSwitch) ticksOffset = (
primaryHits_F[iHit_F].timeAvg/500.f)+detProp.GetXTicksOffset(allHits[firstHit]->WireID().Plane, allHits[firstHit]->WireID().TPC, allHits[firstHit]->WireID().Cryostat);
721 xOffset=detProp.ConvertTicksToX(ticksOffset,allHits[firstHit]->
WireID().
Plane, allHits[firstHit]->
WireID().
TPC, allHits[firstHit]->
WireID().Cryostat);
724 trackStartPositionX_noSCE=trackStartPositionX_notCorrected-xOffset;
725 trackEndPositionX_noSCE=trackEndPositionX_notCorrected-xOffset;
726 if (fabs(xOffset)>300 || ((trackStartPositionX_notCorrected<0 && trackStartPositionX_noSCE>0) || (trackEndPositionX_notCorrected<0 && trackEndPositionX_noSCE>0)) || ((trackStartPositionX_notCorrected>0 && trackStartPositionX_noSCE<0) || (trackEndPositionX_notCorrected>0 && trackEndPositionX_noSCE<0)) )
continue;
729 double trackStartPositionX=trackStartPositionX_noSCE;
730 double trackStartPositionY=trackStartPositionY_noSCE;
731 double trackStartPositionZ=trackStartPositionZ_noSCE;
733 double trackEndPositionX=trackEndPositionX_noSCE;
734 double trackEndPositionY=trackEndPositionY_noSCE;
735 double trackEndPositionZ=trackEndPositionZ_noSCE;
748 TVector3 trackStart(trackStartPositionX, trackStartPositionY, trackStartPositionZ);
749 TVector3 trackEnd(trackEndPositionX, trackEndPositionY, trackEndPositionZ);
750 TVector3 v1(X1,Y1,Z1);
751 TVector3 v2(trackStartPositionX, trackStartPositionY, trackStartPositionZ);
753 TVector3 v4(trackStartPositionX,
755 trackStartPositionZ);
756 TVector3 v5(trackEndPositionX,
759 TVector3 trackVector = (v5-v4).Unit();
760 TVector3 hitVector=(v2-v1).Unit();
765 double predictedHitPositionY1 = (v1.Z()-v5.Z())/(v4.Z()-v5.Z())*(v4.Y()-v5.Y())+v5.Y();
768 double predictedHitPositionX1 = (v1.Z()-v5.Z())/(v4.Z()-v5.Z())*(v4.X()-v5.X())+v5.X();
770 if (predictedHitPositionX1<-200 || predictedHitPositionX1>580 || predictedHitPositionY1<-50 || predictedHitPositionY1>620)
continue;
772 double dotProductCos=trackVector*hitVector;
774 double deltaX1 = (predictedHitPositionX1-X1);
777 double deltaY1 = (predictedHitPositionY1-Y1);
783 best_dotProductCos = dotProductCos;
784 best_trackX1=trackStartPositionX;
785 best_trackX2=trackEndPositionX;
786 best_deltaXF = deltaX1;
787 best_deltaYF = deltaY1;
788 best_xOffset=xOffset;
790 bestHitIndex_F=iHit_F;
797 int f=bestHitIndex_F;
800 double dotProductCos=best_dotProductCos;
802 double trackStartPositionX=best_trackX1;
803 double trackStartPositionY=trackStartPositionY_noSCE;
804 double trackStartPositionZ=trackStartPositionZ_noSCE;
806 double trackEndPositionX=best_trackX2;
807 double trackEndPositionY=trackEndPositionY_noSCE;
808 double trackEndPositionZ=trackEndPositionZ_noSCE;
811 TVector3 trackStart(trackStartPositionX, trackStartPositionY, trackStartPositionZ);
812 TVector3 trackEnd(trackEndPositionX, trackEndPositionY, trackEndPositionZ);
814 if (deltaX==DBL_MAX || deltaY==DBL_MAX)
continue;
816 double minTimeDifference=999999.99;
818 tPair.tempId = tempId;
819 tPair.CRTTrackId =
f;
820 tPair.recoId = iRecoTrack;
824 tPair.dotProductCos=dotProductCos;
831 tPair.xOffset=best_xOffset;
840 tPair.truthId=trackid;
842 tPair.trackStartPosition=trackStart;
843 tPair.flashTDiff=minTimeDifference;
844 tPair.trackEndPosition=trackEnd;
847 if (t0s.empty()) tPair.pandoraT0Check=0;
848 else tPair.pandoraT0Check=1;
854 if ( (trackStartPositionZ_noSCE<620 && trackEndPositionZ_noSCE > 660 && trackStartPositionZ_noSCE > 50 && trackEndPositionZ_noSCE > 50) || (trackStartPositionZ_noSCE>660 && trackEndPositionZ_noSCE < 620 && trackStartPositionZ_noSCE > 50 && trackEndPositionZ_noSCE > 50)) {
856 double min_delta = DBL_MAX;
858 double best_dotProductCos = DBL_MAX;
859 double best_deltaXF = DBL_MAX;
860 double best_deltaYF = DBL_MAX;
861 double best_T=DBL_MAX;
862 double best_xOffset=DBL_MAX;
863 int bestHitIndex_B=0;
864 double best_trackX1=DBL_MAX;
865 double best_trackX2=DBL_MAX;
870 std::vector<art::Ptr<recob::Hit>> allHits=trackHits.at(iRecoTrack);
873 std::map<int,double> trkide;
874 std::map<int,double> trknumelec;
877 for(
size_t h=0;
h<allHits.size();
h++){
879 std::vector<sim::TrackIDE> eveIDs = backTracker->
HitToTrackIDEs(clockData, hit);
880 for(
size_t e=0;
e<eveIDs.size(); ++
e){
881 trkide[eveIDs[
e].trackID] += eveIDs[
e].energy;
888 if((ii->second)>maxe){
901 auto const startPos=particle->
Position(0);
912 for (
int i=0; i<nTrajectory-2; i++){
919 mccX=particle->
Position(approxExit).X();
920 mccY=particle->
Position(approxExit).Y();
921 mccZ=particle->
Position(approxExit).Z();
926 for (
unsigned int iHit_F = 0; iHit_F <
primaryHits_B.size(); iHit_F++) {
934 double mccHitY=(endPos.Y()-startPos.Y())/(endPos.Z()-startPos.Z())*(Z1-startPos.Z())+startPos.Y();
935 double mccHitX=(endPos.X()-startPos.X())/(endPos.Z()-startPos.Z())*(Z1-startPos.Z())+startPos.X();
936 if (fabs(X1-mccHitX)<60 && fabs(Y1-mccHitY)<60) {
mccTruthCheck=1;
957 for (
unsigned int iHit_B = 0; iHit_B <
primaryHits_B.size(); iHit_B++) {
961 double trackStartPositionX_notCorrected=trackStartPositionX_noSCE;
962 double trackEndPositionX_notCorrected=trackEndPositionX_noSCE;
965 if (
event.isRealData() && fabs(t_zero-(
primaryHits_B[iHit_B].timeAvg*20.f))>100000)
continue;
966 if (!
event.isRealData() && fabs(t_zero-
primaryHits_B[iHit_B].timeAvg)>100000)
continue;
972 double ticksOffset=0;
975 if (!
fMCCSwitch) ticksOffset = (
primaryHits_B[iHit_B].timeAvg+RDOffset)/25.f+detProp.GetXTicksOffset(allHits[firstHit]->WireID().Plane, allHits[firstHit]->WireID().TPC, allHits[firstHit]->WireID().Cryostat);
977 else if (
fMCCSwitch) ticksOffset = (
primaryHits_B[iHit_B].timeAvg/500.f)+detProp.GetXTicksOffset(allHits[firstHit]->WireID().Plane, allHits[firstHit]->WireID().TPC, allHits[firstHit]->WireID().Cryostat);
979 xOffset=detProp.ConvertTicksToX(ticksOffset,allHits[firstHit]->
WireID().
Plane, allHits[firstHit]->
WireID().
TPC, allHits[firstHit]->
WireID().Cryostat);
982 trackStartPositionX_noSCE=trackStartPositionX_notCorrected-xOffset;
983 trackEndPositionX_noSCE=trackEndPositionX_notCorrected-xOffset;
984 if (fabs(xOffset)>300 || ((trackStartPositionX_notCorrected<0 && trackStartPositionX_noSCE>0) || (trackEndPositionX_notCorrected<0 && trackEndPositionX_noSCE>0)) || ((trackStartPositionX_notCorrected>0 && trackStartPositionX_noSCE<0) || (trackEndPositionX_notCorrected>0 && trackEndPositionX_noSCE<0)) )
continue;
987 double trackStartPositionX=trackStartPositionX_noSCE;
988 double trackStartPositionY=trackStartPositionY_noSCE;
989 double trackStartPositionZ=trackStartPositionZ_noSCE;
991 double trackEndPositionX=trackEndPositionX_noSCE;
992 double trackEndPositionY=trackEndPositionY_noSCE;
993 double trackEndPositionZ=trackEndPositionZ_noSCE;
998 trackStartPositionX -= posOffsets_F.X();
999 trackStartPositionY += posOffsets_F.Y();
1000 trackStartPositionZ += posOffsets_F.Z();
1002 trackEndPositionX -= posOffsets_B.X();
1003 trackEndPositionY += posOffsets_B.Y();
1004 trackEndPositionZ += posOffsets_B.Z();
1016 TVector3 trackStart(trackStartPositionX, trackStartPositionY, trackStartPositionZ);
1017 TVector3 trackEnd(trackEndPositionX, trackEndPositionY, trackEndPositionZ);
1018 TVector3 v1(X1,Y1,Z1);
1019 TVector3 v2(trackStartPositionX, trackStartPositionY, trackStartPositionZ);
1021 TVector3 v4(trackStartPositionX,
1022 trackStartPositionY,
1023 trackStartPositionZ);
1024 TVector3 v5(trackEndPositionX,
1027 TVector3 trackVector = (v5-v4).Unit();
1028 TVector3 hitVector=(v2-v1).Unit();
1033 double predictedHitPositionY1 = (v1.Z()-v5.Z())/(v4.Z()-v5.Z())*(v4.Y()-v5.Y())+v5.Y();
1036 double predictedHitPositionX1 = (v1.Z()-v5.Z())/(v4.Z()-v5.Z())*(v4.X()-v5.X())+v5.X();
1038 if (
abs(predictedHitPositionX1)>340 || predictedHitPositionY1<-160 || predictedHitPositionY1>560)
continue;
1040 double dotProductCos=trackVector*hitVector;
1042 double deltaX1 = (predictedHitPositionX1-X1);
1045 double deltaY1 = (predictedHitPositionY1-Y1);
1053 best_dotProductCos = dotProductCos;
1054 best_trackX1=trackStartPositionX;
1055 best_trackX2=trackEndPositionX;
1056 best_deltaXF = deltaX1;
1057 best_deltaYF = deltaY1;
1058 best_xOffset=xOffset;
1060 bestHitIndex_B=iHit_B;
1066 int f=bestHitIndex_B;
1068 double deltaX=best_deltaXF;
double deltaY=best_deltaYF;
1069 double dotProductCos=best_dotProductCos;
1074 double trackStartPositionX=best_trackX1;
1075 double trackStartPositionY=trackStartPositionY_noSCE;
1076 double trackStartPositionZ=trackStartPositionZ_noSCE;
1078 double trackEndPositionX=best_trackX2;
1079 double trackEndPositionY=trackEndPositionY_noSCE;
1080 double trackEndPositionZ=trackEndPositionZ_noSCE;
1083 TVector3 trackStart(trackStartPositionX, trackStartPositionY, trackStartPositionZ);
1084 TVector3 trackEnd(trackEndPositionX, trackEndPositionY, trackEndPositionZ);
1086 if (deltaX==DBL_MAX && deltaY==DBL_MAX)
continue;
1088 double minTimeDifference=999999.99;
1090 tPair.tempId = tempId;
1091 tPair.CRTTrackId =
f;
1092 tPair.recoId = iRecoTrack;
1096 tPair.dotProductCos=dotProductCos;
1103 tPair.xOffset=best_xOffset;
1112 tPair.truthId=trackid;
1114 tPair.trackStartPosition=trackStart;
1115 tPair.flashTDiff=minTimeDifference;
1116 tPair.trackEndPosition=trackEnd;
1119 if (t0s.empty()) tPair.pandoraT0Check=0;
1120 else tPair.pandoraT0Check=1;
1136 vector < tracksPair > allUniqueTracksPair;
1151 if (allUniqueTracksPair.size() > 0) {
1152 for (
unsigned int u = 0; u < allUniqueTracksPair.size(); u++) {
1153 deltaX=allUniqueTracksPair[u].deltaX;
1155 deltaY=allUniqueTracksPair[u].deltaY;
1157 opCRTTDiff=allUniqueTracksPair[u].flashTDiff;
1159 dotCos=fabs(allUniqueTracksPair[u].dotProductCos);
1160 trackX1=allUniqueTracksPair[u].trackStartPosition.X();
1161 trackY1=allUniqueTracksPair[u].trackStartPosition.Y();
1162 trackZ1=allUniqueTracksPair[u].trackStartPosition.Z();
1164 trackX2=allUniqueTracksPair[u].trackEndPosition.X();
1165 trackY2=allUniqueTracksPair[u].trackEndPosition.Y();
1166 trackZ2=allUniqueTracksPair[u].trackEndPosition.Z();
1172 moduleX=allUniqueTracksPair[u].moduleX1;
1173 moduleY=allUniqueTracksPair[u].moduleY1;
1175 adcX=allUniqueTracksPair[u].adcX1;
1176 adcY=allUniqueTracksPair[u].adcY1;
1178 CRTT0=allUniqueTracksPair[u].timeAvg;
1179 stripX=allUniqueTracksPair[u].stripX1;
1180 stripY=allUniqueTracksPair[u].stripY1;
1182 X_CRT=allUniqueTracksPair[u].X1;
1183 Y_CRT=allUniqueTracksPair[u].Y1;
1184 Z_CRT=allUniqueTracksPair[u].Z1;
1186 mccE=allUniqueTracksPair[u].mccE;
1187 mccT0=allUniqueTracksPair[u].mccT0;
1194 if (fabs(
trackX1)<400 && fabs(
trackX2)<400 && fabs(deltaX)<60 && fabs(deltaY)<60 && fabs(
dotCos)>.9995) {
1199 if (fabs(
mccT0-CRTT0)>0 && !
event.isRealData()) {
1201 for (
unsigned int iHit_F = 0; iHit_F <
primaryHits_F.size(); iHit_F++) {
1208 for (
unsigned int iHit_F = 0; iHit_F <
primaryHits_B.size(); iHit_F++) {
1218 std::set<int> signal_trackids;
1219 signal_trackids.emplace(allUniqueTracksPair[u].truthId);
1224 for(
unsigned int i = 0; i < opHitList.size(); ++i) {
1227 std::vector< art::Ptr<recob::OpHit> > hitFromFlash = pbt->
OpFlashToOpHits_Ps(FlashP);
1238 auto const startPos=particle->
Position(0);
1240 if (fabs(
mccT0-CRTT0)>100000){
1241 double mccHitY=(endPos.Y()-startPos.Y())/(endPos.Z()-startPos.Z())*(
Z_CRT-startPos.Z())+startPos.Y();
1242 double mccHitX=(endPos.X()-startPos.X())/(endPos.Z()-startPos.Z())*(
Z_CRT-startPos.Z())+startPos.X();
1243 std::cout<<mccHitX<<
','<<mccHitY<<
std::endl;
double E(const int i=0) const
code to link reconstructed objects back to the MC truth information
unsigned int NumberTrajectoryPoints() const
const TLorentzVector & Position(const int i=0) const
std::string fopModuleLabel
std::vector< tracksPair > tracksPair_B
const std::vector< art::Ptr< recob::OpHit > > OpFlashToOpHits_Ps(art::Ptr< recob::OpFlash > &flash_P)
const TLorentzVector & EndPosition() const
std::vector< sim::TrackIDE > HitToTrackIDEs(detinfo::DetectorClocksData const &clockData, recob::Hit const &hit) const
const simb::MCParticle * TrackIdToParticle_P(int id) const
simb::Origin_t Origin() const
geo::TPCID PositionToTPCID(geo::Point_t const &point) const
Returns the ID of the TPC at specified location.
std::string Process() const
const double OpHitCollectionPurity(std::set< int > const &tkIds, std::vector< art::Ptr< recob::OpHit > > const &opHits_Ps)
std::vector< recoHits > primaryHits_F
IDparameter< geo::WireID > WireID
Member type of validated geo::WireID parameter.
std::vector< tracksPair > tracksPair_F
const art::Ptr< simb::MCTruth > & TrackIdToMCTruth_P(int id) const
std::vector< tempHits > tempHits_F
double T(const int i=0) const
std::string fTrackModuleLabel
Detector simulation of raw signals on wires.
std::vector< recoHits > primaryHits_B
int fFronttoBackTimingCut
ROOT::Math::PositionVector3D< ROOT::Math::Cartesian3D< double >, ROOT::Math::GlobalCoordinateSystemTag > Point_t
Type for representation of position in physical 3D space.
int fModuletoModuleTimingCut
constexpr auto const & deepestIndex() const
Returns the value of the deepest ID available (TPC's).
void fill_ptr_vector(std::vector< Ptr< T >> &ptrs, H const &h)
bool moduleMatcher(int module1, int module2)
recob::tracking::Plane Plane
QTextStream & endl(QTextStream &s)
Event finding and building.
std::vector< tempHits > tempHits_B