LArSoft
v06_85_00
Liquid Argon Software toolkit - http://larsoft.org/
|
ThreeDHitCreationAlgorithm::Algorithm class. More...
#include "ThreeDHitCreationAlgorithm.h"
Classes | |
class | ProtoHit |
Proto hits are temporary constructs to be used during iterative 3D hit procedure. More... | |
class | TrajectorySample |
Trajectory samples record the results of sampling a particles in a particular view. More... | |
Public Types | |
typedef std::vector< TrajectorySample > | TrajectorySampleVector |
typedef std::vector< ProtoHit > | ProtoHitVector |
Public Member Functions | |
ThreeDHitCreationAlgorithm () | |
Default constructor. More... | |
void | FilterCaloHitsByType (const pandora::CaloHitVector &inputCaloHitVector, const pandora::HitType hitType, pandora::CaloHitVector &outputCaloHitVector) const |
Get the subset of a provided calo hit vector corresponding to a specified hit type. More... | |
Private Types | |
typedef std::vector< HitCreationBaseTool * > | HitCreationToolVector |
Private Member Functions | |
pandora::StatusCode | Run () |
void | SeparateTwoDHits (const pandora::ParticleFlowObject *const pPfo, const ProtoHitVector &protoHitVector, pandora::CaloHitVector &remainingHitVector) const |
Get the list of 2D calo hits in a pfo for which 3D hits have and have not been created. More... | |
void | IterativeTreatment (ProtoHitVector &protoHitVector) const |
Improve initial 3D hits by fitting proto hits and iteratively creating consisted 3D hit trajectory. More... | |
void | ExtractResults (const ProtoHitVector &protoHitVector, double &chi2, pandora::CartesianPointVector &pointVector) const |
Extract key results from a provided proto hit vector. More... | |
double | GetChi2WrtFit (const ThreeDSlidingFitResult &slidingFitResult, const ProtoHitVector &protoHitVector) const |
Receive a chi2 value indicating consistency of a list of proto hits with a provided 3D sliding fit trajectory. More... | |
double | GetHitMovementChi2 (const ProtoHitVector &protoHitVector) const |
Receive a chi2 value indicating consistency of a list of proto hits with the original, input hit positions. More... | |
void | RefineHitPositions (const ThreeDSlidingFitResult &slidingFitResult, ProtoHitVector &protoHitVector) const |
Refine the 3D hit positions (and chi2) for a list of proto hits, in accordance with a provided 3D sliding fit trajectory. More... | |
void | CreateThreeDHits (const ProtoHitVector &protoHitVector, pandora::CaloHitList &newThreeDHits) const |
Create new three dimensional hits from two dimensional hits. More... | |
void | CreateThreeDHit (const ProtoHit &protoHit, const pandora::CaloHit *&pCaloHit3D) const |
Create a new three dimensional hit from a two dimensional hit. More... | |
bool | CheckThreeDHit (const ProtoHit &protoHit) const |
Check that a new three dimensional position is not unphysical. More... | |
void | AddThreeDHitsToPfo (const pandora::ParticleFlowObject *const pPfo, const pandora::CaloHitList &caloHitList) const |
Add a specified list of three dimensional hits to a cluster in a pfo, creating the new cluster if required. More... | |
pandora::StatusCode | ReadSettings (const pandora::TiXmlHandle xmlHandle) |
Private Attributes | |
HitCreationToolVector | m_algorithmToolVector |
The algorithm tool vector. More... | |
std::string | m_inputPfoListName |
The name of the input pfo list. More... | |
std::string | m_outputCaloHitListName |
The name of the output calo hit list. More... | |
std::string | m_outputClusterListName |
The name of the output cluster list. More... | |
bool | m_iterateTrackHits |
Whether to enable iterative improvement of 3D hits for track trajectories. More... | |
bool | m_iterateShowerHits |
Whether to enable iterative improvement of 3D hits for showers. More... | |
unsigned int | m_slidingFitHalfWindow |
The sliding linear fit half window. More... | |
unsigned int | m_nHitRefinementIterations |
The maximum number of hit refinement iterations. More... | |
double | m_sigma3DFitMultiplier |
Multiplicative factor: sigmaUVW (same as sigmaHit and sigma2DFit) to sigma3DFit. More... | |
double | m_iterationMaxChi2Ratio |
Max ratio between current and previous chi2 values to cease iterations. More... | |
ThreeDHitCreationAlgorithm::Algorithm class.
Definition at line 27 of file ThreeDHitCreationAlgorithm.h.
|
private |
Definition at line 271 of file ThreeDHitCreationAlgorithm.h.
typedef std::vector<ProtoHit> lar_content::ThreeDHitCreationAlgorithm::ProtoHitVector |
Definition at line 163 of file ThreeDHitCreationAlgorithm.h.
typedef std::vector<TrajectorySample> lar_content::ThreeDHitCreationAlgorithm::TrajectorySampleVector |
Definition at line 68 of file ThreeDHitCreationAlgorithm.h.
lar_content::ThreeDHitCreationAlgorithm::ThreeDHitCreationAlgorithm | ( | ) |
Default constructor.
Definition at line 27 of file ThreeDHitCreationAlgorithm.cc.
|
private |
Add a specified list of three dimensional hits to a cluster in a pfo, creating the new cluster if required.
pPfo | the address of the pfo |
caloHitList | the list of three dimensional hits |
Definition at line 372 of file ThreeDHitCreationAlgorithm.cc.
References lar_content::LArPfoHelper::GetThreeDClusterList(), and m_outputClusterListName.
Referenced by Run().
|
private |
Check that a new three dimensional position is not unphysical.
protoHit | the proto hit |
boolean |
Definition at line 354 of file ThreeDHitCreationAlgorithm.cc.
References lar_content::ThreeDHitCreationAlgorithm::ProtoHit::GetPosition3D().
Referenced by CreateThreeDHit().
|
private |
Create a new three dimensional hit from a two dimensional hit.
protoHit | the proto hit containing all required information |
pCaloHit3D | to receive the address of the new three dimensional calo hit |
Definition at line 319 of file ThreeDHitCreationAlgorithm.cc.
References CheckThreeDHit(), lar_content::ThreeDHitCreationAlgorithm::ProtoHit::GetParentCaloHit2D(), and lar_content::ThreeDHitCreationAlgorithm::ProtoHit::GetPosition3D().
Referenced by CreateThreeDHits().
|
private |
Create new three dimensional hits from two dimensional hits.
protoHitVector | the input proto hit vector |
newThreeDHits | to receive the addresses of the new three dimensional calo hits |
Definition at line 303 of file ThreeDHitCreationAlgorithm.cc.
References CreateThreeDHit().
Referenced by Run().
|
private |
Extract key results from a provided proto hit vector.
protoHitVector | the proto hit vector |
chi2 | to receive the sum of the proto hit chi2 values |
pointVector | to receive a vector of proto hit 3D positions |
Definition at line 178 of file ThreeDHitCreationAlgorithm.cc.
Referenced by IterativeTreatment().
void lar_content::ThreeDHitCreationAlgorithm::FilterCaloHitsByType | ( | const pandora::CaloHitVector & | inputCaloHitVector, |
const pandora::HitType | hitType, | ||
pandora::CaloHitVector & | outputCaloHitVector | ||
) | const |
Get the subset of a provided calo hit vector corresponding to a specified hit type.
inputCaloHitVector | the input calo hit vector |
hitType | the hit type to filter upon |
outputCaloHitVector | to receive the output calo hit vector |
Definition at line 39 of file ThreeDHitCreationAlgorithm.cc.
Referenced by lar_content::ShowerHitsBaseTool::Run().
|
private |
Receive a chi2 value indicating consistency of a list of proto hits with a provided 3D sliding fit trajectory.
slidingFitResult | the 3D sliding fit result |
protoHitVector | the proto hit vector |
Definition at line 192 of file ThreeDHitCreationAlgorithm.cc.
References f, lar_content::ThreeDSlidingFitResult::GetGlobalFitPosition(), lar_content::ThreeDSlidingFitResult::GetLongitudinalDisplacement(), lar_content::LArGeometryHelper::GetSigmaUVW(), and m_sigma3DFitMultiplier.
Referenced by IterativeTreatment().
|
private |
Receive a chi2 value indicating consistency of a list of proto hits with the original, input hit positions.
protoHitVector | the proto hit vector |
Definition at line 224 of file ThreeDHitCreationAlgorithm.cc.
References lar_content::LArGeometryHelper::GetSigmaUVW(), and lar_content::LArGeometryHelper::ProjectPosition().
|
private |
Improve initial 3D hits by fitting proto hits and iteratively creating consisted 3D hit trajectory.
protoHitVector | the vector of proto hits, describing current state of 3D hit construction |
Definition at line 136 of file ThreeDHitCreationAlgorithm.cc.
References ExtractResults(), GetChi2WrtFit(), lar_content::LArGeometryHelper::GetWireZPitch(), m_iterationMaxChi2Ratio, m_nHitRefinementIterations, m_slidingFitHalfWindow, and RefineHitPositions().
Referenced by Run().
|
private |
Definition at line 443 of file ThreeDHitCreationAlgorithm.cc.
References m_algorithmToolVector, m_inputPfoListName, m_iterateShowerHits, m_iterateTrackHits, m_iterationMaxChi2Ratio, m_nHitRefinementIterations, m_outputCaloHitListName, m_outputClusterListName, m_sigma3DFitMultiplier, and m_slidingFitHalfWindow.
|
private |
Refine the 3D hit positions (and chi2) for a list of proto hits, in accordance with a provided 3D sliding fit trajectory.
slidingFitResult | the 3D sliding fit result |
protoHitVector | the proto hit vector, non const as proto hit properties will be updated |
Definition at line 245 of file ThreeDHitCreationAlgorithm.cc.
References f, lar_content::ThreeDSlidingFitResult::GetGlobalFitPosition(), lar_content::ThreeDSlidingFitResult::GetLongitudinalDisplacement(), lar_content::LArGeometryHelper::GetSigmaUVW(), m_sigma3DFitMultiplier, max, and w.
Referenced by IterativeTreatment().
|
private |
Definition at line 50 of file ThreeDHitCreationAlgorithm.cc.
References AddThreeDHitsToPfo(), CreateThreeDHits(), lar_content::LArPfoHelper::IsShower(), lar_content::LArPfoHelper::IsTrack(), IterativeTreatment(), m_algorithmToolVector, m_inputPfoListName, m_iterateShowerHits, m_iterateTrackHits, m_outputCaloHitListName, SeparateTwoDHits(), and lar_content::LArPfoHelper::SortByNHits().
|
private |
Get the list of 2D calo hits in a pfo for which 3D hits have and have not been created.
pPfo | the address of the pfo |
protoHitVector | the vector of proto hits, describing current state of 3D hit construction |
remainingHitVector | to receive the vector of 2D calo hits for which 3D hits have not been created |
Definition at line 104 of file ThreeDHitCreationAlgorithm.cc.
References lar_content::LArClusterHelper::GetClusterHitType(), lar_content::LArPfoHelper::GetTwoDClusterList(), and lar_content::LArClusterHelper::SortHitsByPosition().
Referenced by Run().
|
private |
The algorithm tool vector.
Definition at line 272 of file ThreeDHitCreationAlgorithm.h.
Referenced by ReadSettings(), and Run().
|
private |
The name of the input pfo list.
Definition at line 274 of file ThreeDHitCreationAlgorithm.h.
Referenced by ReadSettings(), and Run().
|
private |
Whether to enable iterative improvement of 3D hits for showers.
Definition at line 279 of file ThreeDHitCreationAlgorithm.h.
Referenced by ReadSettings(), and Run().
|
private |
Whether to enable iterative improvement of 3D hits for track trajectories.
Definition at line 278 of file ThreeDHitCreationAlgorithm.h.
Referenced by ReadSettings(), and Run().
|
private |
Max ratio between current and previous chi2 values to cease iterations.
Definition at line 283 of file ThreeDHitCreationAlgorithm.h.
Referenced by IterativeTreatment(), and ReadSettings().
|
private |
The maximum number of hit refinement iterations.
Definition at line 281 of file ThreeDHitCreationAlgorithm.h.
Referenced by IterativeTreatment(), and ReadSettings().
|
private |
The name of the output calo hit list.
Definition at line 275 of file ThreeDHitCreationAlgorithm.h.
Referenced by ReadSettings(), and Run().
|
private |
The name of the output cluster list.
Definition at line 276 of file ThreeDHitCreationAlgorithm.h.
Referenced by AddThreeDHitsToPfo(), and ReadSettings().
|
private |
Multiplicative factor: sigmaUVW (same as sigmaHit and sigma2DFit) to sigma3DFit.
Definition at line 282 of file ThreeDHitCreationAlgorithm.h.
Referenced by GetChi2WrtFit(), ReadSettings(), and RefineHitPositions().
|
private |
The sliding linear fit half window.
Definition at line 280 of file ThreeDHitCreationAlgorithm.h.
Referenced by IterativeTreatment(), and ReadSettings().