LArSoft
v07_13_02
Liquid Argon Software toolkit - http://larsoft.org/
|
ParticleRecoveryAlgorithm class. More...
#include "ParticleRecoveryAlgorithm.h"
Classes | |
class | SimpleOverlapTensor |
SimpleOverlapTensor class. More... | |
Public Member Functions | |
ParticleRecoveryAlgorithm () | |
Default constructor. More... | |
Private Member Functions | |
pandora::StatusCode | Run () |
void | GetInputClusters (pandora::ClusterList &inputClusterListU, pandora::ClusterList &inputClusterListV, pandora::ClusterList &inputClusterListW) const |
Get the input cluster lists for processing in this algorithm. More... | |
void | SelectInputClusters (const pandora::ClusterList &inputClusterList, pandora::ClusterList &selectedClusterList) const |
Select a subset of input clusters for processing in this algorithm. More... | |
void | StandardClusterSelection (const pandora::ClusterList &inputClusterList, pandora::ClusterList &selectedClusterList) const |
Select a subset of input clusters for processing in this algorithm. More... | |
void | VertexClusterSelection (const pandora::ClusterList &inputClusterList, pandora::ClusterList &selectedClusterList) const |
Select a subset of input clusters nodally associated with the vertices of existing particles. More... | |
void | FindOverlaps (const pandora::ClusterList &clusterList1, const pandora::ClusterList &clusterList2, SimpleOverlapTensor &overlapTensor) const |
Find cluster overlaps and record these in the overlap tensor. More... | |
bool | IsOverlap (const pandora::Cluster *const pCluster1, const pandora::Cluster *const pCluster2) const |
Whether two clusters overlap convincingly in x. More... | |
void | CalculateEffectiveOverlapFractions (const pandora::Cluster *const pCluster1, const float xMin1, const float xMax1, const pandora::Cluster *const pCluster2, const float xMin2, const float xMax2, float &xOverlapFraction1, float &xOverlapFraction2) const |
Calculate effective overlap fractions taking into account gaps. More... | |
void | CalculateEffectiveSpan (const pandora::Cluster *const pCluster, const float xMin, const float xMax, float &xMinEff, float &xMaxEff) const |
Calculate effective span for a given clsuter taking gaps into account. More... | |
void | ExamineTensor (const SimpleOverlapTensor &overlapTensor) const |
Identify unambiguous cluster overlaps and resolve ambiguous overlaps, creating new track particles. More... | |
bool | CheckConsistency (const pandora::Cluster *const pClusterU, const pandora::Cluster *const pClusterV, const pandora::Cluster *const pClusterW) const |
Whether a trio of clusters are consistent with representing projections of the same 3d trajectory. More... | |
void | CreateTrackParticle (const pandora::ClusterList &clusterList) const |
Create and save a track particle containing the provided clusters. More... | |
pandora::StatusCode | ReadSettings (const pandora::TiXmlHandle xmlHandle) |
Private Attributes | |
pandora::StringVector | m_inputClusterListNames |
The list of cluster list names. More... | |
std::string | m_outputPfoListName |
The output pfo list name. More... | |
bool | m_checkGaps |
Whether to check for gaps in the calculation of the overlap. More... | |
unsigned int | m_minClusterCaloHits |
The min number of hits in base cluster selection method. More... | |
float | m_minClusterLengthSquared |
The min length (squared) in base cluster selection method. More... | |
float | m_minClusterXSpan |
The min x span required in order to consider a cluster. More... | |
bool | m_vertexClusterMode |
Whether to demand clusters are associated with vertices of existing particles. More... | |
float | m_minVertexLongitudinalDistance |
Vertex association check: min longitudinal distance cut. More... | |
float | m_maxVertexTransverseDistance |
Vertex association check: max transverse distance cut. More... | |
float | m_minXOverlapFraction |
The min x overlap fraction required in order to id overlapping clusters. More... | |
float | m_minXOverlapFractionGaps |
The min x overlap fraction when there are gaps involved. More... | |
float | m_sampleStepSize |
The sampling step size used in association checks, units cm. More... | |
unsigned int | m_slidingFitHalfWindow |
The half window for the fit sliding result constructor. More... | |
float | m_pseudoChi2Cut |
The selection cut on the matched chi2. More... | |
ParticleRecoveryAlgorithm class.
Definition at line 21 of file ParticleRecoveryAlgorithm.h.
lar_content::ParticleRecoveryAlgorithm::ParticleRecoveryAlgorithm | ( | ) |
Default constructor.
Definition at line 26 of file ParticleRecoveryAlgorithm.cc.
|
private |
Calculate effective overlap fractions taking into account gaps.
pCluster1 | address of the first cluster |
xMin1 | min x value of the first cluster |
xMax1 | max x value of the first cluster |
pCluster2 | address of the second cluster |
xMin2 | min x value of the second cluster |
xMax2 | max x value of the second cluster |
xOverlapFraction1 | to receive the effective overlap fraction for the first cluster |
xOverlapFraction2 | to receive the effective overlap fraction for the second cluster |
Definition at line 230 of file ParticleRecoveryAlgorithm.cc.
References CalculateEffectiveSpan(), f, max, and min.
Referenced by IsOverlap().
|
private |
Calculate effective span for a given clsuter taking gaps into account.
pCluster | address of the cluster |
xMin | the min x value above which checks for gaps will be performed |
xMax | the max x value below which checks for gaps will be performed |
xMinEff | to receive the effective min x value for the cluster, including adjacent gaps |
xMaxEff | to receive the effective max x value for the cluster, including adjacent gaps |
Definition at line 255 of file ParticleRecoveryAlgorithm.cc.
References f, lar_content::LArGeometryHelper::GetWireZPitch(), lar_content::LArGeometryHelper::IsXSamplingPointInGap(), m_sampleStepSize, m_slidingFitHalfWindow, max, and min.
Referenced by CalculateEffectiveOverlapFractions().
|
private |
Whether a trio of clusters are consistent with representing projections of the same 3d trajectory.
pClusterU | the address of cluster u |
pClusterV | the address of cluster v |
pClusterW | the address of cluster w |
Definition at line 334 of file ParticleRecoveryAlgorithm.cc.
References f, lar_content::LArClusterHelper::GetAverageZ(), lar_content::LArClusterHelper::GetClusterSpanX(), m_pseudoChi2Cut, max, lar_content::LArGeometryHelper::MergeTwoPositions(), min, and w.
Referenced by ExamineTensor().
|
private |
Create and save a track particle containing the provided clusters.
clusterList | the cluster list |
Definition at line 373 of file ParticleRecoveryAlgorithm.cc.
References f, and m_outputPfoListName.
Referenced by ExamineTensor().
|
private |
Identify unambiguous cluster overlaps and resolve ambiguous overlaps, creating new track particles.
overlapTensor | the overlap tensor |
Definition at line 296 of file ParticleRecoveryAlgorithm.cc.
References CheckConsistency(), CreateTrackParticle(), lar_content::ParticleRecoveryAlgorithm::SimpleOverlapTensor::GetConnectedElements(), lar_content::ParticleRecoveryAlgorithm::SimpleOverlapTensor::GetKeyClusters(), and lar_content::LArClusterHelper::SortByNHits().
Referenced by Run().
|
private |
Find cluster overlaps and record these in the overlap tensor.
clusterList1 | the first cluster list |
clusterList2 | the second cluster list |
overlapTensor | the overlap tensor |
Definition at line 184 of file ParticleRecoveryAlgorithm.cc.
References lar_content::ParticleRecoveryAlgorithm::SimpleOverlapTensor::AddAssociation(), and IsOverlap().
Referenced by Run().
|
private |
Get the input cluster lists for processing in this algorithm.
inputClusterListU | to receive the list of clusters in the u view |
inputClusterListU | to receive the list of clusters in the v view |
inputClusterListU | to receive the list of clusters in the w view |
Definition at line 65 of file ParticleRecoveryAlgorithm.cc.
References lar_content::LArClusterHelper::GetClusterHitType(), and m_inputClusterListNames.
Referenced by Run().
|
private |
Whether two clusters overlap convincingly in x.
pCluster1 | address of the first cluster |
pCluster2 | address of the second cluster |
Definition at line 198 of file ParticleRecoveryAlgorithm.cc.
References CalculateEffectiveOverlapFractions(), f, lar_content::LArClusterHelper::GetClusterHitType(), lar_content::LArClusterHelper::GetClusterSpanX(), m_checkGaps, m_minXOverlapFraction, max, and min.
Referenced by FindOverlaps().
|
private |
Definition at line 472 of file ParticleRecoveryAlgorithm.cc.
References m_checkGaps, m_inputClusterListNames, m_maxVertexTransverseDistance, m_minClusterCaloHits, m_minClusterLengthSquared, m_minClusterXSpan, m_minVertexLongitudinalDistance, m_minXOverlapFraction, m_minXOverlapFractionGaps, m_outputPfoListName, m_pseudoChi2Cut, m_sampleStepSize, m_slidingFitHalfWindow, and m_vertexClusterMode.
|
private |
Definition at line 44 of file ParticleRecoveryAlgorithm.cc.
References ExamineTensor(), FindOverlaps(), GetInputClusters(), and SelectInputClusters().
|
private |
Select a subset of input clusters for processing in this algorithm.
inputClusterList | the input cluster list |
selectedClusterList | to receive the selected cluster list |
Definition at line 96 of file ParticleRecoveryAlgorithm.cc.
References m_vertexClusterMode, StandardClusterSelection(), and VertexClusterSelection().
Referenced by Run().
|
private |
Select a subset of input clusters for processing in this algorithm.
inputClusterList | the input cluster list |
selectedClusterList | to receive the selected cluster list |
Definition at line 112 of file ParticleRecoveryAlgorithm.cc.
References f, lar_content::LArClusterHelper::GetClusterSpanX(), lar_content::LArClusterHelper::GetLengthSquared(), m_minClusterCaloHits, m_minClusterLengthSquared, and m_minClusterXSpan.
Referenced by SelectInputClusters().
|
private |
Select a subset of input clusters nodally associated with the vertices of existing particles.
inputClusterList | the input cluster list |
selectedClusterList | to receive the selected cluster list |
Definition at line 139 of file ParticleRecoveryAlgorithm.cc.
References lar_content::LArPointingCluster::GetInnerVertex(), lar_content::LArPointingCluster::GetOuterVertex(), lar_content::LArPointingCluster::Vertex::GetPosition(), lar_content::LArPointingClusterHelper::IsNode(), m_maxVertexTransverseDistance, and m_minVertexLongitudinalDistance.
Referenced by SelectInputClusters().
|
private |
Whether to check for gaps in the calculation of the overlap.
Definition at line 180 of file ParticleRecoveryAlgorithm.h.
Referenced by IsOverlap(), and ReadSettings().
|
private |
The list of cluster list names.
Definition at line 177 of file ParticleRecoveryAlgorithm.h.
Referenced by GetInputClusters(), and ReadSettings().
|
private |
Vertex association check: max transverse distance cut.
Definition at line 188 of file ParticleRecoveryAlgorithm.h.
Referenced by ReadSettings(), and VertexClusterSelection().
|
private |
The min number of hits in base cluster selection method.
Definition at line 182 of file ParticleRecoveryAlgorithm.h.
Referenced by ReadSettings(), and StandardClusterSelection().
|
private |
The min length (squared) in base cluster selection method.
Definition at line 183 of file ParticleRecoveryAlgorithm.h.
Referenced by ReadSettings(), and StandardClusterSelection().
|
private |
The min x span required in order to consider a cluster.
Definition at line 184 of file ParticleRecoveryAlgorithm.h.
Referenced by ReadSettings(), and StandardClusterSelection().
|
private |
Vertex association check: min longitudinal distance cut.
Definition at line 187 of file ParticleRecoveryAlgorithm.h.
Referenced by ReadSettings(), and VertexClusterSelection().
|
private |
The min x overlap fraction required in order to id overlapping clusters.
Definition at line 190 of file ParticleRecoveryAlgorithm.h.
Referenced by IsOverlap(), and ReadSettings().
|
private |
The min x overlap fraction when there are gaps involved.
Definition at line 191 of file ParticleRecoveryAlgorithm.h.
Referenced by ReadSettings().
|
private |
The output pfo list name.
Definition at line 178 of file ParticleRecoveryAlgorithm.h.
Referenced by CreateTrackParticle(), and ReadSettings().
|
private |
The selection cut on the matched chi2.
Definition at line 194 of file ParticleRecoveryAlgorithm.h.
Referenced by CheckConsistency(), and ReadSettings().
|
private |
The sampling step size used in association checks, units cm.
Definition at line 192 of file ParticleRecoveryAlgorithm.h.
Referenced by CalculateEffectiveSpan(), and ReadSettings().
|
private |
The half window for the fit sliding result constructor.
Definition at line 193 of file ParticleRecoveryAlgorithm.h.
Referenced by CalculateEffectiveSpan(), and ReadSettings().
|
private |
Whether to demand clusters are associated with vertices of existing particles.
Definition at line 186 of file ParticleRecoveryAlgorithm.h.
Referenced by ReadSettings(), and SelectInputClusters().