Pandora
Pandora source code navigator
Loading...
Searching...
No Matches
ThreeViewTransverseTracksAlgorithm.h
Go to the documentation of this file.
1
8#ifndef LAR_THREE_VIEW_TRANSVERSE_TRACKS_ALGORITHM_H
9#define LAR_THREE_VIEW_TRANSVERSE_TRACKS_ALGORITHM_H 1
10
11#include "Pandora/Algorithm.h"
13
15
18
19namespace lar_content
20{
21
22class TransverseTensorTool;
23
24//------------------------------------------------------------------------------------------------------------------------------------------
25
29class ThreeViewTransverseTracksAlgorithm : public NViewTrackMatchingAlgorithm<ThreeViewMatchingControl<TransverseOverlapResult>>
30{
31public:
33
38
39private:
40 typedef std::map<unsigned int, TransverseOverlapResult> FitSegmentToOverlapResultMap;
41 typedef std::map<unsigned int, FitSegmentToOverlapResultMap> FitSegmentMatrix;
42 typedef std::map<unsigned int, FitSegmentMatrix> FitSegmentTensor;
43
44 void CalculateOverlapResult(const pandora::Cluster *const pClusterU, const pandora::Cluster *const pClusterV, const pandora::Cluster *const pClusterW);
45
56 pandora::StatusCode CalculateOverlapResult(const pandora::Cluster *const pClusterU, const pandora::Cluster *const pClusterV,
57 const pandora::Cluster *const pClusterW, TransverseOverlapResult &overlapResult);
58
67 void GetFitSegmentTensor(const TwoDSlidingFitResult &slidingFitResultU, const TwoDSlidingFitResult &slidingFitResultV,
68 const TwoDSlidingFitResult &slidingFitResultW, FitSegmentTensor &fitSegmentTensor) const;
69
83 pandora::StatusCode GetSegmentOverlap(const FitSegment &fitSegmentU, const FitSegment &fitSegmentV, const FitSegment &fitSegmentW,
84 const TwoDSlidingFitResult &slidingFitResultU, const TwoDSlidingFitResult &slidingFitResultV,
85 const TwoDSlidingFitResult &slidingFitResultW, TransverseOverlapResult &transverseOverlapResult) const;
86
93 void GetBestOverlapResult(const FitSegmentTensor &fitSegmentTensor, TransverseOverlapResult &bestTransverseOverlapResult) const;
94
103 void GetPreviousOverlapResults(const unsigned int indexU, const unsigned int indexV, const unsigned int indexW,
104 FitSegmentTensor &fitSegmentSumTensor, TransverseOverlapResultVector &transverseOverlapResultVector) const;
105
108
109 typedef std::vector<TransverseTensorTool *> TensorToolVector;
111
113 unsigned int m_maxFitSegmentIndex;
120};
121
122//------------------------------------------------------------------------------------------------------------------------------------------
123
128{
129public:
130 typedef ThreeViewTransverseTracksAlgorithm::MatchingType::TensorType TensorType;
131 typedef std::vector<TensorType::ElementList::const_iterator> IteratorList;
132
141 virtual bool Run(ThreeViewTransverseTracksAlgorithm *const pAlgorithm, TensorType &overlapTensor) = 0;
142};
143
144} // namespace lar_content
145
146#endif // #ifndef LAR_THREE_VIEW_TRANSVERSE_TRACKS_ALGORITHM_H
Header file for the algorithm class.
Header file for the algorithm tool class.
Header file for the lar track overlap result class.
Header file for the n view track matching algorithm class.
Header file for the three view matching control class.
std::map< unsigned int, FitSegmentMatrix > FitSegmentTensor
float m_minSamplingPointsPerLayer
The minimum number of sampling points per layer to allow particle creation.
float m_minOverallMatchedFraction
The minimum matched sampling fraction to allow particle creation.
pandora::StatusCode ReadSettings(const pandora::TiXmlHandle xmlHandle)
Read the algorithm settings.
void CalculateOverlapResult(const pandora::Cluster *const pClusterU, const pandora::Cluster *const pClusterV, const pandora::Cluster *const pClusterW)
Calculate cluster overlap result and store in container.
void ExamineOverlapContainer()
Examine contents of overlap container, collect together best-matching 2D particles and modify cluster...
unsigned int m_maxFitSegmentIndex
The maximum number of fit segments used when identifying best overlap result.
void GetFitSegmentTensor(const TwoDSlidingFitResult &slidingFitResultU, const TwoDSlidingFitResult &slidingFitResultV, const TwoDSlidingFitResult &slidingFitResultW, FitSegmentTensor &fitSegmentTensor) const
Get the number of matched points for three fit segments and accompanying sliding fit results.
std::map< unsigned int, TransverseOverlapResult > FitSegmentToOverlapResultMap
unsigned int m_nMaxTensorToolRepeats
The maximum number of repeat loops over tensor tools.
void GetPreviousOverlapResults(const unsigned int indexU, const unsigned int indexV, const unsigned int indexW, FitSegmentTensor &fitSegmentSumTensor, TransverseOverlapResultVector &transverseOverlapResultVector) const
Get track overlap results for possible connected segments.
float m_minSegmentMatchedFraction
The minimum segment matched sampling fraction to allow segment grouping.
void GetBestOverlapResult(const FitSegmentTensor &fitSegmentTensor, TransverseOverlapResult &bestTransverseOverlapResult) const
Get the best overlap result, by examining the fit segment tensor.
pandora::StatusCode GetSegmentOverlap(const FitSegment &fitSegmentU, const FitSegment &fitSegmentV, const FitSegment &fitSegmentW, const TwoDSlidingFitResult &slidingFitResultU, const TwoDSlidingFitResult &slidingFitResultV, const TwoDSlidingFitResult &slidingFitResultW, TransverseOverlapResult &transverseOverlapResult) const
Get the overlap result for three fit segments and the accompanying sliding fit results.
std::map< unsigned int, FitSegmentToOverlapResultMap > FitSegmentMatrix
TensorToolVector m_algorithmToolVector
The algorithm tool vector.
NViewTrackMatchingAlgorithm< ThreeViewMatchingControl< TransverseOverlapResult > > BaseAlgorithm
float m_pseudoChi2Cut
The pseudo chi2 cut to identify matched sampling points.
unsigned int m_minOverallMatchedPoints
The minimum number of matched segment sampling points to allow particle creation.
unsigned int m_minSegmentMatchedPoints
The minimum number of matched segment sampling points to allow segment grouping.
ThreeViewTransverseTracksAlgorithm::MatchingType::TensorType TensorType
std::vector< TensorType::ElementList::const_iterator > IteratorList
virtual bool Run(ThreeViewTransverseTracksAlgorithm *const pAlgorithm, TensorType &overlapTensor)=0
Run the algorithm tool.
AlgorithmTool class. Algorithm tools will tend to be tailored for specific parent algorithms,...
Cluster class.
Definition Cluster.h:31
std::vector< TransverseOverlapResult > TransverseOverlapResultVector
StatusCode
The StatusCode enum.