Pandora
Pandora source code navigator
Loading...
Searching...
No Matches
lar_content::ShowerRegionFeatureTool Class Referenceabstract

ShowerRegionFeatureTool to calculate variables related to the shower region. More...

#include "ConnectionPathwayFeatureTool.h"

Inheritance diagram for lar_content::ShowerRegionFeatureTool:
Collaboration diagram for lar_content::ShowerRegionFeatureTool:

Public Types

typedef std::vector< MvaFeatureTool< Ts... > * > FeatureToolVector
 
typedef std::map< std::string, MvaFeatureTool< Ts... > * > FeatureToolMap
 

Public Member Functions

 ShowerRegionFeatureTool ()
 Default constructor.
 
void Run (LArMvaHelper::MvaFeatureVector &featureVector, const pandora::Algorithm *const pAlgorithm, const pandora::ParticleFlowObject *const pShowerPfo, const pandora::CartesianVector &nuVertex3D, const ProtoShowerMatch &protoShowerMatch, const pandora::CartesianPointVector &showerStarts3D)
 
void Run (LArMvaHelper::MvaFeatureMap &featureMap, pandora::StringVector &featureOrder, const std::string &featureToolName, const pandora::Algorithm *const pAlgorithm, const pandora::ParticleFlowObject *const pShowerPfo, const pandora::CartesianVector &nuVertex3D, const ProtoShowerMatch &protoShowerMatch, const pandora::CartesianPointVector &showerStarts3D)
 
virtual void Run (MvaTypes::MvaFeatureVector &featureVector, Ts... args)=0
 Run the algorithm tool.
 
virtual void Run (MvaTypes::MvaFeatureMap &featureMap, pandora::StringVector &featureOrder, const std::string &featureToolName, Ts...)
 
const std::string & GetType () const
 Get the type.
 
const std::string & GetInstanceName () const
 Get the instance name.
 
const PandoraGetPandora () const
 Get the associated pandora instance.
 

Protected Member Functions

virtual StatusCode Initialize ()
 Perform any operations that must occur after reading settings, but before running the process.
 
virtual StatusCode Reset ()
 Perform any operations when pandora is reset, typically at the end of each event.
 
StatusCode RegisterDetails (const Pandora *const pPandora, const std::string &type, const std::string &instanceName)
 Register i) the pandora instance that will run the process and ii) the process type.
 

Protected Attributes

const Pandoram_pPandora
 The pandora object that will run the process.
 
std::string m_type
 The process type.
 
std::string m_instanceName
 The process instance name.
 

Private Member Functions

pandora::StatusCode ReadSettings (const pandora::TiXmlHandle xmlHandle)
 Read the algorithm settings.
 
void GetViewShowerRegionVariables (const pandora::Algorithm *const pAlgorithm, const pandora::ParticleFlowObject *const pShowerPfo, const pandora::CartesianVector &nuVertex3D, const ProtoShowerMatch &protoShowerMatch, const pandora::HitType hitType, const pandora::CartesianVector &showerStart3D, float &nHits, float &foundHitRatio, float &scatterAngle, float &openingAngle, float &nuVertexEnergyAsymmetry, float &nuVertexEnergyWeightedMeanRadialDistance, float &showerStartEnergyAsymmetry, float &showerStartMoliereRadius)
 Calculate the shower region variables for the input view.
 
void BuildViewShower (const pandora::ParticleFlowObject *const pShowerPfo, const TwoDSlidingFitResult &spineFit, const pandora::HitType hitType, const pandora::CartesianVector &showerStart2D, const pandora::CartesianVector &nuVertex2D, pandora::CaloHitList &postShowerHitList, pandora::CartesianPointVector &postShowerPositions)
 Collect the shower region hits in a given view.
 
void GetShowerHitVariables (const pandora::CaloHitList &spineHitList, const pandora::CaloHitList &postShowerHitList, const pandora::ParticleFlowObject *const pShowerPfo, const pandora::HitType hitType, float &nHits, float &foundHitRatio)
 Evaluate the variables associated with the shower region hit multiplicity.
 
void CalculateViewScatterAngle (const pandora::CartesianVector &nuVertex2D, const TwoDSlidingFitResult &spineFitResult, const pandora::CartesianVector &showerStart2D, const TwoDSlidingFitResult &showerFitResult, float &scatterAngle)
 Calculate the connection pathway-shower region scatter angle.
 
void CalculateViewOpeningAngle (const TwoDSlidingFitResult &showerFitResult, const pandora::CaloHitList &postShowerHitList, const pandora::CartesianVector &showerStart2D, float &openingAngle)
 Calculate the opening angle of the shower region.
 
void CalculateViewNuVertexConsistencyVariables (const TwoDSlidingFitResult &spineFitResult, const pandora::CaloHitList &postShowerHitList, const bool isDownstream, const pandora::CartesianVector &nuVertex2D, float &nuVertexEnergyAsymmetry, float &nuVertexEnergyWeightedMeanRadialDistance)
 Evaluate the neutrino vertex consistency variables.
 
void CalculateViewShowerStartConsistencyVariables (const TwoDSlidingFitResult &showerFitResult, const pandora::CaloHitList &postShowerHitList, const bool isShowerDownstream, float &showerStartEnergyAsymmetry, float &showerStartMoliereRadius)
 Evaluate the shower start consistency variables.
 

Private Attributes

float m_defaultFloat
 Default float value.
 
float m_defaultRatio
 Default float value for ratios.
 
unsigned int m_spineFitWindow
 The spine fit window.
 
float m_showerRadius
 The max. separation distance between a shower region hit and the shower core.
 
unsigned int m_showerFitWindow
 The shower fit window.
 
float m_edgeStep
 The binning of the shower boundaries.
 
float m_moliereFraction
 The energy fraction which corresponds to minShowerStartMoliereRadius.
 
float m_maxNHitsLimit
 maxNHits max. limit
 
float m_maxFoundHitRatioLimit
 maxFoundHitRatio max. limit
 
float m_maxScatterAngleLimit
 maxScatterAngle max. limit
 
float m_maxOpeningAngleLimit
 maxOpeningAngle max. limit
 
float m_maxNuVertexEnergyWeightedMeanRadialDistanceLimit
 maxNuVertexEnergyWeightedMeanRadialDistance max. limit
 
float m_minShowerStartMoliereRadiusLimit
 minShowerStartMoliereRadius max. limit
 

Detailed Description

ShowerRegionFeatureTool to calculate variables related to the shower region.

Definition at line 128 of file ConnectionPathwayFeatureTool.h.

Member Typedef Documentation

◆ FeatureToolMap

template<typename... Ts>
typedef std::map<std::string, MvaFeatureTool<Ts...> *> lar_content::MvaFeatureTool< Ts >::FeatureToolMap
inherited

Definition at line 37 of file LArMvaHelper.h.

◆ FeatureToolVector

template<typename... Ts>
typedef std::vector<MvaFeatureTool<Ts...> *> lar_content::MvaFeatureTool< Ts >::FeatureToolVector
inherited

Definition at line 36 of file LArMvaHelper.h.

Constructor & Destructor Documentation

◆ ShowerRegionFeatureTool()

lar_content::ShowerRegionFeatureTool::ShowerRegionFeatureTool ( )

Default constructor.

Definition at line 335 of file ConnectionPathwayFeatureTool.cc.

Member Function Documentation

◆ BuildViewShower()

void lar_content::ShowerRegionFeatureTool::BuildViewShower ( const pandora::ParticleFlowObject *const  pShowerPfo,
const TwoDSlidingFitResult spineFit,
const pandora::HitType  hitType,
const pandora::CartesianVector showerStart2D,
const pandora::CartesianVector nuVertex2D,
pandora::CaloHitList postShowerHitList,
pandora::CartesianPointVector postShowerPositions 
)
private

Collect the shower region hits in a given view.

Parameters
pShowerPfothe shower pfo
spineFitthe shower spine fit
hitTypethe 2D view
showerStart2Dthe 2D shower start position
nuVertex2Dthe 2D neutrino vertex position
postShowerHitListthe collected shower region hit list
postShowerPositionsthe collected shower region hit position vector

Definition at line 579 of file ConnectionPathwayFeatureTool.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ CalculateViewNuVertexConsistencyVariables()

void lar_content::ShowerRegionFeatureTool::CalculateViewNuVertexConsistencyVariables ( const TwoDSlidingFitResult spineFitResult,
const pandora::CaloHitList postShowerHitList,
const bool  isDownstream,
const pandora::CartesianVector nuVertex2D,
float &  nuVertexEnergyAsymmetry,
float &  nuVertexEnergyWeightedMeanRadialDistance 
)
private

Evaluate the neutrino vertex consistency variables.

Parameters
spineHitListthe shower spine hit list
postShowerHitListthe collected shower region hit list
isDownstreamwhether the shower direction is downstream (in Z) of the neutrino vertex
nuVertex2Dthe 2D neutrino vertex
nuVertexEnergyAsymmetrythe output neutrino vertex energy asymmetry
nuVertexEnergyWeightedMeanRadialDistancethe output neutrino vertex energy weighted mean radial distance

Definition at line 725 of file ConnectionPathwayFeatureTool.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ CalculateViewOpeningAngle()

void lar_content::ShowerRegionFeatureTool::CalculateViewOpeningAngle ( const TwoDSlidingFitResult showerFitResult,
const pandora::CaloHitList postShowerHitList,
const pandora::CartesianVector showerStart2D,
float &  openingAngle 
)
private

Calculate the opening angle of the shower region.

Parameters
showerFitResultthe shower region fit
postShowerHitListthe collected shower region hit list
showerStart2Dthe 2D shower start position
openingAnglethe output opening angle

Definition at line 661 of file ConnectionPathwayFeatureTool.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ CalculateViewScatterAngle()

void lar_content::ShowerRegionFeatureTool::CalculateViewScatterAngle ( const pandora::CartesianVector nuVertex2D,
const TwoDSlidingFitResult spineFitResult,
const pandora::CartesianVector showerStart2D,
const TwoDSlidingFitResult showerFitResult,
float &  scatterAngle 
)
private

Calculate the connection pathway-shower region scatter angle.

Parameters
nuVertex2Dthe 2D neutrino vertex
spineFitResultthe shower spine fit
showerStart2Dthe 2D shower start position
showerFitResultthe shower region fit
scatterAnglethe output scatter angle

Definition at line 644 of file ConnectionPathwayFeatureTool.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ CalculateViewShowerStartConsistencyVariables()

void lar_content::ShowerRegionFeatureTool::CalculateViewShowerStartConsistencyVariables ( const TwoDSlidingFitResult showerFitResult,
const pandora::CaloHitList postShowerHitList,
const bool  isShowerDownstream,
float &  showerStartEnergyAsymmetry,
float &  showerStartMoliereRadius 
)
private

Evaluate the shower start consistency variables.

Parameters
showerFitResultthe shower fit result
postShowerHitListthe collected shower region hit list
isShowerDownstreamwhether the shower direction is downstream (in Z) of the neutrino vertex
showerStartEnergyAsymmetrythe output shower start energy asymmetry
showerStartMoliereRadiusthe output shower start moliere radius

Definition at line 768 of file ConnectionPathwayFeatureTool.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetInstanceName()

const std::string & pandora::Process::GetInstanceName ( ) const
inlineinherited

Get the instance name.

Returns
The instance name

Definition at line 109 of file Process.h.

◆ GetPandora()

const Pandora & pandora::Process::GetPandora ( ) const
inlineinherited

Get the associated pandora instance.

Returns
the associated pandora instance

Definition at line 116 of file Process.h.

◆ GetShowerHitVariables()

void lar_content::ShowerRegionFeatureTool::GetShowerHitVariables ( const pandora::CaloHitList spineHitList,
const pandora::CaloHitList postShowerHitList,
const pandora::ParticleFlowObject *const  pShowerPfo,
const pandora::HitType  hitType,
float &  nHits,
float &  foundHitRatio 
)
private

Evaluate the variables associated with the shower region hit multiplicity.

Parameters
spineHitListthe shower spine hit list
postShowerHitListthe collected shower region hit list
pShowerPfothe shower pfo
hitTypethe 2D view
nHitsthe output number of shower region hits
foundHitRatiothe output found hit ratio

Definition at line 624 of file ConnectionPathwayFeatureTool.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetType()

const std::string & pandora::Process::GetType ( ) const
inlineinherited

Get the type.

Returns
The type

Definition at line 102 of file Process.h.

◆ GetViewShowerRegionVariables()

void lar_content::ShowerRegionFeatureTool::GetViewShowerRegionVariables ( const pandora::Algorithm *const  pAlgorithm,
const pandora::ParticleFlowObject *const  pShowerPfo,
const pandora::CartesianVector nuVertex3D,
const ProtoShowerMatch protoShowerMatch,
const pandora::HitType  hitType,
const pandora::CartesianVector showerStart3D,
float &  nHits,
float &  foundHitRatio,
float &  scatterAngle,
float &  openingAngle,
float &  nuVertexEnergyAsymmetry,
float &  nuVertexEnergyWeightedMeanRadialDistance,
float &  showerStartEnergyAsymmetry,
float &  showerStartMoliereRadius 
)
private

Calculate the shower region variables for the input view.

Parameters
pAlgorithmthe algorithm
pShowerPfothe shower pfo
nuVertex3Dthe 3D neutrino vertex
protoShowerMatchthe ProtoShower match
hitTypethe 2D view
showerStart3Dthe 3D shower start position
nHitsthe output number of shower region hits
foundHitRatiothe output found hit ratio
scatterAnglethe output scatter angle
openingAnglethe output opening angle
nuVertexEnergyAsymmetrythe output neutrino vertex energy asymmetry
nuVertexEnergyWeightedMeanRadialDistancethe output neutrino vertex energy weighted mean radial distance
showerStartEnergyAsymmetrythe output shower start energy asymmetry
showerStartMoliereRadiusthe output shower start moliere radius

Definition at line 502 of file ConnectionPathwayFeatureTool.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Initialize()

StatusCode pandora::Process::Initialize ( )
inlineprotectedvirtualinherited

Perform any operations that must occur after reading settings, but before running the process.

Reimplemented in lar_content::BdtBeamParticleIdTool, lar_content::BeamParticleIdTool, lar_content::CosmicRayTaggingTool, lar_content::EventReadingAlgorithm, lar_content::EventWritingAlgorithm, lar_content::LArPseudoLayerPlugin, lar_content::LArRotationalTransformationPlugin, EventReadingAlgorithm, and EventWritingAlgorithm.

Definition at line 126 of file Process.h.

Here is the caller graph for this function:

◆ ReadSettings()

StatusCode lar_content::ShowerRegionFeatureTool::ReadSettings ( const pandora::TiXmlHandle  xmlHandle)
privatevirtual

Read the algorithm settings.

Parameters
xmlHandlethe relevant xml handle

Implements pandora::Process.

Definition at line 830 of file ConnectionPathwayFeatureTool.cc.

Here is the call graph for this function:

◆ RegisterDetails()

StatusCode pandora::Process::RegisterDetails ( const Pandora *const  pPandora,
const std::string &  type,
const std::string &  instanceName 
)
inlineprotectedinherited

Register i) the pandora instance that will run the process and ii) the process type.

Parameters
pPandoraaddress of the pandora object that will run the process
typethe process type
instanceNamethe process instance name

Definition at line 146 of file Process.h.

Here is the caller graph for this function:

◆ Reset()

StatusCode pandora::Process::Reset ( )
inlineprotectedvirtualinherited

Perform any operations when pandora is reset, typically at the end of each event.

Reimplemented in lar_content::MasterAlgorithm, lar_content::PostProcessingAlgorithm, and lar_content::PreProcessingAlgorithm.

Definition at line 133 of file Process.h.

Here is the caller graph for this function:

◆ Run() [1/4]

void lar_content::ShowerRegionFeatureTool::Run ( LArMvaHelper::MvaFeatureMap featureMap,
pandora::StringVector featureOrder,
const std::string &  featureToolName,
const pandora::Algorithm *const  pAlgorithm,
const pandora::ParticleFlowObject *const  pShowerPfo,
const pandora::CartesianVector nuVertex3D,
const ProtoShowerMatch protoShowerMatch,
const pandora::CartesianPointVector showerStarts3D 
)

Definition at line 420 of file ConnectionPathwayFeatureTool.cc.

Here is the call graph for this function:

◆ Run() [2/4]

void lar_content::ShowerRegionFeatureTool::Run ( LArMvaHelper::MvaFeatureVector featureVector,
const pandora::Algorithm *const  pAlgorithm,
const pandora::ParticleFlowObject *const  pShowerPfo,
const pandora::CartesianVector nuVertex3D,
const ProtoShowerMatch protoShowerMatch,
const pandora::CartesianPointVector showerStarts3D 
)

Definition at line 354 of file ConnectionPathwayFeatureTool.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Run() [3/4]

template<typename... Ts>
virtual void lar_content::MvaFeatureTool< Ts >::Run ( MvaTypes::MvaFeatureMap featureMap,
pandora::StringVector featureOrder,
const std::string &  featureToolName,
Ts...   
)
inlinevirtualinherited

Definition at line 51 of file LArMvaHelper.h.

◆ Run() [4/4]

template<typename... Ts>
virtual void lar_content::MvaFeatureTool< Ts >::Run ( MvaTypes::MvaFeatureVector featureVector,
Ts...  args 
)
pure virtualinherited

Run the algorithm tool.

Parameters
featureVectorthe vector of features to append
argsarguments to pass to the tool

Member Data Documentation

◆ m_defaultFloat

float lar_content::ShowerRegionFeatureTool::m_defaultFloat
private

Default float value.

Definition at line 248 of file ConnectionPathwayFeatureTool.h.

◆ m_defaultRatio

float lar_content::ShowerRegionFeatureTool::m_defaultRatio
private

Default float value for ratios.

Definition at line 249 of file ConnectionPathwayFeatureTool.h.

◆ m_edgeStep

float lar_content::ShowerRegionFeatureTool::m_edgeStep
private

The binning of the shower boundaries.

Definition at line 253 of file ConnectionPathwayFeatureTool.h.

◆ m_instanceName

std::string pandora::Process::m_instanceName
protectedinherited

The process instance name.

Definition at line 89 of file Process.h.

◆ m_maxFoundHitRatioLimit

float lar_content::ShowerRegionFeatureTool::m_maxFoundHitRatioLimit
private

maxFoundHitRatio max. limit

Definition at line 256 of file ConnectionPathwayFeatureTool.h.

◆ m_maxNHitsLimit

float lar_content::ShowerRegionFeatureTool::m_maxNHitsLimit
private

maxNHits max. limit

Definition at line 255 of file ConnectionPathwayFeatureTool.h.

◆ m_maxNuVertexEnergyWeightedMeanRadialDistanceLimit

float lar_content::ShowerRegionFeatureTool::m_maxNuVertexEnergyWeightedMeanRadialDistanceLimit
private

maxNuVertexEnergyWeightedMeanRadialDistance max. limit

Definition at line 259 of file ConnectionPathwayFeatureTool.h.

◆ m_maxOpeningAngleLimit

float lar_content::ShowerRegionFeatureTool::m_maxOpeningAngleLimit
private

maxOpeningAngle max. limit

Definition at line 258 of file ConnectionPathwayFeatureTool.h.

◆ m_maxScatterAngleLimit

float lar_content::ShowerRegionFeatureTool::m_maxScatterAngleLimit
private

maxScatterAngle max. limit

Definition at line 257 of file ConnectionPathwayFeatureTool.h.

◆ m_minShowerStartMoliereRadiusLimit

float lar_content::ShowerRegionFeatureTool::m_minShowerStartMoliereRadiusLimit
private

minShowerStartMoliereRadius max. limit

Definition at line 260 of file ConnectionPathwayFeatureTool.h.

◆ m_moliereFraction

float lar_content::ShowerRegionFeatureTool::m_moliereFraction
private

The energy fraction which corresponds to minShowerStartMoliereRadius.

Definition at line 254 of file ConnectionPathwayFeatureTool.h.

◆ m_pPandora

const Pandora* pandora::Process::m_pPandora
protectedinherited

The pandora object that will run the process.

Definition at line 87 of file Process.h.

◆ m_showerFitWindow

unsigned int lar_content::ShowerRegionFeatureTool::m_showerFitWindow
private

The shower fit window.

Definition at line 252 of file ConnectionPathwayFeatureTool.h.

◆ m_showerRadius

float lar_content::ShowerRegionFeatureTool::m_showerRadius
private

The max. separation distance between a shower region hit and the shower core.

Definition at line 251 of file ConnectionPathwayFeatureTool.h.

◆ m_spineFitWindow

unsigned int lar_content::ShowerRegionFeatureTool::m_spineFitWindow
private

The spine fit window.

Definition at line 250 of file ConnectionPathwayFeatureTool.h.

◆ m_type

std::string pandora::Process::m_type
protectedinherited

The process type.

Definition at line 88 of file Process.h.


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