![]() |
LArSoft
v10_06_00
Liquid Argon Software toolkit - https://larsoft.org/
|
ClusterAssociationAlgorithm class. More...
#include "ClusterAssociationAlgorithm.h"
Classes | |
| class | ClusterAssociation |
| ClusterAssociation class. More... | |
Public Member Functions | |
| ClusterAssociationAlgorithm () | |
| Default constructor. More... | |
Protected Types | |
| typedef std::unordered_map< const pandora::Cluster *, ClusterAssociation > | ClusterAssociationMap |
Protected Member Functions | |
| virtual pandora::StatusCode | Run () |
| virtual pandora::StatusCode | ReadSettings (const pandora::TiXmlHandle xmlHandle) |
| virtual void | GetListOfCleanClusters (const pandora::ClusterList *const pClusterList, pandora::ClusterVector &clusterVector) const =0 |
| Populate cluster vector with subset of cluster list, containing clusters judged to be clean. More... | |
| virtual void | PopulateClusterAssociationMap (const pandora::ClusterVector &clusterVector, ClusterAssociationMap &clusterAssociationMap) const =0 |
| Populate the cluster association map. More... | |
| virtual bool | IsExtremalCluster (const bool isForward, const pandora::Cluster *const pCurrentCluster, const pandora::Cluster *const pTestCluster) const =0 |
| Determine which of two clusters is extremal. More... | |
Private Member Functions | |
| void | UnambiguousPropagation (const pandora::Cluster *const pCluster, const bool isForward, ClusterAssociationMap &clusterAssociationMap) const |
| Unambiguous propagation. More... | |
| void | AmbiguousPropagation (const pandora::Cluster *const pCluster, const bool isForward, ClusterAssociationMap &clusterAssociationMap) const |
| Ambiguous propagation. More... | |
| void | UpdateForUnambiguousMerge (const pandora::Cluster *const pClusterToEnlarge, const pandora::Cluster *const pClusterToDelete, const bool isForwardMerge, ClusterAssociationMap &clusterAssociationMap) const |
| Update cluster association map to reflect an unambiguous cluster merge. More... | |
| void | UpdateForAmbiguousMerge (const pandora::Cluster *const pCluster, ClusterAssociationMap &clusterAssociationMap) const |
| Update cluster association map to reflect an ambiguous cluster merge. More... | |
| void | NavigateAlongAssociations (const ClusterAssociationMap &clusterAssociationMap, const pandora::Cluster *const pCluster, const bool isForward, const pandora::Cluster *&pExtremalCluster, pandora::ClusterSet &clusterSet) const |
| Navigate along cluster associations, from specified cluster, in specified direction. More... | |
Private Attributes | |
| bool | m_mergeMade |
| bool | m_resolveAmbiguousAssociations |
| Whether to resolve ambiguous associations. More... | |
ClusterAssociationAlgorithm class.
Definition at line 21 of file ClusterAssociationAlgorithm.h.
|
protected |
Definition at line 43 of file ClusterAssociationAlgorithm.h.
| lar_content::ClusterAssociationAlgorithm::ClusterAssociationAlgorithm | ( | ) |
Default constructor.
Definition at line 20 of file ClusterAssociationAlgorithm.cc.
|
private |
Ambiguous propagation.
| pCluster | address of the cluster to propagate |
| isForward | whether propagation direction is forward |
| clusterAssociationMap | the cluster association map |
Definition at line 123 of file ClusterAssociationAlgorithm.cc.
References m_mergeMade, NavigateAlongAssociations(), lar_content::LArClusterHelper::SortByNHits(), and UpdateForAmbiguousMerge().
Referenced by Run().
|
protectedpure virtual |
Populate cluster vector with subset of cluster list, containing clusters judged to be clean.
| pClusterList | address of the cluster list |
| clusterVector | to receive the populated cluster vector |
Implemented in lar_content::TransverseAssociationAlgorithm, lar_content::LongitudinalAssociationAlgorithm, lar_content::CrossGapsAssociationAlgorithm, and lar_content::HitWidthClusterMergingAlgorithm.
Referenced by Run().
|
protectedpure virtual |
Determine which of two clusters is extremal.
| isForward | whether propagation direction is forward |
| pCurrentCluster | current extremal cluster |
| pTestCluster | potential extremal cluster |
Implemented in lar_content::TransverseAssociationAlgorithm, lar_content::LongitudinalAssociationAlgorithm, lar_content::CrossGapsAssociationAlgorithm, and lar_content::HitWidthClusterMergingAlgorithm.
Referenced by NavigateAlongAssociations().
|
private |
Navigate along cluster associations, from specified cluster, in specified direction.
| clusterAssociationMap | the cluster association map |
| pCluster | address of cluster with which to begin search |
| isForward | whether propagation direction is forward |
| pExtremalCluster | to receive the extremal cluster |
| clusterSet | to receive set of clusters traversed |
Definition at line 233 of file ClusterAssociationAlgorithm.cc.
References IsExtremalCluster().
Referenced by AmbiguousPropagation().
|
protectedpure virtual |
Populate the cluster association map.
| clusterVector | the cluster vector |
| clusterAssociationMap | to receive the populated cluster association map |
Implemented in lar_content::TransverseAssociationAlgorithm, lar_content::LongitudinalAssociationAlgorithm, lar_content::CrossGapsAssociationAlgorithm, and lar_content::HitWidthClusterMergingAlgorithm.
Referenced by Run().
|
protectedvirtual |
Reimplemented in lar_content::HitWidthClusterMergingAlgorithm, lar_content::TransverseAssociationAlgorithm, lar_content::CrossGapsAssociationAlgorithm, and lar_content::LongitudinalAssociationAlgorithm.
Definition at line 256 of file ClusterAssociationAlgorithm.cc.
References m_resolveAmbiguousAssociations.
Referenced by lar_content::LongitudinalAssociationAlgorithm::ReadSettings(), lar_content::CrossGapsAssociationAlgorithm::ReadSettings(), lar_content::TransverseAssociationAlgorithm::ReadSettings(), and lar_content::HitWidthClusterMergingAlgorithm::ReadSettings().
|
protectedvirtual |
Definition at line 28 of file ClusterAssociationAlgorithm.cc.
References AmbiguousPropagation(), GetListOfCleanClusters(), m_mergeMade, m_resolveAmbiguousAssociations, PopulateClusterAssociationMap(), and UnambiguousPropagation().
|
private |
Unambiguous propagation.
| pCluster | address of the cluster to propagate |
| isForward | whether propagation direction is forward |
| clusterAssociationMap | the cluster association map |
Definition at line 89 of file ClusterAssociationAlgorithm.cc.
References m_mergeMade, and UpdateForUnambiguousMerge().
Referenced by Run().
|
private |
Update cluster association map to reflect an ambiguous cluster merge.
| pCluster | address of the cluster to be cleared |
| clusterAssociationMap | the cluster association map |
Definition at line 206 of file ClusterAssociationAlgorithm.cc.
Referenced by AmbiguousPropagation().
|
private |
Update cluster association map to reflect an unambiguous cluster merge.
| pClusterToEnlarge | address of the cluster to be enlarged |
| pClusterToDelete | address of the cluster to be deleted |
| isForwardMerge | whether merge is forward (pClusterToEnlarge is forward-associated with pClusterToDelete) |
| clusterAssociationMap | the cluster association map |
Definition at line 168 of file ClusterAssociationAlgorithm.cc.
Referenced by UnambiguousPropagation().
|
mutableprivate |
Definition at line 123 of file ClusterAssociationAlgorithm.h.
Referenced by AmbiguousPropagation(), Run(), and UnambiguousPropagation().
|
private |
Whether to resolve ambiguous associations.
Definition at line 125 of file ClusterAssociationAlgorithm.h.
Referenced by ReadSettings(), and Run().