Pandora
Pandora source code navigator
Loading...
Searching...
No Matches
TracksCrossingGapsTool.h
Go to the documentation of this file.
1
8#ifndef TRACKS_CROSSING_GAPS_TOOL_H
9#define TRACKS_CROSSING_GAPS_TOOL_H 1
10
13
14namespace lar_content
15{
16
21{
22public:
27
28 bool Run(ThreeViewTransverseTracksAlgorithm *const pAlgorithm, TensorType &overlapTensor);
29
30private:
32
40 void FindTracks(ThreeViewTransverseTracksAlgorithm *const pAlgorithm, const TensorType &overlapTensor, ProtoParticleVector &protoParticleVector) const;
41
50 void SelectElements(ThreeViewTransverseTracksAlgorithm *const pAlgorithm, const TensorType::ElementList &elementList,
51 const pandora::ClusterSet &usedClusters, IteratorList &iteratorList) const;
52
62 void CalculateEffectiveOverlapFractions(ThreeViewTransverseTracksAlgorithm *const pAlgorithm, const TensorType::Element &element,
63 float &xOverlapFractionU, float &xOverlapFractionV, float &xOverlapFractionW) const;
64
77 void CalculateEffectiveOverlapSpan(ThreeViewTransverseTracksAlgorithm *const pAlgorithm, const TensorType::Element &element,
78 float &xMinEffU, float &xMaxEffU, float &xMinEffV, float &xMaxEffV, float &xMinEffW, float &xMaxEffW) const;
79
92 bool PassesGapChecks(ThreeViewTransverseTracksAlgorithm *const pAlgorithm, const TensorType::Element &element, const float xSample,
93 bool &gapInU, bool &gapInV, bool &gapInW) const;
94
108 bool CheckXPositionInGap(const float xSample, const TwoDSlidingFitResult &slidingFitResult1, const TwoDSlidingFitResult &slidingFitResult2,
109 const TwoDSlidingFitResult &slidingFitResult3, bool &gapIn1, bool &gapIn2, bool &gapIn3) const;
110
119 bool IsEndOfCluster(const float xSample, const TwoDSlidingFitResult &slidingFitResult) const;
120
127 unsigned int m_maxAngleRatio;
128};
129
130} // namespace lar_content
131
132#endif // #ifndef LONG_TRACKS_TOOL_H
Header file for the lar track overlap result class.
Header file for the three view transverse tracks algorithm class.
unsigned int m_maxAngleRatio
The max ratio allowed in the angle.
bool CheckXPositionInGap(const float xSample, const TwoDSlidingFitResult &slidingFitResult1, const TwoDSlidingFitResult &slidingFitResult2, const TwoDSlidingFitResult &slidingFitResult3, bool &gapIn1, bool &gapIn2, bool &gapIn3) const
Check individually each cluster where a gap might be present.
bool Run(ThreeViewTransverseTracksAlgorithm *const pAlgorithm, TensorType &overlapTensor)
Run the algorithm tool.
float m_maxGapTolerance
The max gap tolerance.
float m_minMatchedFraction
The min matched sampling point fraction for particle creation.
void CalculateEffectiveOverlapFractions(ThreeViewTransverseTracksAlgorithm *const pAlgorithm, const TensorType::Element &element, float &xOverlapFractionU, float &xOverlapFractionV, float &xOverlapFractionW) const
Calculate the effective overlap fractions given a set of clusters, taking gaps into account.
void SelectElements(ThreeViewTransverseTracksAlgorithm *const pAlgorithm, const TensorType::ElementList &elementList, const pandora::ClusterSet &usedClusters, IteratorList &iteratorList) const
Select a list of track-like elements crossing a gap in one or more views from a set of connected tens...
bool IsEndOfCluster(const float xSample, const TwoDSlidingFitResult &slidingFitResult) const
Check whether a x position is at the end of the cluster.
unsigned int m_minMatchedSamplingPoints
The min number of matched sampling points for particle creation.
void CalculateEffectiveOverlapSpan(ThreeViewTransverseTracksAlgorithm *const pAlgorithm, const TensorType::Element &element, float &xMinEffU, float &xMaxEffU, float &xMinEffV, float &xMaxEffV, float &xMinEffW, float &xMaxEffW) const
Calculate the effective overlap span given a set of clusters, taking gaps into account.
void FindTracks(ThreeViewTransverseTracksAlgorithm *const pAlgorithm, const TensorType &overlapTensor, ProtoParticleVector &protoParticleVector) const
Find tracks crossing gaps, with unambiguous connection but poor overlap due to gaps.
float m_minXOverlapFraction
The min x overlap fraction (in each view) for particle creation.
float m_sampleStepSize
The sampling step size used in association checks, units cm.
unsigned int m_minMatchedSamplingPointRatio
The min ratio between 1st and 2nd highest msps for simple ambiguity resolution.
pandora::StatusCode ReadSettings(const pandora::TiXmlHandle xmlHandle)
Read the algorithm settings.
bool PassesGapChecks(ThreeViewTransverseTracksAlgorithm *const pAlgorithm, const TensorType::Element &element, const float xSample, bool &gapInU, bool &gapInV, bool &gapInW) const
Check whether there is any gap in the three U-V-W clusters combination.
ThreeViewTransverseTracksAlgorithm::MatchingType::TensorType TensorType
std::vector< TensorType::ElementList::const_iterator > IteratorList
std::vector< ProtoParticle > ProtoParticleVector
std::unordered_set< const Cluster * > ClusterSet
StatusCode
The StatusCode enum.