8 #ifndef LAR_SLIDING_CONE_PFO_MOP_UP_ALGORITHM_H
9 #define LAR_SLIDING_CONE_PFO_MOP_UP_ALGORITHM_H 1
13 #include <unordered_map>
43 ClusterMerge(
const pandora::Cluster *
const pParentCluster,
const float boundedFraction1,
const float boundedFraction2);
83 pandora::StatusCode
Run();
92 typedef std::unordered_map<const pandora::Cluster *, const pandora::ParticleFlowObject *>
ClusterToPfoMap;
102 typedef std::unordered_map<const pandora::Cluster *, ClusterMergeList>
ClusterMergeMap;
127 bool IsVertexAssociated(
const pandora::Cluster *
const pCluster,
const pandora::Vertex *
const pVertex,
139 bool IsVertexAssociated(
const pandora::Cluster *
const pCluster,
const pandora::CartesianVector &vertexPosition,
152 pandora::StatusCode
ReadSettings(
const pandora::TiXmlHandle xmlHandle);
177 const pandora::Cluster *
const pParentCluster,
const float boundedFraction1,
const float boundedFraction2) :
178 m_pParentCluster(pParentCluster),
179 m_boundedFraction1(boundedFraction1),
180 m_boundedFraction2(boundedFraction2)
188 return m_pParentCluster;
195 return m_boundedFraction1;
202 return m_boundedFraction2;
207 #endif // #ifndef LAR_SLIDING_CONE_PFO_MOP_UP_ALGORITHM_H
std::unordered_map< const pandora::Cluster *, const pandora::Cluster * > ClusterReplacementMap
float GetBoundedFraction2() const
Get the bounded fraction for algorithm-specified cone angle 2.
void GetClusterMergeMap(const pandora::Vertex *const pVertex, const pandora::ClusterVector &clusters3D, const ClusterToPfoMap &clusterToPfoMap, ClusterMergeMap &clusterMergeMap) const
Get the cluster merge map describing all potential 3d cluster merges.
float m_coneBoundedFraction2
The minimum cluster bounded fraction for association 2.
void GetInteractionVertex(const pandora::Vertex *&pVertex) const
Get the neutrino interaction vertex if it is available and if the algorithm is configured to do so...
float m_boundedFraction1
The bounded fraction for algorithm-specified cone angle 1.
float m_maxConeLength
The maximum allowed cone length to use when calculating bounded cluster fractions.
float m_maxVertexTransverseDistance
Vertex association check: max transverse distance cut.
std::unordered_map< const pandora::Cluster *, const pandora::ParticleFlowObject * > ClusterToPfoMap
ClusterMerge(const pandora::Cluster *const pParentCluster, const float boundedFraction1, const float boundedFraction2)
Constructor.
float m_boundedFraction2
The bounded fraction for algorithm-specified cone angle 2.
float m_coneLengthMultiplier
The cone length multiplier to use when calculating bounded cluster fractions.
bool MakePfoMerges(const ClusterToPfoMap &clusterToPfoMap, const ClusterMergeMap &clusterMergeMap) const
Make pfo merges based on the provided cluster merge map.
void GetThreeDClusters(pandora::ClusterVector &clusters3D, ClusterToPfoMap &clusterToPfoMap) const
Get all 3d clusters contained in the input pfo lists and a mapping from clusters to pfos...
bool m_useVertex
Whether to use the interaction vertex to select useful cone directions.
float GetBoundedFraction1() const
Get the bounded fraction for algorithm-specified cone angle 1.
bool IsVertexAssociated(const pandora::Cluster *const pCluster, const pandora::Vertex *const pVertex, VertexAssociationMap &vertexAssociationMap, const ThreeDSlidingFitResult *const pSlidingFitResult=nullptr) const
Whether a 3D cluster is nodally associated with a provided vertex.
float m_minVertexLongitudinalDistance
Vertex association check: min longitudinal distance cut.
unsigned int m_nConeFitLayers
The number of layers over which to sum fitted direction to obtain cone fit.
SlidingConePfoMopUpAlgorithm()
Default constructor.
pandora::StatusCode ReadSettings(const pandora::TiXmlHandle xmlHandle)
const pandora::Cluster * m_pParentCluster
The address of the candidate parent (shower) cluster.
unsigned int m_maxHitsToConsider3DTrack
The maximum number of hits in a 3d track cluster to warrant inclusion in algorithm.
PfoMopUpBaseAlgorithm class.
float m_coneTanHalfAngle1
The cone tan half angle to use when calculating bounded cluster fractions 1.
pandora::StringVector m_inputPfoListNames
The input pfo list names.
std::vector< ClusterMerge > ClusterMergeList
float m_coneBoundedFraction1
The minimum cluster bounded fraction for association 1.
pandora::StatusCode Run()
std::unordered_map< const pandora::Cluster *, bool > VertexAssociationMap
SlidingConePfoMopUpAlgorithm class.
ThreeDSlidingFitResult class.
Header file for the pfo mop up algorithm base class.
unsigned int m_maxIterations
The maximum allowed number of algorithm iterations.
unsigned int m_minHitsToConsider3DShower
The minimum number of hits in a 3d shower cluster to attempt cone fits.
std::vector< art::Ptr< recob::Cluster > > ClusterVector
bool operator<(const ClusterMerge &rhs) const
operator <
unsigned int m_nConeFits
The number of cone fits to perform, spread roughly uniformly along the shower length.
std::unordered_map< const pandora::Cluster *, ClusterMergeList > ClusterMergeMap
const pandora::Cluster * GetParentCluster() const
Get the address of the candidate parent (shower) cluster.
float m_coneTanHalfAngle2
The cone tan half angle to use when calculating bounded cluster fractions 2.
unsigned int m_halfWindowLayers
The number of layers to use for half-window of sliding fit.