31 std::cout <<
"----> Running Algorithm Tool: " << this->
GetInstanceName() <<
", " << this->
GetType() << std::endl;
35 overlapMatrix.GetSortedKeyClusters(sortedKeyClusters);
37 for (
const Cluster *
const pKeyCluster : sortedKeyClusters)
42 if (usedKeyClusters.count(pKeyCluster))
45 unsigned int n1(0), n2(0);
46 MatrixType::ElementList elementList;
57 std::cout <<
" Connections: n1 " << n1 <<
", n2 " << n2 <<
", nElements " << elementList.size() << std::endl;
59 for (MatrixType::ElementList::const_iterator eIter = elementList.begin(); eIter != elementList.end(); ++eIter)
61 if (allClusterList1.end() == std::find(allClusterList1.begin(), allClusterList1.end(), eIter->GetCluster1()))
62 allClusterList1.push_back(eIter->GetCluster1());
63 if (allClusterList2.end() == std::find(allClusterList2.begin(), allClusterList2.end(), eIter->GetCluster2()))
64 allClusterList2.push_back(eIter->GetCluster2());
65 usedKeyClusters.insert(eIter->GetCluster1());
68 for (MatrixType::ElementList::const_iterator eIter = elementList.begin(); eIter != elementList.end(); ++eIter)
72 bool isPrimary0(
false);
73 bool isPrimary1(
false);
74 bool sameParticle(
false);
83 sameParticle = (particle0->
GetUid() == particle1->
GetUid());
92 std::cout <<
" Element " << counter++ << std::endl;
93 std::cout <<
" ---True PDG 0: " << pdg0 << std::endl;
94 std::cout <<
" ---True PDG 1: " << pdg1 << std::endl;
95 std::cout <<
" ---True is primary 0: " << isPrimary0 << std::endl;
96 std::cout <<
" ---True is primary 1: " << isPrimary1 << std::endl;
97 std::cout <<
" ---True is same particle: " << sameParticle << std::endl;
98 std::cout <<
" ---Is cluster 0 available: " << eIter->GetCluster1()->IsAvailable() << std::endl;
99 std::cout <<
" ---Is cluster 1 available: " << eIter->GetCluster2()->IsAvailable() << std::endl;
100 std::cout <<
" ---XOverlap: " << eIter->GetOverlapResult().GetTwoViewXOverlap().GetTwoViewXOverlapSpan() << std::endl;
101 std::cout <<
" ---XOverlap fraction view0: " << eIter->GetOverlapResult().GetTwoViewXOverlap().GetXOverlapFraction0() << std::endl;
102 std::cout <<
" ---XOverlap fraction view1: " << eIter->GetOverlapResult().GetTwoViewXOverlap().GetXOverlapFraction1() << std::endl;
103 std::cout <<
" ---Matching score: " << eIter->GetOverlapResult().GetMatchingScore() << std::endl;
104 std::cout <<
" ---N. sampling points: " << eIter->GetOverlapResult().GetNSamplingPoints() << std::endl;
105 std::cout <<
" ---N. matched sampling points: " << eIter->GetOverlapResult().GetNMatchedSamplingPoints() << std::endl;
106 std::cout <<
" ---N. (re-)upsampled sampling points: " << eIter->GetOverlapResult().GetNReUpsampledSamplingPoints() << std::endl;
107 std::cout <<
" ---N. (re-)upsampled matched sampling points: " << eIter->GetOverlapResult().GetNMatchedReUpsampledSamplingPoints()
109 std::cout <<
" ---Correlation coeff.: " << eIter->GetOverlapResult().GetCorrelationCoefficient() << std::endl;
110 std::cout <<
" ---Locally matched fraction: " << eIter->GetOverlapResult().GetLocallyMatchedFraction() << std::endl;
114 const ClusterList clusterList1(1, eIter->GetCluster1()), clusterList2(1, eIter->GetCluster2());
124 std::cout <<
" All Connected Clusters " << std::endl;
static const pandora::PandoraSettings * GetSettings(const pandora::Algorithm &algorithm)
Get the pandora settings instance.
TwoViewTransverseTracksAlgorithm class.
static const MCParticle * GetMainMCParticle(const T *const pT)
Find the mc particle making the largest contribution to a specified calo hit, track or cluster.
Uid GetUid() const
Get the mc particle unique identifier.
bool IsRootParticle() const
Whether the mc particle is a root particle.
int GetParticleId() const
Get the PDG code of the mc particle.