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

LArMCParticleHelper class. More...

#include "LArMCParticleHelper.h"

Classes

class  PrimaryParameters
 PrimaryParameters class. More...
 

Public Types

typedef std::unordered_map< const pandora::MCParticle *, const pandora::MCParticle * > MCRelationMap
 
typedef std::unordered_map< const pandora::MCParticle *, int > MCParticleIntMap
 
typedef std::unordered_map< const pandora::MCParticle *, const pandora::ParticleFlowObject * > MCToPfoMap
 
typedef std::unordered_map< const pandora::CaloHit *, const pandora::MCParticle * > CaloHitToMCMap
 
typedef std::unordered_map< const pandora::CaloHit *, const pandora::ParticleFlowObject * > CaloHitToPfoMap
 
typedef std::unordered_map< const pandora::MCParticle *, pandora::CaloHitListMCContributionMap
 
typedef std::vector< MCContributionMapMCContributionMapVector
 
typedef std::unordered_map< const pandora::Cluster *, pandora::CaloHitListClusterContributionMap
 
typedef std::unordered_map< const pandora::ParticleFlowObject *, pandora::CaloHitListPfoContributionMap
 
typedef std::unordered_map< const pandora::MCParticle *, PfoContributionMapMCToPfoMatchingMap
 
typedef std::pair< const pandora::MCParticle *, pandora::CaloHitListMCParticleCaloHitListPair
 
typedef std::pair< const pandora::ParticleFlowObject *, pandora::CaloHitListPfoCaloHitListPair
 
typedef std::pair< const pandora::Cluster *, pandora::CaloHitListClusterCaloHitListPair
 
typedef std::vector< MCParticleCaloHitListPairMCParticleToSharedHitsVector
 
typedef std::vector< PfoCaloHitListPairPfoToSharedHitsVector
 
typedef std::map< const pandora::ParticleFlowObject *, MCParticleToSharedHitsVectorPfoToMCParticleHitSharingMap
 
typedef std::map< const pandora::MCParticle *, PfoToSharedHitsVectorMCParticleToPfoHitSharingMap
 

Static Public Member Functions

static bool DoesPrimaryMeetCriteria (const pandora::MCParticle *const pMCParticle, std::function< bool(const pandora::MCParticle *const)> fCriteria)
 Returns true if passed particle whose primary meets the passed criteria.
 
static bool DoesLeadingMeetCriteria (const pandora::MCParticle *const pMCParticle, std::function< bool(const pandora::MCParticle *const)> fCriteria)
 Returns true if passed particle whose leading meets the passed criteria.
 
static bool IsBeamNeutrinoFinalState (const pandora::MCParticle *const pMCParticle)
 Returns true if passed a primary neutrino final state MCParticle.
 
static bool IsTriggeredBeamParticle (const pandora::MCParticle *const pMCParticle)
 Returns true if passed a primary triggered beam MCParticle.
 
static bool IsBeamParticle (const pandora::MCParticle *const pMCParticle)
 Returns true if passed a primary beam MCParticle.
 
static bool IsLeadingBeamParticle (const pandora::MCParticle *const pMCParticle)
 Returns true if passed a leading beam MCParticle.
 
static bool IsCosmicRay (const pandora::MCParticle *const pMCParticle)
 Return true if passed a primary cosmic ray MCParticle.
 
static unsigned int GetNuanceCode (const pandora::MCParticle *const pMCParticle)
 Get the nuance code of an MCParticle.
 
static bool IsNeutrino (const pandora::MCParticle *const pMCParticle)
 Whether a mc particle is a neutrino or antineutrino.
 
static bool IsPrimary (const pandora::MCParticle *const pMCParticle)
 Whether a provided mc particle matches the implemented definition of being primary.
 
static bool IsLeading (const pandora::MCParticle *const pMCParticle)
 Whether a provided mc particle matches the implemented definition of being leading.
 
static int GetHierarchyTier (const pandora::MCParticle *const pMCParticle)
 Determine the position in the hierarchy for the MCParticle.
 
static bool IsVisible (const pandora::MCParticle *const pMCParticle)
 Whether a mc particle is visible (i.e. long-lived charged particle)
 
static void GetTrueNeutrinos (const pandora::MCParticleList *const pMCParticleList, pandora::MCParticleVector &trueNeutrinos)
 Get neutrino MC particles from an input MC particle list.
 
static void GetTrueTestBeamParticles (const pandora::MCParticleList *const pMCParticleList, pandora::MCParticleVector &trueTestBeamParticles)
 Get triggered test beam MC particles from an input MC particle list.
 
static void GetFirstVisibleMCParticles (const pandora::MCParticle *const pRoot, pandora::MCParticleList &visibleParticleList)
 Get the first visible MC particles given a root particle. For example, given a neutrino this would return the primaries (the visible final state particles or the first visible descendents of invisible final state particles - note photons and neutrons are considered visible for this purpose).
 
static const pandora::MCParticleGetPrimaryMCParticle (const pandora::MCParticle *const pMCParticle)
 Get the primary parent mc particle.
 
static const pandora::MCParticleGetLeadingMCParticle (const pandora::MCParticle *const pMCParticle, const int hierarchyTierLimit=1)
 Get the leading particle in the hierarchy, for use at ProtoDUNE.
 
static void GetPrimaryMCParticleList (const pandora::MCParticleList *const pMCParticleList, pandora::MCParticleVector &mcPrimaryVector)
 Get vector of primary MC particles from an input list of MC particles.
 
static void GetLeadingMCParticleList (const pandora::MCParticleList *const pMCParticleList, pandora::MCParticleVector &mcLeadingVector)
 Get vector of leading MC particles from an input list of MC particles.
 
static const pandora::MCParticleGetParentMCParticle (const pandora::MCParticle *const pMCParticle)
 Get the parent mc particle.
 
static void GetAllDescendentMCParticles (const pandora::MCParticle *const pMCParticle, pandora::MCParticleList &descendentMCParticleList)
 Get all descendent mc particles.
 
static void GetAllDescendentMCParticles (const pandora::MCParticle *const pMCParticle, pandora::MCParticleList &descendentTrackParticles, pandora::MCParticleList &leadingShowerParticles, pandora::MCParticleList &leadingNeutrons)
 Get all descendent mc particles, separated into track-like, shower-like and neutron branches. This method collects together all track-like particles (i.e. not electron, photon or neutron) downstream of the root particle, stopping at a leading shower or neutron and then storing that leading shower or neutron in a separate list.
 
static void GetAllAncestorMCParticles (const pandora::MCParticle *const pMCParticle, pandora::MCParticleList &ancestorMCParticleList)
 Get all ancestor mc particles.
 
static void GetMCPrimaryMap (const pandora::MCParticleList *const pMCParticleList, MCRelationMap &mcPrimaryMap)
 Get mapping from individual mc particles (in a provided list) and their primary parent mc particles.
 
static void GetMCLeadingMap (const pandora::MCParticleList *const pMCParticleList, MCRelationMap &mcLeadingMap)
 Get mapping from individual mc particles (in a provided list) and their leading parent mc particles.
 
static void GetMCToSelfMap (const pandora::MCParticleList *const pMCParticleList, MCRelationMap &mcToSelfMap)
 Get mapping from individual mc particles (in a provided list) to themselves (to be used when not folding particles to their primaries)
 
static const pandora::MCParticleGetMainMCParticle (const pandora::ParticleFlowObject *const pPfo)
 Find the mc particle making the largest contribution to 2D clusters in a specified pfo.
 
static bool SortByMomentum (const pandora::MCParticle *const pLhs, const pandora::MCParticle *const pRhs)
 Sort mc particles by their momentum.
 
static void GetMCParticleToCaloHitMatches (const pandora::CaloHitList *const pCaloHitList, const MCRelationMap &mcToTargetMCMap, CaloHitToMCMap &hitToMCMap, MCContributionMap &mcToTrueHitListMap)
 Match calo hits to their parent particles.
 
static void SelectReconstructableMCParticles (const pandora::MCParticleList *pMCParticleList, const pandora::CaloHitList *pCaloHitList, const PrimaryParameters &parameters, std::function< bool(const pandora::MCParticle *const)> fCriteria, MCContributionMap &selectedMCParticlesToHitsMap)
 Select target, reconstructable mc particles that match given criteria.
 
static void SelectReconstructableTestBeamHierarchyMCParticles (const pandora::MCParticleList *pMCParticleList, const pandora::CaloHitList *pCaloHitList, const PrimaryParameters &parameters, std::function< bool(const pandora::MCParticle *const)> fCriteria, MCContributionMap &selectedMCParticlesToHitsMap)
 Select target, reconstructable mc particles in the relevant hierarchy that match given criteria.
 
static void GetPfoToReconstructable2DHitsMap (const pandora::PfoList &pfoList, const MCContributionMap &selectedMCParticleToHitsMap, PfoContributionMap &pfoToReconstructable2DHitsMap, const bool foldBackHierarchy)
 Get mapping from Pfo to reconstructable 2D hits (=good hits belonging to a selected reconstructable MCParticle)
 
static void GetTestBeamHierarchyPfoToReconstructable2DHitsMap (const pandora::PfoList &pfoList, const MCContributionMap &selectedMCParticleToHitsMap, PfoContributionMap &pfoToReconstructable2DHitsMap, const bool foldBackHierarchy)
 Get mapping from Pfo in reconstructed test beam hierarchy to reconstructable 2D hits (=good hits belonging to a selected reconstructable MCParticle)
 
static void GetPfoToReconstructable2DHitsMap (const pandora::PfoList &pfoList, const MCContributionMapVector &selectedMCParticleToHitsMaps, PfoContributionMap &pfoToReconstructable2DHitsMap, const bool foldBackHierarchy)
 Get mapping from Pfo to reconstructable 2D hits (=good hits belonging to a selected reconstructable MCParticle)
 
static void GetTestBeamHierarchyPfoToReconstructable2DHitsMap (const pandora::PfoList &pfoList, const MCContributionMapVector &selectedMCParticleToHitsMaps, PfoContributionMap &pfoToReconstructable2DHitsMap, const bool foldBackHierarchy)
 Get mapping from Pfo in reconstructed test beam hierarchy to reconstructable 2D hits (=good hits belonging to a selected reconstructable MCParticle)
 
static void GetClusterToReconstructable2DHitsMap (const pandora::ClusterList &clusterList, const MCContributionMap &selectedMCToHitsMap, ClusterContributionMap &clusterToReconstructable2DHitsMap)
 Get mapping from cluster to reconstructable 2D hits (=good hits belonging to a selected reconstructable MCParticle)
 
static void GetClusterToReconstructable2DHitsMap (const pandora::ClusterList &clusterList, const MCContributionMapVector &selectedMCToHitsMaps, ClusterContributionMap &clusterToReconstructable2DHitsMap)
 Get mapping from cluster to reconstructable 2D hits (=good hits belonging to a selected reconstructable MCParticle)
 
static void GetPfoMCParticleHitSharingMaps (const PfoContributionMap &pfoToReconstructable2DHitsMap, const MCContributionMapVector &selectedMCParticleToHitsMaps, PfoToMCParticleHitSharingMap &pfoToMCParticleHitSharingMap, MCParticleToPfoHitSharingMap &mcParticleToPfoHitSharingMap)
 Get the mappings from Pfo -> pair (reconstructable MCparticles, number of reconstructable 2D hits shared with Pfo) reconstructable MCParticle -> pair (Pfo, number of reconstructable 2D hits shared with MCParticle)
 
static void SelectCaloHits (const pandora::CaloHitList *const pCaloHitList, const MCRelationMap &mcToTargetMCMap, pandora::CaloHitList &selectedCaloHitList, const bool selectInputHits, const float maxPhotonPropagation)
 Select a subset of calo hits representing those that represent "reconstructable" regions of the event.
 
static bool IsDescendentOf (const pandora::MCParticle *const pMCParticle, const int pdg, const bool isChargeSensitive=false)
 Determine if the MC particle is a descendent of a particle with the given PDG code.
 
static void GetBreadthFirstHierarchyRepresentation (const pandora::MCParticle *const pMCParticle, pandora::MCParticleList &mcParticleList)
 Retrieve a linearised representation of the MC particle hierarchy in breadth first order. This iterates over the MC hierarchy in a manor that sees primaries at the front of the list, with progressively deeper tiers later in the list. This is useful for some visualisation cases.
 
static void SelectParticlesByHitCount (const pandora::MCParticleVector &candidateTargets, const MCContributionMap &mcToTrueHitListMap, const MCRelationMap &mcToTargetMCMap, const PrimaryParameters &parameters, MCContributionMap &selectedMCParticlesToHitsMap)
 Filter an input vector of MCParticles to ensure they have sufficient good hits to be reconstructable.
 
static pandora::CaloHitList GetSharedHits (const pandora::CaloHitList &hitListA, const pandora::CaloHitList &hitListB)
 Get the hits in the intersection of two hit lists.
 
static bool IsBremsstrahlung (const pandora::MCParticle *const pMCParticle)
 
static bool IsCapture (const pandora::MCParticle *const pMCParticle)
 Check whether or not an MC particle comes from a capture process.
 
static bool IsDecay (const pandora::MCParticle *const pMCParticle)
 Check whether or not an MC particle comes from a decay process.
 
static bool IsElasticScatter (const pandora::MCParticle *const pMCParticle)
 Check whether or not an MC particle came from an elastic scattering process.
 
static bool IsInelasticScatter (const pandora::MCParticle *const pMCParticle)
 Check whether or not an MC particle came from an inelastic scattering process.
 
static bool IsIonisation (const pandora::MCParticle *const pMCParticle)
 Check whether or not an MC particle comes from an ionisation process.
 
static bool IsNuclear (const pandora::MCParticle *const pMCParticle)
 Check whether or not an MC particle comes from a nuclear interaction process.
 
static bool IsPairProduction (const pandora::MCParticle *const pMCParticle)
 Check whether or not an MC particle comes from a pair production process.
 
static bool AreTopologicallyContinuous (const pandora::MCParticle *const pMCParent, const pandora::MCParticle *const pMCChild, const float cosAngleTolerance)
 Determine if two MC particles are topologically continuous within a given tolerance. If the parent does not travel any distance, a travelling parent is sought and the comparison made between this and the child. If no travelling parent can be found, the particles are treated as continuous.
 

Static Private Member Functions

static void CollectReconstructable2DHits (const pandora::ParticleFlowObject *const pPfo, const MCContributionMapVector &selectedMCParticleToHitsMaps, pandora::CaloHitList &reconstructableCaloHitList2D, const bool foldBackHierarchy)
 For a given Pfo, collect the hits which are reconstructable (=good hits belonging to a selected reconstructable MCParticle)
 
static void CollectReconstructableTestBeamHierarchy2DHits (const pandora::ParticleFlowObject *const pPfo, const MCContributionMapVector &selectedMCParticleToHitsMaps, pandora::CaloHitList &reconstructableCaloHitList2D, const bool foldBackHierarchy)
 For a given Pfo, collect the hits which are reconstructable (=good hits belonging to a selected reconstructable MCParticle) and belong in the test beam particle interaction hierarchy.
 
static void CollectReconstructable2DHits (const pandora::PfoList &pfoList, const MCContributionMapVector &selectedMCParticleToHitsMaps, pandora::CaloHitList &reconstructableCaloHitList2D)
 For a given Pfo list, collect the hits which are reconstructable (=good hits belonging to a selected reconstructable MCParticle)
 
static void CollectReconstructable2DHits (const pandora::Cluster *const pCluster, const MCContributionMapVector &selectedMCParticleToHitsMaps, pandora::CaloHitList &reconstructableCaloHitList2D)
 For a given cluster, collect the hits which are reconstructable (=good hits belonging to a selected reconstructable MCParticle)
 
static void SelectGoodCaloHits (const pandora::CaloHitList *const pSelectedCaloHitList, const MCRelationMap &mcToTargetMCMap, pandora::CaloHitList &selectedGoodCaloHitList, const bool selectInputHits, const float minHitSharingFraction)
 Apply further selection criteria to end up with a collection of "good" calo hits that can be use to define whether a target mc particle is reconstructable.
 
static void SelectParticlesMatchingCriteria (const pandora::MCParticleVector &inputMCParticles, std::function< bool(const pandora::MCParticle *const)> fCriteria, pandora::MCParticleVector &selectedParticles, const PrimaryParameters &parameters, const bool isTestBeam)
 Select mc particles matching given criteria from an input list.
 
static bool PassMCParticleChecks (const pandora::MCParticle *const pOriginalPrimary, const pandora::MCParticle *const pThisMCParticle, const pandora::MCParticle *const pHitMCParticle, const float maxPhotonPropagation)
 Whether it is possible to navigate from a primary mc particle to a downstream mc particle without "passing through" a neutron.
 

Detailed Description

LArMCParticleHelper class.

Definition at line 24 of file LArMCParticleHelper.h.

Member Typedef Documentation

◆ CaloHitToMCMap

Definition at line 32 of file LArMCParticleHelper.h.

◆ CaloHitToPfoMap

Definition at line 33 of file LArMCParticleHelper.h.

◆ ClusterCaloHitListPair

◆ ClusterContributionMap

◆ MCContributionMap

◆ MCContributionMapVector

◆ MCParticleCaloHitListPair

◆ MCParticleIntMap

Definition at line 28 of file LArMCParticleHelper.h.

◆ MCParticleToPfoHitSharingMap

◆ MCParticleToSharedHitsVector

◆ MCRelationMap

Definition at line 27 of file LArMCParticleHelper.h.

◆ MCToPfoMap

Definition at line 30 of file LArMCParticleHelper.h.

◆ MCToPfoMatchingMap

◆ PfoCaloHitListPair

◆ PfoContributionMap

◆ PfoToMCParticleHitSharingMap

◆ PfoToSharedHitsVector

Member Function Documentation

◆ AreTopologicallyContinuous()

bool lar_content::LArMCParticleHelper::AreTopologicallyContinuous ( const pandora::MCParticle *const  pMCParent,
const pandora::MCParticle *const  pMCChild,
const float  cosAngleTolerance 
)
static

Determine if two MC particles are topologically continuous within a given tolerance. If the parent does not travel any distance, a travelling parent is sought and the comparison made between this and the child. If no travelling parent can be found, the particles are treated as continuous.

Parameters
pMCParentThe parent MC particle
pMCChildThe child MC particle
cosAngleToleranceThe cosine of the maximum acceptable angular deviation
Returns
True if the partiles are topologically continous, false otherwise.

Definition at line 974 of file LArMCParticleHelper.cc.

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

◆ CollectReconstructable2DHits() [1/3]

void lar_content::LArMCParticleHelper::CollectReconstructable2DHits ( const pandora::Cluster *const  pCluster,
const MCContributionMapVector selectedMCParticleToHitsMaps,
pandora::CaloHitList reconstructableCaloHitList2D 
)
staticprivate

For a given cluster, collect the hits which are reconstructable (=good hits belonging to a selected reconstructable MCParticle)

Parameters
pClusterthe input cluster
selectedMCToHitsMapsthe input mappings from selected reconstructable MCParticles to hits
reconstructableCaloHitList2Dthe output list of reconstructable 2D calo hits in the input pfo

Definition at line 1097 of file LArMCParticleHelper.cc.

Here is the call graph for this function:

◆ CollectReconstructable2DHits() [2/3]

void lar_content::LArMCParticleHelper::CollectReconstructable2DHits ( const pandora::ParticleFlowObject *const  pPfo,
const MCContributionMapVector selectedMCParticleToHitsMaps,
pandora::CaloHitList reconstructableCaloHitList2D,
const bool  foldBackHierarchy 
)
staticprivate

For a given Pfo, collect the hits which are reconstructable (=good hits belonging to a selected reconstructable MCParticle)

Parameters
pPfothe input pfo
selectedMCParticleToHitsMapsthe input mappings from selected reconstructable MCParticles to hits
reconstructableCaloHitList2Dthe output list of reconstructable 2D calo hits in the input pfo
foldBackHierarchywhether to fold the particle hierarchy back to primaries

Definition at line 1009 of file LArMCParticleHelper.cc.

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

◆ CollectReconstructable2DHits() [3/3]

void lar_content::LArMCParticleHelper::CollectReconstructable2DHits ( const pandora::PfoList pfoList,
const MCContributionMapVector selectedMCParticleToHitsMaps,
pandora::CaloHitList reconstructableCaloHitList2D 
)
staticprivate

For a given Pfo list, collect the hits which are reconstructable (=good hits belonging to a selected reconstructable MCParticle)

Parameters
pfoListthe input pfo list
selectedMCParticleToHitsMapsthe input mappings from selected reconstructable MCParticles to hits
reconstructableCaloHitList2Dthe output list of reconstructable 2D calo hits in the input pfo

Definition at line 1060 of file LArMCParticleHelper.cc.

Here is the call graph for this function:

◆ CollectReconstructableTestBeamHierarchy2DHits()

void lar_content::LArMCParticleHelper::CollectReconstructableTestBeamHierarchy2DHits ( const pandora::ParticleFlowObject *const  pPfo,
const MCContributionMapVector selectedMCParticleToHitsMaps,
pandora::CaloHitList reconstructableCaloHitList2D,
const bool  foldBackHierarchy 
)
staticprivate

For a given Pfo, collect the hits which are reconstructable (=good hits belonging to a selected reconstructable MCParticle) and belong in the test beam particle interaction hierarchy.

Parameters
pPfothe input pfo
selectedMCParticleToHitsMapsthe input mappings from selected reconstructable MCParticles to hits
reconstructableCaloHitList2Dthe output list of reconstructable 2D calo hits in the input pfo
foldBackHierarchywhether to fold the particle hierarchy back to leading particles

Definition at line 1031 of file LArMCParticleHelper.cc.

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

◆ DoesLeadingMeetCriteria()

bool lar_content::LArMCParticleHelper::DoesLeadingMeetCriteria ( const pandora::MCParticle *const  pMCParticle,
std::function< bool(const pandora::MCParticle *const)>  fCriteria 
)
static

Returns true if passed particle whose leading meets the passed criteria.

Parameters
pMCParticlethe input mc particle
fCriteriathe given criteria

Definition at line 61 of file LArMCParticleHelper.cc.

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

◆ DoesPrimaryMeetCriteria()

bool lar_content::LArMCParticleHelper::DoesPrimaryMeetCriteria ( const pandora::MCParticle *const  pMCParticle,
std::function< bool(const pandora::MCParticle *const)>  fCriteria 
)
static

Returns true if passed particle whose primary meets the passed criteria.

Parameters
pMCParticlethe input mc particle
fCriteriathe given criteria

Definition at line 45 of file LArMCParticleHelper.cc.

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

◆ GetAllAncestorMCParticles()

void lar_content::LArMCParticleHelper::GetAllAncestorMCParticles ( const pandora::MCParticle *const  pMCParticle,
pandora::MCParticleList ancestorMCParticleList 
)
static

Get all ancestor mc particles.

Parameters
pMCParticlethe input mc particle
ancestorMCParticleListthe output ancestor mc particle list

Definition at line 290 of file LArMCParticleHelper.cc.

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

◆ GetAllDescendentMCParticles() [1/2]

void lar_content::LArMCParticleHelper::GetAllDescendentMCParticles ( const pandora::MCParticle *const  pMCParticle,
pandora::MCParticleList descendentMCParticleList 
)
static

Get all descendent mc particles.

Parameters
pMCParticlethe input mc particle
descendentMCParticleListthe output descendent mc particle list

Definition at line 249 of file LArMCParticleHelper.cc.

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

◆ GetAllDescendentMCParticles() [2/2]

void lar_content::LArMCParticleHelper::GetAllDescendentMCParticles ( const pandora::MCParticle *const  pMCParticle,
pandora::MCParticleList descendentTrackParticles,
pandora::MCParticleList leadingShowerParticles,
pandora::MCParticleList leadingNeutrons 
)
static

Get all descendent mc particles, separated into track-like, shower-like and neutron branches. This method collects together all track-like particles (i.e. not electron, photon or neutron) downstream of the root particle, stopping at a leading shower or neutron and then storing that leading shower or neutron in a separate list.

Parameters
pMCParticlethe input mc particle
descendentTrackParticlesthe output list of descendent track-like particles
leadingShowerParticlesthe output list of leading shower particles
leadingNeutronsthe output list of leading neutrons

Definition at line 263 of file LArMCParticleHelper.cc.

Here is the call graph for this function:

◆ GetBreadthFirstHierarchyRepresentation()

void lar_content::LArMCParticleHelper::GetBreadthFirstHierarchyRepresentation ( const pandora::MCParticle *const  pMCParticle,
pandora::MCParticleList mcParticleList 
)
static

Retrieve a linearised representation of the MC particle hierarchy in breadth first order. This iterates over the MC hierarchy in a manor that sees primaries at the front of the list, with progressively deeper tiers later in the list. This is useful for some visualisation cases.

Parameters
pMCParticlean MC particle in the hierarchy - can be any particle
mcParticleListthe output MC particle list

Definition at line 1185 of file LArMCParticleHelper.cc.

Here is the call graph for this function:

◆ GetClusterToReconstructable2DHitsMap() [1/2]

void lar_content::LArMCParticleHelper::GetClusterToReconstructable2DHitsMap ( const pandora::ClusterList clusterList,
const MCContributionMap selectedMCToHitsMap,
ClusterContributionMap clusterToReconstructable2DHitsMap 
)
static

Get mapping from cluster to reconstructable 2D hits (=good hits belonging to a selected reconstructable MCParticle)

Parameters
clusterListthe input list of clusters
selectedMCToHitsMapthe input mapping from selected reconstructable MCParticles to their hits
clusterToReconstructable2DHitsMapthe output mapping from clusters to their reconstructable 2D hits

Definition at line 751 of file LArMCParticleHelper.cc.

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

◆ GetClusterToReconstructable2DHitsMap() [2/2]

void lar_content::LArMCParticleHelper::GetClusterToReconstructable2DHitsMap ( const pandora::ClusterList clusterList,
const MCContributionMapVector selectedMCToHitsMaps,
ClusterContributionMap clusterToReconstructable2DHitsMap 
)
static

Get mapping from cluster to reconstructable 2D hits (=good hits belonging to a selected reconstructable MCParticle)

Parameters
clusterListthe input list of clusters
selectedMCToHitsMapsthe input vector of mappings from selected reconstructable MCParticles to their hits
clusterToReconstructable2DHitsMapthe output mapping from cluster to their reconstructable 2D hits

Definition at line 759 of file LArMCParticleHelper.cc.

Here is the call graph for this function:

◆ GetFirstVisibleMCParticles()

void lar_content::LArMCParticleHelper::GetFirstVisibleMCParticles ( const pandora::MCParticle *const  pRoot,
pandora::MCParticleList visibleParticleList 
)
static

Get the first visible MC particles given a root particle. For example, given a neutrino this would return the primaries (the visible final state particles or the first visible descendents of invisible final state particles - note photons and neutrons are considered visible for this purpose).

Parameters
pRootthe input mc particle
visibleParticleListthe output list of visible particles (if pRoot is visible this will contain only pRoot)

Definition at line 338 of file LArMCParticleHelper.cc.

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

◆ GetHierarchyTier()

int lar_content::LArMCParticleHelper::GetHierarchyTier ( const pandora::MCParticle *const  pMCParticle)
static

Determine the position in the hierarchy for the MCParticle.

Parameters
pMCParticlethe address of the mc particle
Returns
integer

Definition at line 173 of file LArMCParticleHelper.cc.

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

◆ GetLeadingMCParticle()

const MCParticle * lar_content::LArMCParticleHelper::GetLeadingMCParticle ( const pandora::MCParticle *const  pMCParticle,
const int  hierarchyTierLimit = 1 
)
static

Get the leading particle in the hierarchy, for use at ProtoDUNE.

Parameters
pMCParticlethe input mc particle
Returns
address of the primary parent mc particle

Definition at line 384 of file LArMCParticleHelper.cc.

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

◆ GetLeadingMCParticleList()

void lar_content::LArMCParticleHelper::GetLeadingMCParticleList ( const pandora::MCParticleList *const  pMCParticleList,
pandora::MCParticleVector mcLeadingVector 
)
static

Get vector of leading MC particles from an input list of MC particles.

Parameters
pMCParticleListthe input mc particle list
mcLeadingVectorthe output mc particle vector

Definition at line 321 of file LArMCParticleHelper.cc.

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

◆ GetMainMCParticle()

const MCParticle * lar_content::LArMCParticleHelper::GetMainMCParticle ( const pandora::ParticleFlowObject *const  pPfo)
static

Find the mc particle making the largest contribution to 2D clusters in a specified pfo.

Parameters
pPfoaddress of the pfo to examine
Returns
address of the main mc particle

Definition at line 477 of file LArMCParticleHelper.cc.

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

◆ GetMCLeadingMap()

void lar_content::LArMCParticleHelper::GetMCLeadingMap ( const pandora::MCParticleList *const  pMCParticleList,
MCRelationMap mcLeadingMap 
)
static

Get mapping from individual mc particles (in a provided list) and their leading parent mc particles.

Parameters
pMCParticleListthe input mc particle list
mcLeadingMapthe output mapping between mc particles and their leading parent

Definition at line 450 of file LArMCParticleHelper.cc.

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

◆ GetMCParticleToCaloHitMatches()

void lar_content::LArMCParticleHelper::GetMCParticleToCaloHitMatches ( const pandora::CaloHitList *const  pCaloHitList,
const MCRelationMap mcToTargetMCMap,
CaloHitToMCMap hitToMCMap,
MCContributionMap mcToTrueHitListMap 
)
static

Match calo hits to their parent particles.

Parameters
pCaloHitListthe input list of calo hits
mcToTargetMCMapthe mc particle to target (primary or self) mc particle map
hitToMCMapoutput mapping between calo hits and their main MC particle
mcToTrueHitListMapoutput mapping between MC particles and their associated hits

Definition at line 512 of file LArMCParticleHelper.cc.

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

◆ GetMCPrimaryMap()

void lar_content::LArMCParticleHelper::GetMCPrimaryMap ( const pandora::MCParticleList *const  pMCParticleList,
MCRelationMap mcPrimaryMap 
)
static

Get mapping from individual mc particles (in a provided list) and their primary parent mc particles.

Parameters
pMCParticleListthe input mc particle list
mcPrimaryMapthe output mapping between mc particles and their parents

Definition at line 433 of file LArMCParticleHelper.cc.

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

◆ GetMCToSelfMap()

void lar_content::LArMCParticleHelper::GetMCToSelfMap ( const pandora::MCParticleList *const  pMCParticleList,
MCRelationMap mcToSelfMap 
)
static

Get mapping from individual mc particles (in a provided list) to themselves (to be used when not folding particles to their primaries)

Parameters
pMCParticleListthe input mc particle list
mcToSelfMapthe output mapping between mc particles and themselves

Definition at line 467 of file LArMCParticleHelper.cc.

Here is the caller graph for this function:

◆ GetNuanceCode()

unsigned int lar_content::LArMCParticleHelper::GetNuanceCode ( const pandora::MCParticle *const  pMCParticle)
static

Get the nuance code of an MCParticle.

Definition at line 119 of file LArMCParticleHelper.cc.

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

◆ GetParentMCParticle()

const MCParticle * lar_content::LArMCParticleHelper::GetParentMCParticle ( const pandora::MCParticle *const  pMCParticle)
static

Get the parent mc particle.

Parameters
pMCParticlethe input mc particle
Returns
address of the parent mc particle

Definition at line 232 of file LArMCParticleHelper.cc.

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

◆ GetPfoMCParticleHitSharingMaps()

void lar_content::LArMCParticleHelper::GetPfoMCParticleHitSharingMaps ( const PfoContributionMap pfoToReconstructable2DHitsMap,
const MCContributionMapVector selectedMCParticleToHitsMaps,
PfoToMCParticleHitSharingMap pfoToMCParticleHitSharingMap,
MCParticleToPfoHitSharingMap mcParticleToPfoHitSharingMap 
)
static

Get the mappings from Pfo -> pair (reconstructable MCparticles, number of reconstructable 2D hits shared with Pfo) reconstructable MCParticle -> pair (Pfo, number of reconstructable 2D hits shared with MCParticle)

Parameters
pfoToReconstructable2DHitsMapthe input mapping from Pfos to reconstructable 2D hits
selectedMCParticleToHitsMapsthe input mappings from selected reconstructable MCParticles to hits
pfoToMCParticleHitSharingMapthe output mapping from Pfos to selected reconstructable MCParticles and the number hits shared
mcParticleToPfoHitSharingMapthe output mapping from selected reconstructable MCParticles to Pfos and the number hits shared

Definition at line 686 of file LArMCParticleHelper.cc.

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

◆ GetPfoToReconstructable2DHitsMap() [1/2]

void lar_content::LArMCParticleHelper::GetPfoToReconstructable2DHitsMap ( const pandora::PfoList pfoList,
const MCContributionMap selectedMCParticleToHitsMap,
PfoContributionMap pfoToReconstructable2DHitsMap,
const bool  foldBackHierarchy 
)
static

Get mapping from Pfo to reconstructable 2D hits (=good hits belonging to a selected reconstructable MCParticle)

Parameters
pfoListthe input list of Pfos
selectedMCParticleToHitsMapthe input mapping from selected reconstructable MCParticles to their hits
pfoToReconstructable2DHitsMapthe output mapping from Pfos to their reconstructable 2D hits
foldBackHierarchywhether to fold the particle hierarchy back to the primaries

Definition at line 638 of file LArMCParticleHelper.cc.

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

◆ GetPfoToReconstructable2DHitsMap() [2/2]

void lar_content::LArMCParticleHelper::GetPfoToReconstructable2DHitsMap ( const pandora::PfoList pfoList,
const MCContributionMapVector selectedMCParticleToHitsMaps,
PfoContributionMap pfoToReconstructable2DHitsMap,
const bool  foldBackHierarchy 
)
static

Get mapping from Pfo to reconstructable 2D hits (=good hits belonging to a selected reconstructable MCParticle)

Parameters
pfoListthe input list of Pfos
selectedMCParticleToHitsMapsthe input vector of mappings from selected reconstructable MCParticles to their hits
pfoToReconstructable2DHitsMapthe output mapping from Pfos to their reconstructable 2D hits
foldToHierarchywhether to fold the particle hierarchy back to the primaries

Definition at line 656 of file LArMCParticleHelper.cc.

Here is the call graph for this function:

◆ GetPrimaryMCParticle()

const MCParticle * lar_content::LArMCParticleHelper::GetPrimaryMCParticle ( const pandora::MCParticle *const  pMCParticle)
static

Get the primary parent mc particle.

Parameters
pMCParticlethe input mc particle
Returns
address of the primary parent mc particle

Definition at line 353 of file LArMCParticleHelper.cc.

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

◆ GetPrimaryMCParticleList()

void lar_content::LArMCParticleHelper::GetPrimaryMCParticleList ( const pandora::MCParticleList *const  pMCParticleList,
pandora::MCParticleVector mcPrimaryVector 
)
static

Get vector of primary MC particles from an input list of MC particles.

Parameters
pMCParticleListthe input mc particle list
mcPrimaryVectorthe output mc particle vector

Definition at line 308 of file LArMCParticleHelper.cc.

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

◆ GetSharedHits()

CaloHitList lar_content::LArMCParticleHelper::GetSharedHits ( const pandora::CaloHitList hitListA,
const pandora::CaloHitList hitListB 
)
static

Get the hits in the intersection of two hit lists.

Parameters
hitListAan input hit list
hitListBanother input hit list
Returns
The hits that are found in both hitListA and hitListB

Definition at line 959 of file LArMCParticleHelper.cc.

Here is the caller graph for this function:

◆ GetTestBeamHierarchyPfoToReconstructable2DHitsMap() [1/2]

void lar_content::LArMCParticleHelper::GetTestBeamHierarchyPfoToReconstructable2DHitsMap ( const pandora::PfoList pfoList,
const MCContributionMap selectedMCParticleToHitsMap,
PfoContributionMap pfoToReconstructable2DHitsMap,
const bool  foldBackHierarchy 
)
static

Get mapping from Pfo in reconstructed test beam hierarchy to reconstructable 2D hits (=good hits belonging to a selected reconstructable MCParticle)

Parameters
pfoListthe input list of Pfos
selectedMCParticleToHitsMapthe input mapping from selected reconstructable MCParticles to their hits
pfoToReconstructable2DHitsMapthe output mapping from Pfos to their reconstructable 2D hits
foldBackHierarchywhether to fold the particle hierarchy back to the leading particles

Definition at line 647 of file LArMCParticleHelper.cc.

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

◆ GetTestBeamHierarchyPfoToReconstructable2DHitsMap() [2/2]

void lar_content::LArMCParticleHelper::GetTestBeamHierarchyPfoToReconstructable2DHitsMap ( const pandora::PfoList pfoList,
const MCContributionMapVector selectedMCParticleToHitsMaps,
PfoContributionMap pfoToReconstructable2DHitsMap,
const bool  foldBackHierarchy 
)
static

Get mapping from Pfo in reconstructed test beam hierarchy to reconstructable 2D hits (=good hits belonging to a selected reconstructable MCParticle)

Parameters
pfoListthe input list of Pfos
selectedMCParticleToHitsMapsthe input vector of mappings from selected reconstructable MCParticles to their hits
pfoToReconstructable2DHitsMapthe output mapping from Pfos to their reconstructable 2D hits
foldBackHierarchywhether to fold the particle hierarchy back to the leading particles

Definition at line 671 of file LArMCParticleHelper.cc.

Here is the call graph for this function:

◆ GetTrueNeutrinos()

void lar_content::LArMCParticleHelper::GetTrueNeutrinos ( const pandora::MCParticleList *const  pMCParticleList,
pandora::MCParticleVector trueNeutrinos 
)
static

Get neutrino MC particles from an input MC particle list.

Parameters
pMCParticleListthe input MC particle list
trueNeutrinosto receive the vector of neutrino MC particles

Definition at line 206 of file LArMCParticleHelper.cc.

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

◆ GetTrueTestBeamParticles()

void lar_content::LArMCParticleHelper::GetTrueTestBeamParticles ( const pandora::MCParticleList *const  pMCParticleList,
pandora::MCParticleVector trueTestBeamParticles 
)
static

Get triggered test beam MC particles from an input MC particle list.

Parameters
pMCParticleListthe input MC particle list
trueTestBeamParticlesto receive the vector of neutrino MC particles

Definition at line 219 of file LArMCParticleHelper.cc.

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

◆ IsBeamNeutrinoFinalState()

bool lar_content::LArMCParticleHelper::IsBeamNeutrinoFinalState ( const pandora::MCParticle *const  pMCParticle)
static

Returns true if passed a primary neutrino final state MCParticle.

Definition at line 77 of file LArMCParticleHelper.cc.

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

◆ IsBeamParticle()

bool lar_content::LArMCParticleHelper::IsBeamParticle ( const pandora::MCParticle *const  pMCParticle)
static

Returns true if passed a primary beam MCParticle.

Definition at line 93 of file LArMCParticleHelper.cc.

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

◆ IsBremsstrahlung()

bool lar_content::LArMCParticleHelper::IsBremsstrahlung ( const pandora::MCParticle *const  pMCParticle)
static

Definition at line 774 of file LArMCParticleHelper.cc.

◆ IsCapture()

bool lar_content::LArMCParticleHelper::IsCapture ( const pandora::MCParticle *const  pMCParticle)
static

Check whether or not an MC particle comes from a capture process.

Parameters
pMCParticleThe MC particle to consider
Returns
Whether or not the MC particle came from capture

Definition at line 795 of file LArMCParticleHelper.cc.

◆ IsCosmicRay()

bool lar_content::LArMCParticleHelper::IsCosmicRay ( const pandora::MCParticle *const  pMCParticle)
static

Return true if passed a primary cosmic ray MCParticle.

Definition at line 110 of file LArMCParticleHelper.cc.

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

◆ IsDecay()

bool lar_content::LArMCParticleHelper::IsDecay ( const pandora::MCParticle *const  pMCParticle)
static

Check whether or not an MC particle comes from a decay process.

Parameters
pMCParticleThe MC particle to consider
Returns
Whether or not the MC particle came from decay

Definition at line 818 of file LArMCParticleHelper.cc.

◆ IsDescendentOf()

bool lar_content::LArMCParticleHelper::IsDescendentOf ( const pandora::MCParticle *const  pMCParticle,
const int  pdg,
const bool  isChargeSensitive = false 
)
static

Determine if the MC particle is a descendent of a particle with the given PDG code.

Parameters
pMCParticlethe descendent particle
pdgthe PDG code of the ancestor particle
isChargeSensitivewhether or not to consider the sign of the PDG code when looking for the ancestor (default: false)
Returns
true if the MC particle has an ancestor with the matching PDG code, false otherwise

Definition at line 1165 of file LArMCParticleHelper.cc.

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

◆ IsElasticScatter()

bool lar_content::LArMCParticleHelper::IsElasticScatter ( const pandora::MCParticle *const  pMCParticle)
static

Check whether or not an MC particle came from an elastic scattering process.

Parameters
pMCParticleThe MC particle to consider
Returns
Whether or not the MC particle came from an elastic scatter

Definition at line 837 of file LArMCParticleHelper.cc.

Here is the caller graph for this function:

◆ IsInelasticScatter()

bool lar_content::LArMCParticleHelper::IsInelasticScatter ( const pandora::MCParticle *const  pMCParticle)
static

Check whether or not an MC particle came from an inelastic scattering process.

Parameters
pMCParticleThe MC particle to consider
Returns
Whether or not the MC particle came from an inelastic scatter

Definition at line 859 of file LArMCParticleHelper.cc.

Here is the caller graph for this function:

◆ IsIonisation()

bool lar_content::LArMCParticleHelper::IsIonisation ( const pandora::MCParticle *const  pMCParticle)
static

Check whether or not an MC particle comes from an ionisation process.

Parameters
pMCParticleThe MC particle to consider
Returns
Whether or not the MC particle came from ionisation

Definition at line 896 of file LArMCParticleHelper.cc.

◆ IsLeading()

bool lar_content::LArMCParticleHelper::IsLeading ( const pandora::MCParticle *const  pMCParticle)
static

Whether a provided mc particle matches the implemented definition of being leading.

Parameters
pMCParticlethe address of the mc particle
Returns
boolean

Definition at line 158 of file LArMCParticleHelper.cc.

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

◆ IsLeadingBeamParticle()

bool lar_content::LArMCParticleHelper::IsLeadingBeamParticle ( const pandora::MCParticle *const  pMCParticle)
static

Returns true if passed a leading beam MCParticle.

Definition at line 101 of file LArMCParticleHelper.cc.

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

◆ IsNeutrino()

bool lar_content::LArMCParticleHelper::IsNeutrino ( const pandora::MCParticle *const  pMCParticle)
static

Whether a mc particle is a neutrino or antineutrino.

Parameters
pMCParticlethe input mc particle
Returns
boolean

Definition at line 131 of file LArMCParticleHelper.cc.

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

◆ IsNuclear()

bool lar_content::LArMCParticleHelper::IsNuclear ( const pandora::MCParticle *const  pMCParticle)
static

Check whether or not an MC particle comes from a nuclear interaction process.

Parameters
pMCParticleThe MC particle to consider
Returns
Whether or not the MC particle came from nuclear interaction

Definition at line 918 of file LArMCParticleHelper.cc.

◆ IsPairProduction()

bool lar_content::LArMCParticleHelper::IsPairProduction ( const pandora::MCParticle *const  pMCParticle)
static

Check whether or not an MC particle comes from a pair production process.

Parameters
pMCParticleThe MC particle to consider
Returns
Whether or not the MC particle came from pair production

Definition at line 939 of file LArMCParticleHelper.cc.

◆ IsPrimary()

bool lar_content::LArMCParticleHelper::IsPrimary ( const pandora::MCParticle *const  pMCParticle)
static

Whether a provided mc particle matches the implemented definition of being primary.

Parameters
pMCParticlethe address of the mc particle
Returns
boolean

Definition at line 143 of file LArMCParticleHelper.cc.

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

◆ IsTriggeredBeamParticle()

bool lar_content::LArMCParticleHelper::IsTriggeredBeamParticle ( const pandora::MCParticle *const  pMCParticle)
static

Returns true if passed a primary triggered beam MCParticle.

Definition at line 85 of file LArMCParticleHelper.cc.

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

◆ IsVisible()

bool lar_content::LArMCParticleHelper::IsVisible ( const pandora::MCParticle *const  pMCParticle)
static

Whether a mc particle is visible (i.e. long-lived charged particle)

Parameters
pMCParticlethe input mc particle
Returns
boolean

Definition at line 192 of file LArMCParticleHelper.cc.

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

◆ PassMCParticleChecks()

bool lar_content::LArMCParticleHelper::PassMCParticleChecks ( const pandora::MCParticle *const  pOriginalPrimary,
const pandora::MCParticle *const  pThisMCParticle,
const pandora::MCParticle *const  pHitMCParticle,
const float  maxPhotonPropagation 
)
staticprivate

Whether it is possible to navigate from a primary mc particle to a downstream mc particle without "passing through" a neutron.

Parameters
pOriginalPrimarythe address of the original primary mc particle
pThisMCParticlethe address of the current mc particle in the primary decay chain
pHitMCParticlethe address of the mc particle associated to a calo hit
maxPhotonPropagationthe maximum photon propagation length
Returns
boolean

Definition at line 1331 of file LArMCParticleHelper.cc.

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

◆ SelectCaloHits()

void lar_content::LArMCParticleHelper::SelectCaloHits ( const pandora::CaloHitList *const  pCaloHitList,
const MCRelationMap mcToTargetMCMap,
pandora::CaloHitList selectedCaloHitList,
const bool  selectInputHits,
const float  maxPhotonPropagation 
)
static

Select a subset of calo hits representing those that represent "reconstructable" regions of the event.

Parameters
pCaloHitListthe address of the input calo hit list
mcToTargetMCMapthe mc particle to target (primary or self) mc particle map
selectedCaloHitListto receive the populated selected calo hit list
selectInputHitswhether to select input hits
maxPhotonPropagationthe maximum photon propagation length

Definition at line 1131 of file LArMCParticleHelper.cc.

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

◆ SelectGoodCaloHits()

void lar_content::LArMCParticleHelper::SelectGoodCaloHits ( const pandora::CaloHitList *const  pSelectedCaloHitList,
const MCRelationMap mcToTargetMCMap,
pandora::CaloHitList selectedGoodCaloHitList,
const bool  selectInputHits,
const float  minHitSharingFraction 
)
staticprivate

Apply further selection criteria to end up with a collection of "good" calo hits that can be use to define whether a target mc particle is reconstructable.

Parameters
pSelectedCaloHitListthe address of the calo hit list (typically already been through some selection procedure)
mcToTargetMCMapthe mc particle to target (primary or self) mc particle map
selectedGoodCaloHitListto receive the populated good selected calo hit list
selectInputHitswhether to select input hits
minHitSharingFractionthe minimum Hit sharing fraction

Definition at line 1246 of file LArMCParticleHelper.cc.

Here is the caller graph for this function:

◆ SelectParticlesByHitCount()

void lar_content::LArMCParticleHelper::SelectParticlesByHitCount ( const pandora::MCParticleVector candidateTargets,
const MCContributionMap mcToTrueHitListMap,
const MCRelationMap mcToTargetMCMap,
const PrimaryParameters parameters,
MCContributionMap selectedMCParticlesToHitsMap 
)
static

Filter an input vector of MCParticles to ensure they have sufficient good hits to be reconstructable.

Parameters
candidateTargetscandidate reconstructable MCParticles
mcToTrueHitListMapmapping from candidates reconstructable MCParticles to their true hits
mcToTargetMCMapthe mc particle to target (primary or self) mc particle map
parametersvalidation parameters to decide when an MCParticle is considered reconstructable
selectedMCParticlesToHitsMapthe output mapping from selected mcparticles to their hits

Definition at line 1206 of file LArMCParticleHelper.cc.

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

◆ SelectParticlesMatchingCriteria()

void lar_content::LArMCParticleHelper::SelectParticlesMatchingCriteria ( const pandora::MCParticleVector inputMCParticles,
std::function< bool(const pandora::MCParticle *const)>  fCriteria,
pandora::MCParticleVector selectedParticles,
const PrimaryParameters parameters,
const bool  isTestBeam 
)
staticprivate

Select mc particles matching given criteria from an input list.

Parameters
inputMCParticlesinput vector of MCParticles
fCriteriaa function which returns a bool (= shouldSelect) for a given input MCParticle
selectedParticlesthe output vector of particles selected
parametersvalidation parameters to decide when an MCParticle is considered reconstructable
isTestBeamwhether the mc particles correspond to the test beam case or the neutrino case

Definition at line 1302 of file LArMCParticleHelper.cc.

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

◆ SelectReconstructableMCParticles()

void lar_content::LArMCParticleHelper::SelectReconstructableMCParticles ( const pandora::MCParticleList pMCParticleList,
const pandora::CaloHitList pCaloHitList,
const PrimaryParameters parameters,
std::function< bool(const pandora::MCParticle *const)>  fCriteria,
MCContributionMap selectedMCParticlesToHitsMap 
)
static

Select target, reconstructable mc particles that match given criteria.

Parameters
pMCParticleListthe address of the list of MCParticles
pCaloHitListthe address of the list of CaloHits
parametersvalidation parameters to decide when an MCParticle is considered reconstructable
fCriteriaa function which returns a bool (= shouldSelect) for a given input MCParticle
selectedMCParticlesToHitsMapthe output mapping from selected mcparticles to their hits

Definition at line 546 of file LArMCParticleHelper.cc.

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

◆ SelectReconstructableTestBeamHierarchyMCParticles()

void lar_content::LArMCParticleHelper::SelectReconstructableTestBeamHierarchyMCParticles ( const pandora::MCParticleList pMCParticleList,
const pandora::CaloHitList pCaloHitList,
const PrimaryParameters parameters,
std::function< bool(const pandora::MCParticle *const)>  fCriteria,
MCContributionMap selectedMCParticlesToHitsMap 
)
static

Select target, reconstructable mc particles in the relevant hierarchy that match given criteria.

Parameters
pMCParticleListthe address of the list of MCParticles
pCaloHitListthe address of the list of CaloHits
parametersvalidation parameters to decide when an MCParticle is considered reconstructable
fCriteriaa function which returns a bool (= shouldSelect) for a given input MCParticle
selectedMCParticlesToHitsMapthe output mapping from selected mcparticles to their hits

Definition at line 585 of file LArMCParticleHelper.cc.

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

◆ SortByMomentum()

bool lar_content::LArMCParticleHelper::SortByMomentum ( const pandora::MCParticle *const  pLhs,
const pandora::MCParticle *const  pRhs 
)
static

Sort mc particles by their momentum.

Parameters
pLhsaddress of first mc particle
pRhsaddress of second mc particle

Definition at line 486 of file LArMCParticleHelper.cc.

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

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