LArSoft
v07_13_02
Liquid Argon Software toolkit - http://larsoft.org/
|
MissingTrackSegmentTool class. More...
#include "MissingTrackSegmentTool.h"
Classes | |
class | Particle |
Particle class. More... | |
class | SegmentOverlap |
SegmentOverlap class. More... | |
Public Types | |
typedef ThreeDTransverseTracksAlgorithm::TensorType | TensorType |
typedef std::vector< TensorType::ElementList::const_iterator > | IteratorList |
Public Member Functions | |
MissingTrackSegmentTool () | |
Default constructor. More... | |
bool | Run (ThreeDTransverseTracksAlgorithm *const pAlgorithm, TensorType &overlapTensor) |
Run the algorithm tool. More... | |
Private Types | |
typedef std::unordered_map< const pandora::Cluster *, SegmentOverlap > | SegmentOverlapMap |
typedef std::unordered_map< const pandora::Cluster *, pandora::ClusterList > | ClusterMergeMap |
Private Member Functions | |
pandora::StatusCode | ReadSettings (const pandora::TiXmlHandle xmlHandle) |
void | FindTracks (ThreeDTransverseTracksAlgorithm *const pAlgorithm, const TensorType &overlapTensor, ProtoParticleVector &protoParticleVector, ClusterMergeMap &clusterMergeMap) const |
Find remaining tracks, hidden by missing track segments (and maybe other ambiguities) in the tensor. More... | |
void | SelectElements (const TensorType::ElementList &elementList, const pandora::ClusterSet &usedClusters, IteratorList &iteratorList) const |
Select a list of the relevant elements from a set of connected tensor elements. More... | |
bool | PassesParticleChecks (ThreeDTransverseTracksAlgorithm *const pAlgorithm, const TensorType::Element &element, pandora::ClusterSet &usedClusters, ClusterMergeMap &clusterMergeMap) const |
Whether a provided tensor element can be used to construct a pfo. More... | |
void | GetCandidateClusters (ThreeDTransverseTracksAlgorithm *const pAlgorithm, const Particle &particle, pandora::ClusterList &candidateClusters) const |
Get a list of candidate clusters, which may represent missing track segments for a provided particle. More... | |
void | GetSlidingFitResultMap (ThreeDTransverseTracksAlgorithm *const pAlgorithm, const pandora::ClusterList &candidateClusterList, TwoDSlidingFitResultMap &slidingFitResultMap) const |
Get a sliding fit result map for the list of candidate clusters. More... | |
void | GetSegmentOverlapMap (ThreeDTransverseTracksAlgorithm *const pAlgorithm, const Particle &particle, const TwoDSlidingFitResultMap &slidingFitResultMap, SegmentOverlapMap &segmentOverlapMap) const |
Get a segment overlap map, describing overlap between a provided particle and all clusters in a sliding fit result map. More... | |
bool | MakeDecisions (const Particle &particle, const TwoDSlidingFitResultMap &slidingFitResultMap, const SegmentOverlapMap &segmentOverlapMap, pandora::ClusterSet &usedClusters, ClusterMergeMap &clusterMergeMap) const |
Make decisions about whether to create a pfo for a provided particle and whether to make cluster merges. More... | |
bool | PassesSamplingCuts (const SegmentOverlap &segmentOverlap) const |
Whether the segment overlap object passes cuts on matched sampling points, etc. More... | |
bool | IsPossibleMerge (const pandora::Cluster *const pCluster, const Particle &particle, const SegmentOverlap &segmentOverlap, const TwoDSlidingFitResultMap &slidingFitResultMap) const |
Whether the cluster could be merged with the candidate particle. More... | |
Private Attributes | |
float | m_minMatchedFraction |
The min matched sampling point fraction for particle creation. More... | |
unsigned int | m_minMatchedSamplingPoints |
The min number of matched sampling points for particle creation. More... | |
unsigned int | m_minMatchedSamplingPointRatio |
The min ratio between 1st and 2nd highest msps for simple ambiguity resolution. More... | |
float | m_minInitialXOverlapFraction |
The min x overlap fraction (between long clusters and short cluster vs. shared overlap) More... | |
float | m_minFinalXOverlapFraction |
The min x overlap fraction between extended short cluster and the long clusters. More... | |
unsigned int | m_minCaloHitsInCandidateCluster |
The min no. of calo hits in a candidate cluster, for matching with long clusters. More... | |
float | m_pseudoChi2Cut |
The pseudo chi2 cut to determine whether a sampling point is matched. More... | |
unsigned int | m_makePfoMinSamplingPoints |
The min number of sampling points in order to be able to make pfo. More... | |
unsigned int | m_makePfoMinMatchedSamplingPoints |
The min number of matched sampling points in order to be able to make pfo. More... | |
float | m_makePfoMinMatchedFraction |
The min matched sampling point fraction in order to be able to make pfo. More... | |
float | m_makePfoMaxImpactParameter |
The max transverse impact parameter in order to be able to make pfo. More... | |
float | m_mergeMaxChi2PerSamplingPoint |
The max value of chi2 per sampling point in order to merge cluster with parent. More... | |
float | m_mergeXContainmentTolerance |
The tolerance in determining whether candidate cluster is contained in x window. More... | |
MissingTrackSegmentTool class.
Definition at line 21 of file MissingTrackSegmentTool.h.
|
private |
Definition at line 78 of file MissingTrackSegmentTool.h.
|
inherited |
Definition at line 128 of file ThreeDTransverseTracksAlgorithm.h.
|
private |
Definition at line 77 of file MissingTrackSegmentTool.h.
|
inherited |
Definition at line 127 of file ThreeDTransverseTracksAlgorithm.h.
lar_content::MissingTrackSegmentTool::MissingTrackSegmentTool | ( | ) |
Default constructor.
Definition at line 25 of file MissingTrackSegmentTool.cc.
|
private |
Find remaining tracks, hidden by missing track segments (and maybe other ambiguities) in the tensor.
pAlgorithm | address of the calling algorithm |
overlapTensor | the overlap tensor |
protoParticleVector | to receive the list of proto particles |
clusterMergeMap | to receive the cluster merge map |
Definition at line 60 of file MissingTrackSegmentTool.cc.
References lar_content::OverlapTensor< T >::GetConnectedElements(), lar_content::OverlapTensor< T >::GetSortedKeyClusters(), lar_content::LongTracksTool::HasLongDirectConnections(), lar_content::LongTracksTool::IsLongerThanDirectConnections(), lar_content::ProtoParticle::m_clusterListU, lar_content::ProtoParticle::m_clusterListV, lar_content::ProtoParticle::m_clusterListW, m_minMatchedSamplingPointRatio, PassesParticleChecks(), and SelectElements().
Referenced by Run().
|
private |
Get a list of candidate clusters, which may represent missing track segments for a provided particle.
pAlgorithm | address of the calling algorithm |
particle | the particle |
candidateClusters | to receive the list of candidate clusters |
Definition at line 171 of file MissingTrackSegmentTool.cc.
References lar_content::ThreeDBaseAlgorithm< T >::GetInputClusterListU(), lar_content::ThreeDBaseAlgorithm< T >::GetInputClusterListV(), lar_content::ThreeDBaseAlgorithm< T >::GetInputClusterListW(), m_minCaloHitsInCandidateCluster, lar_content::MissingTrackSegmentTool::Particle::m_pShortCluster, and lar_content::MissingTrackSegmentTool::Particle::m_shortHitType.
Referenced by PassesParticleChecks().
|
private |
Get a segment overlap map, describing overlap between a provided particle and all clusters in a sliding fit result map.
pAlgorithm | address of the calling algorithm |
particle | the particle |
slidingFitResultMap | the sliding fit result map |
segmentOverlapMap | to receive the segment overlap map |
Definition at line 226 of file MissingTrackSegmentTool.cc.
References f, lar_content::ThreeDTracksBaseAlgorithm< T >::GetCachedSlidingFitResult(), lar_content::MissingTrackSegmentTool::Particle::m_hitType1, lar_content::MissingTrackSegmentTool::Particle::m_hitType2, lar_content::MissingTrackSegmentTool::Particle::m_longMaxX, lar_content::MissingTrackSegmentTool::Particle::m_longMinX, lar_content::MissingTrackSegmentTool::SegmentOverlap::m_matchedSamplingMaxX, lar_content::MissingTrackSegmentTool::SegmentOverlap::m_matchedSamplingMinX, lar_content::MissingTrackSegmentTool::SegmentOverlap::m_nMatchedSamplingPoints, lar_content::MissingTrackSegmentTool::SegmentOverlap::m_nSamplingPoints, lar_content::MissingTrackSegmentTool::Particle::m_pCluster1, lar_content::MissingTrackSegmentTool::Particle::m_pCluster2, m_pseudoChi2Cut, lar_content::MissingTrackSegmentTool::SegmentOverlap::m_pseudoChi2Sum, lar_content::MissingTrackSegmentTool::Particle::m_shortMaxX, lar_content::MissingTrackSegmentTool::Particle::m_shortMinX, max, lar_content::LArGeometryHelper::MergeTwoPositions(), min, n, lar_content::LArClusterHelper::SortByNHits(), and x.
Referenced by PassesParticleChecks().
|
private |
Get a sliding fit result map for the list of candidate clusters.
pAlgorithm | address of the calling algorithm |
candidateClusters | the list of candidate clusters |
slidingFitResultMap | to receive the sliding fit result map |
Definition at line 193 of file MissingTrackSegmentTool.cc.
References lar_content::ThreeDTracksBaseAlgorithm< T >::GetCachedSlidingFitResult(), lar_content::ThreeDTracksBaseAlgorithm< T >::GetSlidingFitWindow(), and lar_content::LArGeometryHelper::GetWireZPitch().
Referenced by PassesParticleChecks().
|
private |
Whether the cluster could be merged with the candidate particle.
pCluster | address of the cluster |
particle | the particle |
segmentOverlap | the segment overlap |
slidingFitResultMap | the sliding fit result map |
Definition at line 352 of file MissingTrackSegmentTool.cc.
References lar_content::MissingTrackSegmentTool::Particle::m_longMaxX, lar_content::MissingTrackSegmentTool::Particle::m_longMinX, m_mergeMaxChi2PerSamplingPoint, m_mergeXContainmentTolerance, lar_content::MissingTrackSegmentTool::SegmentOverlap::m_nSamplingPoints, lar_content::MissingTrackSegmentTool::SegmentOverlap::m_pseudoChi2Sum, lar_content::MissingTrackSegmentTool::Particle::m_shortMaxX, lar_content::MissingTrackSegmentTool::Particle::m_shortMinX, and max.
Referenced by MakeDecisions().
|
private |
Make decisions about whether to create a pfo for a provided particle and whether to make cluster merges.
particle | the particle |
slidingFitResultMap | the sliding fit result map |
segmentOverlapMap | the segment overlap map |
usedClusters | the list of used clusters |
clusterMergeMap | to receive details of cluster merges clusterMergeMap |
Definition at line 288 of file MissingTrackSegmentTool.cc.
References IsPossibleMerge(), lar_content::MissingTrackSegmentTool::Particle::m_longMaxX, lar_content::MissingTrackSegmentTool::Particle::m_longMinX, m_minFinalXOverlapFraction, lar_content::MissingTrackSegmentTool::Particle::m_pShortCluster, lar_content::MissingTrackSegmentTool::Particle::m_shortMaxX, lar_content::MissingTrackSegmentTool::Particle::m_shortMinX, max, min, PassesSamplingCuts(), and lar_content::LArClusterHelper::SortByNHits().
Referenced by PassesParticleChecks().
|
private |
Whether a provided tensor element can be used to construct a pfo.
pAlgorithm | address of the calling algorithm |
element | the tensor element |
usedClusters | the list of used clusters |
clusterMergeMap | to receive the cluster merge map |
Definition at line 136 of file MissingTrackSegmentTool.cc.
References GetCandidateClusters(), GetSegmentOverlapMap(), GetSlidingFitResultMap(), and MakeDecisions().
Referenced by FindTracks().
|
private |
Whether the segment overlap object passes cuts on matched sampling points, etc.
segmentOverlap | the segment overlap |
Definition at line 336 of file MissingTrackSegmentTool.cc.
References m_makePfoMinMatchedFraction, m_makePfoMinMatchedSamplingPoints, m_makePfoMinSamplingPoints, lar_content::MissingTrackSegmentTool::SegmentOverlap::m_nMatchedSamplingPoints, and lar_content::MissingTrackSegmentTool::SegmentOverlap::m_nSamplingPoints.
Referenced by MakeDecisions().
|
private |
Definition at line 406 of file MissingTrackSegmentTool.cc.
References m_makePfoMaxImpactParameter, m_makePfoMinMatchedFraction, m_makePfoMinMatchedSamplingPoints, m_makePfoMinSamplingPoints, m_mergeMaxChi2PerSamplingPoint, m_mergeXContainmentTolerance, m_minCaloHitsInCandidateCluster, m_minFinalXOverlapFraction, m_minInitialXOverlapFraction, m_minMatchedFraction, m_minMatchedSamplingPointRatio, m_minMatchedSamplingPoints, and m_pseudoChi2Cut.
|
virtual |
Run the algorithm tool.
pAlgorithm | address of the calling algorithm |
overlapTensor | the overlap tensor |
Implements lar_content::TransverseTensorTool.
Definition at line 44 of file MissingTrackSegmentTool.cc.
References lar_content::ThreeDBaseAlgorithm< T >::CreateThreeDParticles(), FindTracks(), and lar_content::ThreeDBaseAlgorithm< T >::MakeClusterMerges().
|
private |
Select a list of the relevant elements from a set of connected tensor elements.
elementList | the full list of connected tensor elements |
usedClusters | the list of clusters already marked as to be added to a pfo |
iteratorList | to receive a list of iterators to long track-like elements |
Definition at line 105 of file MissingTrackSegmentTool.cc.
References m_minInitialXOverlapFraction, m_minMatchedFraction, m_minMatchedSamplingPoints, max, and min.
Referenced by FindTracks().
|
private |
The max transverse impact parameter in order to be able to make pfo.
Definition at line 190 of file MissingTrackSegmentTool.h.
Referenced by ReadSettings().
|
private |
The min matched sampling point fraction in order to be able to make pfo.
Definition at line 189 of file MissingTrackSegmentTool.h.
Referenced by PassesSamplingCuts(), and ReadSettings().
|
private |
The min number of matched sampling points in order to be able to make pfo.
Definition at line 188 of file MissingTrackSegmentTool.h.
Referenced by PassesSamplingCuts(), and ReadSettings().
|
private |
The min number of sampling points in order to be able to make pfo.
Definition at line 187 of file MissingTrackSegmentTool.h.
Referenced by PassesSamplingCuts(), and ReadSettings().
|
private |
The max value of chi2 per sampling point in order to merge cluster with parent.
Definition at line 192 of file MissingTrackSegmentTool.h.
Referenced by IsPossibleMerge(), and ReadSettings().
|
private |
The tolerance in determining whether candidate cluster is contained in x window.
Definition at line 193 of file MissingTrackSegmentTool.h.
Referenced by IsPossibleMerge(), and ReadSettings().
|
private |
The min no. of calo hits in a candidate cluster, for matching with long clusters.
Definition at line 184 of file MissingTrackSegmentTool.h.
Referenced by GetCandidateClusters(), and ReadSettings().
|
private |
The min x overlap fraction between extended short cluster and the long clusters.
Definition at line 182 of file MissingTrackSegmentTool.h.
Referenced by MakeDecisions(), and ReadSettings().
|
private |
The min x overlap fraction (between long clusters and short cluster vs. shared overlap)
Definition at line 181 of file MissingTrackSegmentTool.h.
Referenced by ReadSettings(), and SelectElements().
|
private |
The min matched sampling point fraction for particle creation.
Definition at line 177 of file MissingTrackSegmentTool.h.
Referenced by ReadSettings(), and SelectElements().
|
private |
The min ratio between 1st and 2nd highest msps for simple ambiguity resolution.
Definition at line 179 of file MissingTrackSegmentTool.h.
Referenced by FindTracks(), and ReadSettings().
|
private |
The min number of matched sampling points for particle creation.
Definition at line 178 of file MissingTrackSegmentTool.h.
Referenced by ReadSettings(), and SelectElements().
|
private |
The pseudo chi2 cut to determine whether a sampling point is matched.
Definition at line 185 of file MissingTrackSegmentTool.h.
Referenced by GetSegmentOverlapMap(), and ReadSettings().