Private Member Functions | List of all members
lar_content::MultiValuedTransverseTrackHitsTool Class Reference

MultiValuedTransverseTrackHitsTool class. More...

#include <MultiValuedTransverseTrackHitsTool.h>

Inheritance diagram for lar_content::MultiValuedTransverseTrackHitsTool:
lar_content::TransverseTrackHitsBaseTool lar_content::TrackHitsBaseTool lar_content::HitCreationBaseTool

Private Member Functions

void GetTransverseTrackHit3D (const MatchedSlidingFitMap &matchedSlidingFitMap, ProtoHit &protoHit) const
 Get the three dimensional position using a provided two dimensional calo hit and sliding linear fits in the other two views. More...
 

Additional Inherited Members

- Public Types inherited from lar_content::HitCreationBaseTool
typedef ThreeDHitCreationAlgorithm::ProtoHit ProtoHit
 
typedef ThreeDHitCreationAlgorithm::ProtoHitVector ProtoHitVector
 
typedef ThreeDHitCreationAlgorithm::TrajectorySample TrajectorySample
 
- Public Member Functions inherited from lar_content::TrackHitsBaseTool
 TrackHitsBaseTool ()
 Default constructor. More...
 
virtual void Run (ThreeDHitCreationAlgorithm *const pAlgorithm, const pandora::ParticleFlowObject *const pPfo, const pandora::CaloHitVector &inputTwoDHits, ProtoHitVector &protoHitVector)
 Run the algorithm tool. More...
 
- Public Member Functions inherited from lar_content::HitCreationBaseTool
 HitCreationBaseTool ()
 Default constructor. More...
 
virtual ~HitCreationBaseTool ()
 Destructor. More...
 
- Protected Types inherited from lar_content::TrackHitsBaseTool
typedef std::map< pandora::HitType, TwoDSlidingFitResultMatchedSlidingFitMap
 
- Protected Member Functions inherited from lar_content::TransverseTrackHitsBaseTool
virtual void GetTrackHits3D (const pandora::CaloHitVector &inputTwoDHits, const MatchedSlidingFitMap &matchedSlidingFitMap, ProtoHitVector &protoHitVector) const
 Calculate 3D hits from an input list of 2D hits. More...
 
virtual void AddTransverseChi2 (const MatchedSlidingFitMap &matchedSlidingFitMap, ProtoHit &protoHit) const
 Calculate an additional contribution to the chi-squared based on the steepness of the track. More...
 
- Protected Member Functions inherited from lar_content::TrackHitsBaseTool
virtual void BuildSlidingFitMap (const pandora::ParticleFlowObject *const pPfo, MatchedSlidingFitMap &matchedSlidingFitMap) const
 Calculate sliding fit results for clusters from each view. More...
 
virtual pandora::StatusCode ReadSettings (const pandora::TiXmlHandle xmlHandle)
 
- Protected Member Functions inherited from lar_content::HitCreationBaseTool
virtual void GetBestPosition3D (const pandora::HitType hitType1, const pandora::HitType hitType2, const pandora::CartesianPointVector &fitPositionList1, const pandora::CartesianPointVector &fitPositionList2, ProtoHit &protoHit) const
 Get the three dimensional position using a provided two dimensional calo hit and candidate fit positions from the other two views. More...
 
virtual void GetBestPosition3D (const pandora::HitType hitType1, const pandora::HitType hitType2, const pandora::CartesianVector &fitPosition1, const pandora::CartesianVector &fitPosition2, ProtoHit &protoHit) const
 Get the three dimensional position using a provided two dimensional calo hit and candidate fit positions from the other two views. More...
 
virtual void GetBestPosition3D (const pandora::HitType hitType, const pandora::CartesianVector &fitPosition, ProtoHit &protoHit) const
 Get the three dimensional position using a provided two dimensional calo hit and a candidate fit position from another view. More...
 
- Protected Attributes inherited from lar_content::TrackHitsBaseTool
unsigned int m_minViews
 The minimum number of views required for building hits. More...
 
unsigned int m_slidingFitWindow
 The layer window for the sliding linear fits. More...
 
- Protected Attributes inherited from lar_content::HitCreationBaseTool
double m_sigmaX2
 The sigmaX squared value, for calculation of chi2 deltaX term. More...
 
double m_chiSquaredCut
 The chi squared cut (accept only values below the cut value) More...
 

Detailed Description

MultiValuedTransverseTrackHitsTool class.

Definition at line 19 of file MultiValuedTransverseTrackHitsTool.h.

Member Function Documentation

void lar_content::MultiValuedTransverseTrackHitsTool::GetTransverseTrackHit3D ( const MatchedSlidingFitMap matchedSlidingFitMap,
ProtoHit protoHit 
) const
privatevirtual

Get the three dimensional position using a provided two dimensional calo hit and sliding linear fits in the other two views.

Parameters
matchedSlidingFitMapmap of sliding fit results from each view
protoHitto receive the populated proto hit

Implements lar_content::TransverseTrackHitsBaseTool.

Definition at line 18 of file MultiValuedTransverseTrackHitsTool.cc.

19 {
20  const CaloHit *const pCaloHit2D(protoHit.GetParentCaloHit2D());
21  const HitType hitType(pCaloHit2D->GetHitType());
22  const HitType hitType1((TPC_VIEW_U == hitType) ? TPC_VIEW_V : (TPC_VIEW_V == hitType) ? TPC_VIEW_W : TPC_VIEW_U);
23  const HitType hitType2((TPC_VIEW_U == hitType) ? TPC_VIEW_W : (TPC_VIEW_V == hitType) ? TPC_VIEW_U : TPC_VIEW_V);
24 
25  CartesianPointVector fitPositionList1, fitPositionList2;
26 
27  MatchedSlidingFitMap::const_iterator iter1 = matchedSlidingFitMap.find(hitType1);
28 
29  if (matchedSlidingFitMap.end() != iter1)
30  {
31  const TwoDSlidingFitResult &fitResult1 = iter1->second;
32  PANDORA_THROW_RESULT_IF_AND_IF(STATUS_CODE_SUCCESS, STATUS_CODE_NOT_FOUND, !=,
33  fitResult1.GetGlobalFitPositionListAtX(pCaloHit2D->GetPositionVector().GetX(), fitPositionList1));
34  }
35 
36  MatchedSlidingFitMap::const_iterator iter2 = matchedSlidingFitMap.find(hitType2);
37 
38  if (matchedSlidingFitMap.end() != iter2)
39  {
40  const TwoDSlidingFitResult &fitResult2 = iter2->second;
41  PANDORA_THROW_RESULT_IF_AND_IF(STATUS_CODE_SUCCESS, STATUS_CODE_NOT_FOUND, !=,
42  fitResult2.GetGlobalFitPositionListAtX(pCaloHit2D->GetPositionVector().GetX(), fitPositionList2));
43  }
44 
45  unsigned int nViews(1);
46  if (fitPositionList1.size() > 0)
47  ++nViews;
48  if (fitPositionList2.size() > 0)
49  ++nViews;
50 
51  if (nViews < m_minViews)
52  throw StatusCodeException(STATUS_CODE_NOT_FOUND);
53 
54  if (nViews <= 2)
55  throw StatusCodeException(STATUS_CODE_INVALID_PARAMETER);
56 
57  this->GetBestPosition3D(hitType1, hitType2, fitPositionList1, fitPositionList2, protoHit);
58 }
enum cvn::HType HitType
intermediate_table::const_iterator const_iterator
virtual void GetBestPosition3D(const pandora::HitType hitType1, const pandora::HitType hitType2, const pandora::CartesianPointVector &fitPositionList1, const pandora::CartesianPointVector &fitPositionList2, ProtoHit &protoHit) const
Get the three dimensional position using a provided two dimensional calo hit and candidate fit positi...
unsigned int m_minViews
The minimum number of views required for building hits.

The documentation for this class was generated from the following files: