Pandora
Pandora source code navigator
Loading...
Searching...
No Matches
lar_content::TestBeamHierarchyEventValidationAlgorithm Class Reference

TestBeamHierarchyEventValidationAlgorithm class. More...

#include "TestBeamHierarchyEventValidationAlgorithm.h"

Inheritance diagram for lar_content::TestBeamHierarchyEventValidationAlgorithm:
Collaboration diagram for lar_content::TestBeamHierarchyEventValidationAlgorithm:

Public Member Functions

 TestBeamHierarchyEventValidationAlgorithm ()
 Default constructor.
 
 ~TestBeamHierarchyEventValidationAlgorithm ()
 Destructor.
 
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

void InterpretMatching (const ValidationInfo &validationInfo, LArMCParticleHelper::MCParticleToPfoHitSharingMap &interpretedMCToPfoHitSharingMap) const
 Apply an interpretative matching procedure to the comprehensive matches in the provided validation info object.
 
bool GetStrongestPfoMatch (const ValidationInfo &validationInfo, const pandora::MCParticleVector &mcPrimaryVector, pandora::PfoSet &usedPfos, LArMCParticleHelper::MCParticleToPfoHitSharingMap &interpretedMCToPfoHitSharingMap) const
 Get the strongest pfo match (most matched hits) between an available mc primary and an available pfo.
 
void GetRemainingPfoMatches (const ValidationInfo &validationInfo, const pandora::MCParticleVector &mcPrimaryVector, const pandora::PfoSet &usedPfos, LArMCParticleHelper::MCParticleToPfoHitSharingMap &interpretedMCToPfoHitSharingMap) const
 Get the best matches for any pfos left-over after the strong matching procedure.
 
bool IsGoodMatch (const pandora::CaloHitList &trueHits, const pandora::CaloHitList &recoHits, const pandora::CaloHitList &sharedHits) const
 Whether a provided mc primary and pfo are deemed to be a good match.
 
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

LArMCParticleHelper::PrimaryParameters m_primaryParameters
 The mc particle primary selection parameters.
 
int m_fileIdentifier
 The input file identifier.
 
int m_eventNumber
 The event number.
 
std::string m_treeName
 Name of output tree.
 
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 Types

typedef std::unordered_map< const pandora::ParticleFlowObject *, unsigned int > PfoToIdMap
 
typedef std::vector< pandora::HitTypeHitTypeVector
 

Private Member Functions

void FillValidationInfo (const pandora::MCParticleList *const pMCParticleList, const pandora::CaloHitList *const pCaloHitList, const pandora::PfoList *const pPfoList, ValidationInfo &validationInfo) const
 Fill the validation info containers.
 
void ProcessOutput (const ValidationInfo &validationInfo, const bool useInterpretedMatching, const bool printToScreen, const bool fillTree) const
 Print matching information in a provided validation info object, and write information to tree if configured to do so.
 
pandora::StatusCode ReadSettings (const pandora::TiXmlHandle xmlHandle)
 Read the algorithm settings.
 
pandora::StatusCode Run ()
 Run the algorithm.
 
void PrintAllMatches (const ValidationInfo &validationInfo) const
 Print all/raw matching information to screen.
 
void PrintInterpretedMatches (const ValidationInfo &validationInfo) const
 Print interpreted matching information to screen.
 
void WriteInterpretedMatches (const ValidationInfo &validationInfo) const
 Write interpreted matching information to tree.
 

Private Attributes

std::string m_caloHitListName
 Name of input calo hit list.
 
std::string m_mcParticleListName
 Name of input MC particle list.
 
std::string m_pfoListName
 Name of input Pfo list.
 
bool m_printAllToScreen
 Whether to print all/raw matching details to screen.
 
bool m_printMatchingToScreen
 Whether to print matching output to screen.
 
bool m_writeToTree
 Whether to write all/raw matching details to tree.
 
bool m_useSmallPrimaries
 Whether to consider matches to mc primaries with fewer than m_matchingMinPrimaryHits.
 
unsigned int m_matchingMinSharedHits
 The minimum number of shared hits used in matching scheme.
 
float m_matchingMinCompleteness
 The minimum particle completeness to declare a match.
 
float m_matchingMinPurity
 The minimum particle purity to declare a match.
 
std::string m_fileName
 Name of output file.
 

Detailed Description

Member Typedef Documentation

◆ HitTypeVector

◆ PfoToIdMap

Constructor & Destructor Documentation

◆ TestBeamHierarchyEventValidationAlgorithm()

lar_content::TestBeamHierarchyEventValidationAlgorithm::TestBeamHierarchyEventValidationAlgorithm ( )

Default constructor.

Definition at line 24 of file TestBeamHierarchyEventValidationAlgorithm.cc.

◆ ~TestBeamHierarchyEventValidationAlgorithm()

lar_content::TestBeamHierarchyEventValidationAlgorithm::~TestBeamHierarchyEventValidationAlgorithm ( )

Destructor.

Definition at line 30 of file TestBeamHierarchyEventValidationAlgorithm.cc.

Member Function Documentation

◆ FillValidationInfo()

void lar_content::TestBeamHierarchyEventValidationAlgorithm::FillValidationInfo ( const pandora::MCParticleList *const  pMCParticleList,
const pandora::CaloHitList *const  pCaloHitList,
const pandora::PfoList *const  pPfoList,
ValidationInfo validationInfo 
) const
privatevirtual

Fill the validation info containers.

Parameters
pMCParticleListthe address of the mc particle list
pCaloHitListthe address of the calo hit list
pPfoListthe address of the pfo list
validationInfoto receive the validation info

Implements lar_content::EventValidationBaseAlgorithm.

Definition at line 36 of file TestBeamHierarchyEventValidationAlgorithm.cc.

Here is the call 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.

◆ GetRemainingPfoMatches()

void lar_content::EventValidationBaseAlgorithm::GetRemainingPfoMatches ( const ValidationInfo validationInfo,
const pandora::MCParticleVector mcPrimaryVector,
const pandora::PfoSet usedPfos,
LArMCParticleHelper::MCParticleToPfoHitSharingMap interpretedMCToPfoHitSharingMap 
) const
protectedinherited

Get the best matches for any pfos left-over after the strong matching procedure.

Parameters
validationInfothe validation info
mcPrimaryVectorthe mc primary vector
usedPfosthe set of previously used pfos
interpretedMCToPfoHitSharingMapthe output, interpreted mc particle to pfo hit sharing map

Definition at line 155 of file EventValidationBaseAlgorithm.cc.

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

◆ GetStrongestPfoMatch()

bool lar_content::EventValidationBaseAlgorithm::GetStrongestPfoMatch ( const ValidationInfo validationInfo,
const pandora::MCParticleVector mcPrimaryVector,
pandora::PfoSet usedPfos,
LArMCParticleHelper::MCParticleToPfoHitSharingMap interpretedMCToPfoHitSharingMap 
) const
protectedinherited

Get the strongest pfo match (most matched hits) between an available mc primary and an available pfo.

Parameters
validationInfothe validation info
mcPrimaryVectorthe mc primary vector
usedPfosthe set of previously used pfos
interpretedMCToPfoHitSharingMapthe output, interpreted mc particle to pfo hit sharing map
Returns
whether a strong match was identified

Definition at line 111 of file EventValidationBaseAlgorithm.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.

◆ 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:

◆ InterpretMatching()

void lar_content::EventValidationBaseAlgorithm::InterpretMatching ( const ValidationInfo validationInfo,
LArMCParticleHelper::MCParticleToPfoHitSharingMap interpretedMCToPfoHitSharingMap 
) const
protectedinherited

Apply an interpretative matching procedure to the comprehensive matches in the provided validation info object.

Parameters
validationInfothe validation info
interpretedMCToPfoHitSharingMapthe output, interpreted mc particle to pfo hit sharing map

Definition at line 86 of file EventValidationBaseAlgorithm.cc.

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

◆ IsGoodMatch()

bool lar_content::EventValidationBaseAlgorithm::IsGoodMatch ( const pandora::CaloHitList trueHits,
const pandora::CaloHitList recoHits,
const pandora::CaloHitList sharedHits 
) const
protectedinherited

Whether a provided mc primary and pfo are deemed to be a good match.

Parameters
trueHitsthe list of true hits
recoHitsthe list of reco hits
sharedHitsthe list of shared hits
Returns
boolean

Definition at line 203 of file EventValidationBaseAlgorithm.cc.

Here is the caller graph for this function:

◆ PrintAllMatches()

void lar_content::EventValidationBaseAlgorithm::PrintAllMatches ( const ValidationInfo validationInfo) const
inlineprivateinherited

Print all/raw matching information to screen.

Parameters
validationInfothe validation info

Definition at line 313 of file EventValidationBaseAlgorithm.h.

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

◆ PrintInterpretedMatches()

void lar_content::EventValidationBaseAlgorithm::PrintInterpretedMatches ( const ValidationInfo validationInfo) const
inlineprivateinherited

Print interpreted matching information to screen.

Parameters
validationInfothe validation info

Definition at line 320 of file EventValidationBaseAlgorithm.h.

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

◆ ProcessOutput()

void lar_content::TestBeamHierarchyEventValidationAlgorithm::ProcessOutput ( const ValidationInfo validationInfo,
const bool  useInterpretedMatching,
const bool  printToScreen,
const bool  fillTree 
) const
privatevirtual

Print matching information in a provided validation info object, and write information to tree if configured to do so.

Parameters
validationInfothe validation info
useInterpretedMatchingwhether to use the interpreted (rather than raw) matching information
printToScreenwhether to print the information to screen
fillTreewhether to write the information to tree

Implements lar_content::EventValidationBaseAlgorithm.

Definition at line 101 of file TestBeamHierarchyEventValidationAlgorithm.cc.

Here is the call graph for this function:

◆ ReadSettings()

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

Read the algorithm settings.

Parameters
xmlHandlethe relevant xml handle

Reimplemented from lar_content::EventValidationBaseAlgorithm.

Definition at line 622 of file TestBeamHierarchyEventValidationAlgorithm.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()

StatusCode lar_content::EventValidationBaseAlgorithm::Run ( )
privatevirtualinherited

Run the algorithm.

Implements pandora::Algorithm.

Definition at line 56 of file EventValidationBaseAlgorithm.cc.

Here is the call graph for this function:

◆ WriteInterpretedMatches()

void lar_content::EventValidationBaseAlgorithm::WriteInterpretedMatches ( const ValidationInfo validationInfo) const
inlineprivateinherited

Write interpreted matching information to tree.

Parameters
validationInfothe validation info

Definition at line 327 of file EventValidationBaseAlgorithm.h.

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

Member Data Documentation

◆ m_caloHitListName

std::string lar_content::EventValidationBaseAlgorithm::m_caloHitListName
privateinherited

Name of input calo hit list.

Definition at line 222 of file EventValidationBaseAlgorithm.h.

◆ m_eventNumber

int lar_content::EventValidationBaseAlgorithm::m_eventNumber
protectedinherited

The event number.

Definition at line 194 of file EventValidationBaseAlgorithm.h.

◆ m_fileIdentifier

int lar_content::EventValidationBaseAlgorithm::m_fileIdentifier
protectedinherited

The input file identifier.

Definition at line 193 of file EventValidationBaseAlgorithm.h.

◆ m_fileName

std::string lar_content::EventValidationBaseAlgorithm::m_fileName
privateinherited

Name of output file.

Definition at line 235 of file EventValidationBaseAlgorithm.h.

◆ m_instanceName

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

The process instance name.

Definition at line 89 of file Process.h.

◆ m_matchingMinCompleteness

float lar_content::EventValidationBaseAlgorithm::m_matchingMinCompleteness
privateinherited

The minimum particle completeness to declare a match.

Definition at line 232 of file EventValidationBaseAlgorithm.h.

◆ m_matchingMinPurity

float lar_content::EventValidationBaseAlgorithm::m_matchingMinPurity
privateinherited

The minimum particle purity to declare a match.

Definition at line 233 of file EventValidationBaseAlgorithm.h.

◆ m_matchingMinSharedHits

unsigned int lar_content::EventValidationBaseAlgorithm::m_matchingMinSharedHits
privateinherited

The minimum number of shared hits used in matching scheme.

Definition at line 231 of file EventValidationBaseAlgorithm.h.

◆ m_mcParticleListName

std::string lar_content::EventValidationBaseAlgorithm::m_mcParticleListName
privateinherited

Name of input MC particle list.

Definition at line 223 of file EventValidationBaseAlgorithm.h.

◆ m_pfoListName

std::string lar_content::EventValidationBaseAlgorithm::m_pfoListName
privateinherited

Name of input Pfo list.

Definition at line 224 of file EventValidationBaseAlgorithm.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_primaryParameters

LArMCParticleHelper::PrimaryParameters lar_content::EventValidationBaseAlgorithm::m_primaryParameters
protectedinherited

The mc particle primary selection parameters.

Definition at line 192 of file EventValidationBaseAlgorithm.h.

◆ m_printAllToScreen

bool lar_content::EventValidationBaseAlgorithm::m_printAllToScreen
privateinherited

Whether to print all/raw matching details to screen.

Definition at line 226 of file EventValidationBaseAlgorithm.h.

◆ m_printMatchingToScreen

bool lar_content::EventValidationBaseAlgorithm::m_printMatchingToScreen
privateinherited

Whether to print matching output to screen.

Definition at line 227 of file EventValidationBaseAlgorithm.h.

◆ m_treeName

std::string lar_content::EventValidationBaseAlgorithm::m_treeName
protectedinherited

Name of output tree.

Definition at line 196 of file EventValidationBaseAlgorithm.h.

◆ m_type

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

The process type.

Definition at line 88 of file Process.h.

◆ m_useSmallPrimaries

bool lar_content::EventValidationBaseAlgorithm::m_useSmallPrimaries
privateinherited

Whether to consider matches to mc primaries with fewer than m_matchingMinPrimaryHits.

Definition at line 230 of file EventValidationBaseAlgorithm.h.

◆ m_writeToTree

bool lar_content::EventValidationBaseAlgorithm::m_writeToTree
privateinherited

Whether to write all/raw matching details to tree.

Definition at line 228 of file EventValidationBaseAlgorithm.h.


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