MasterAlgorithm class. More...
#include <MasterAlgorithm.h>
Classes | |
| class | ExternalSteeringParameters |
| External steering parameters class. More... | |
| class | LArTPCHitList |
| LArTPCHitList class. More... | |
Public Types | |
| typedef std::unordered_map < const pandora::ParticleFlowObject *, const pandora::LArTPC * > | PfoToLArTPCMap |
Public Member Functions | |
| MasterAlgorithm () | |
| Default constructor. More... | |
| void | ShiftPfoHierarchy (const pandora::ParticleFlowObject *const pParentPfo, const PfoToLArTPCMap &pfoToLArTPCMap, const float x0) const |
| Shift a Pfo hierarchy by a specified x0 value. More... | |
| void | StitchPfos (const pandora::ParticleFlowObject *const pPfoToEnlarge, const pandora::ParticleFlowObject *const pPfoToDelete, PfoToLArTPCMap &pfoToLArTPCMap) const |
| Stitch together a pair of pfos. More... | |
Protected Types | |
| typedef std::map< unsigned int, LArTPCHitList > | VolumeIdToHitListMap |
| typedef std::vector < StitchingBaseTool * > | StitchingToolVector |
| typedef std::vector < CosmicRayTaggingBaseTool * > | CosmicRayTaggingToolVector |
| typedef std::vector < SliceIdBaseTool * > | SliceIdToolVector |
| typedef std::vector < SliceSelectionBaseTool * > | SliceSelectionToolVector |
Protected Member Functions | |
| pandora::StatusCode | Run () |
| pandora::StatusCode | InitializeWorkerInstances () |
| Initialize pandora worker instances. More... | |
| pandora::StatusCode | CopyMCParticles () const |
| Copy mc particles in the named input list to all pandora worker instances. More... | |
| pandora::StatusCode | GetVolumeIdToHitListMap (VolumeIdToHitListMap &volumeIdToHitListMap) const |
| Get the mapping from lar tpc volume id to lists of all hits, and truncated hits. More... | |
| pandora::StatusCode | RunCosmicRayReconstruction (const VolumeIdToHitListMap &volumeIdToHitListMap) const |
| Run the cosmic-ray reconstruction worker instances. More... | |
| pandora::StatusCode | RecreateCosmicRayPfos (PfoToLArTPCMap &pfoToLArTPCMap) const |
| Recreate cosmic-ray pfos (created by worker instances) in the master instance. More... | |
| pandora::StatusCode | StitchCosmicRayPfos (PfoToLArTPCMap &pfoToLArTPCMap, PfoToFloatMap &stitchedPfosToX0Map) const |
| Stitch together cosmic-ray pfos crossing between adjacent lar tpcs. More... | |
| pandora::StatusCode | TagCosmicRayPfos (const PfoToFloatMap &stitchedPfosToX0Map, pandora::PfoList &clearCosmicRayPfos, pandora::PfoList &ambiguousPfos) const |
| Tag clear, unambiguous cosmic-ray pfos. More... | |
| pandora::StatusCode | RunCosmicRayHitRemoval (const pandora::PfoList &ambiguousPfos) const |
| Run cosmic-ray hit removal, freeing hits in ambiguous pfos for further processing. More... | |
| pandora::StatusCode | RunSlicing (const VolumeIdToHitListMap &volumeIdToHitListMap, SliceVector &sliceVector) const |
| Run the event slicing procedures, dividing available hits up into distinct 3D regions. More... | |
| pandora::StatusCode | RunSliceReconstruction (SliceVector &sliceVector, SliceHypotheses &nuSliceHypotheses, SliceHypotheses &crSliceHypotheses) const |
| Process each slice under different reconstruction hypotheses. More... | |
| pandora::StatusCode | SelectBestSliceHypotheses (const SliceHypotheses &nuSliceHypotheses, const SliceHypotheses &crSliceHypotheses) const |
| Examine slice hypotheses to identify the most appropriate to provide in final event output. More... | |
| pandora::StatusCode | Reset () |
| Reset all worker instances. More... | |
| pandora::StatusCode | Copy (const pandora::Pandora *const pPandora, const pandora::CaloHit *const pCaloHit) const |
| Copy a specified calo hit to the provided pandora instance. More... | |
| pandora::StatusCode | Copy (const pandora::Pandora *const pPandora, const pandora::MCParticle *const pMCParticle, const LArMCParticleFactory *const pMCParticleFactory) const |
| Copy a specified mc particle to the provided pandora instance. More... | |
| pandora::StatusCode | Recreate (const pandora::PfoList &inputPfoList, pandora::PfoList &newPfoList) const |
| Recreate a specified list of pfos in the current pandora instance. More... | |
| pandora::StatusCode | Recreate (const pandora::ParticleFlowObject *const pInputPfo, const pandora::ParticleFlowObject *const pNewParentPfo, pandora::PfoList &newPfoList) const |
| Recreate a specified pfo in the current pandora instance. More... | |
| const pandora::CaloHit * | CreateCaloHit (const pandora::CaloHit *const pInputCaloHit, const pandora::CaloHit *const pParentCaloHit) const |
| Create a new calo hit in the current pandora instance, based upon the provided input calo hit. More... | |
| const pandora::Cluster * | CreateCluster (const pandora::Cluster *const pInputCluster, const pandora::CaloHitList &newCaloHitList, const pandora::CaloHitList &newIsolatedCaloHitList) const |
| Create a new cluster in the current pandora instance, based upon the provided input cluster. More... | |
| const pandora::Vertex * | CreateVertex (const pandora::Vertex *const pInputVertex) const |
| Create a new vertex in the current pandora instance, based upon the provided input vertex. More... | |
| const pandora::ParticleFlowObject * | CreatePfo (const pandora::ParticleFlowObject *const pInputPfo, const pandora::ClusterList &newClusterList, const pandora::VertexList &newVertexList) const |
| Create a new pfo in the current pandora instance, based upon the provided input pfo. More... | |
| const pandora::Pandora * | CreateWorkerInstance (const pandora::LArTPC &larTPC, const pandora::DetectorGapList &gapList, const std::string &settingsFile, const std::string &name) const |
| Create a pandora worker instance to handle a single LArTPC. More... | |
| const pandora::Pandora * | CreateWorkerInstance (const pandora::LArTPCMap &larTPCMap, const pandora::DetectorGapList &gapList, const std::string &settingsFile, const std::string &name) const |
| Create a pandora worker instance to handle a number of LArTPCs. More... | |
| virtual pandora::StatusCode | RegisterCustomContent (const pandora::Pandora *const pPandora) const |
| Register custom content, such as algorithms or algorithm tools, with a specified pandora instance. More... | |
| pandora::StatusCode | ReadSettings (const pandora::TiXmlHandle xmlHandle) |
| pandora::StatusCode | ReadExternalSettings (const ExternalSteeringParameters *const pExternalParameters, const pandora::InputBool inputBool, const pandora::TiXmlHandle xmlHandle, const std::string &xmlTag, bool &outputBool) |
| Read settings from external steering parameters block, if present, otherwise from xml as standard. More... | |
Protected Attributes | |
| bool | m_workerInstancesInitialized |
| Whether all worker instances have been initialized. More... | |
| unsigned int | m_larCaloHitVersion |
| The LArCaloHit version for LArCaloHitFactory. More... | |
| bool | m_shouldRunAllHitsCosmicReco |
| Whether to run all hits cosmic-ray reconstruction. More... | |
| bool | m_shouldRunStitching |
| Whether to stitch cosmic-ray muons crossing between volumes. More... | |
| bool | m_shouldRunCosmicHitRemoval |
| Whether to remove hits from tagged cosmic-rays. More... | |
| bool | m_shouldRunSlicing |
| Whether to slice events into separate regions for processing. More... | |
| bool | m_shouldRunNeutrinoRecoOption |
| Whether to run neutrino reconstruction for each slice. More... | |
| bool | m_shouldRunCosmicRecoOption |
| Whether to run cosmic-ray reconstruction for each slice. More... | |
| bool | m_shouldPerformSliceId |
| Whether to identify slices and select most appropriate pfos. More... | |
| bool | m_printOverallRecoStatus |
| Whether to print current operation status messages. More... | |
| bool | m_visualizeOverallRecoStatus |
| Whether to display results of current operations. More... | |
| bool | m_shouldRemoveOutOfTimeHits |
| Whether to remove out of time hits. More... | |
| PandoraInstanceList | m_crWorkerInstances |
| The list of cosmic-ray reconstruction worker instances. More... | |
| const pandora::Pandora * | m_pSlicingWorkerInstance |
| The slicing worker instance. More... | |
| const pandora::Pandora * | m_pSliceNuWorkerInstance |
| The per-slice neutrino reconstruction worker instance. More... | |
| const pandora::Pandora * | m_pSliceCRWorkerInstance |
| The per-slice cosmic-ray reconstruction worker instance. More... | |
| bool | m_fullWidthCRWorkerWireGaps |
| Whether wire-type line gaps in cosmic-ray worker instances should cover all drift time. More... | |
| bool | m_passMCParticlesToWorkerInstances |
| Whether to pass mc particle details (and links to calo hits) to worker instances. More... | |
| StitchingToolVector | m_stitchingToolVector |
| The stitching tool vector. More... | |
| CosmicRayTaggingToolVector | m_cosmicRayTaggingToolVector |
| The cosmic-ray tagging tool vector. More... | |
| SliceIdToolVector | m_sliceIdToolVector |
| The slice id tool vector. More... | |
| SliceSelectionToolVector | m_sliceSelectionToolVector |
| The slice selection tool vector. More... | |
| std::string | m_filePathEnvironmentVariable |
| The environment variable providing a list of paths to xml files. More... | |
| std::string | m_crSettingsFile |
| The cosmic-ray reconstruction settings file. More... | |
| std::string | m_nuSettingsFile |
| The neutrino reconstruction settings file. More... | |
| std::string | m_slicingSettingsFile |
| The slicing settings file. More... | |
| std::string | m_inputMCParticleListName |
| The input mc particle list name. More... | |
| std::string | m_inputHitListName |
| The input hit list name. More... | |
| std::string | m_recreatedPfoListName |
| The output recreated pfo list name. More... | |
| std::string | m_recreatedClusterListName |
| The output recreated cluster list name. More... | |
| std::string | m_recreatedVertexListName |
| The output recreated vertex list name. More... | |
| float | m_inTimeMaxX0 |
| Cut on X0 to determine whether particle is clear cosmic ray. More... | |
| LArCaloHitFactory | m_larCaloHitFactory |
| Factory for creating LArCaloHits during hit copying. More... | |
MasterAlgorithm class.
Definition at line 38 of file MasterAlgorithm.h.
|
protected |
Definition at line 334 of file MasterAlgorithm.h.
| typedef std::unordered_map<const pandora::ParticleFlowObject *, const pandora::LArTPC *> lar_content::MasterAlgorithm::PfoToLArTPCMap |
Definition at line 62 of file MasterAlgorithm.h.
|
protected |
Definition at line 335 of file MasterAlgorithm.h.
|
protected |
Definition at line 336 of file MasterAlgorithm.h.
|
protected |
Definition at line 333 of file MasterAlgorithm.h.
|
protected |
Definition at line 94 of file MasterAlgorithm.h.
| lar_content::MasterAlgorithm::MasterAlgorithm | ( | ) |
Default constructor.
Definition at line 35 of file MasterAlgorithm.cc.
|
protected |
Copy a specified calo hit to the provided pandora instance.
| pPandora | the address of the target pandora instance |
| pCaloHit | the address of the calo hit |
|
protected |
Copy a specified mc particle to the provided pandora instance.
| pPandora | the address of the target pandora instance |
| pMCParticle | the address of the mc particle |
| pMCParticleFactory | the address of the mc particle factory, allowing decoration of instances with information beyond that expected by sdk |
|
protected |
Copy mc particles in the named input list to all pandora worker instances.
Definition at line 239 of file MasterAlgorithm.cc.
|
protected |
Create a new calo hit in the current pandora instance, based upon the provided input calo hit.
| pInputCaloHit | the address of the input calo hit |
| pParentCaloHit | the address of the parent calo hit |
Definition at line 814 of file MasterAlgorithm.cc.
|
protected |
Create a new cluster in the current pandora instance, based upon the provided input cluster.
| pInputCluster | the address of the input cluster |
| newCaloHitList | the list of calo hits for the new cluster |
| newIsolatedCaloHitList | the list of isolated calo hits for the new cluster |
Definition at line 851 of file MasterAlgorithm.cc.
|
protected |
Create a new pfo in the current pandora instance, based upon the provided input pfo.
| pInputPfo | the address of the input pfo |
| newClusterList | the list of clusters for the new pfo |
| newVertexList | the list of vertices for the new pfo |
Definition at line 885 of file MasterAlgorithm.cc.
|
protected |
Create a new vertex in the current pandora instance, based upon the provided input vertex.
| pInputVertex | the address of the input vertex |
Definition at line 870 of file MasterAlgorithm.cc.
|
protected |
Create a pandora worker instance to handle a single LArTPC.
| larTPC | the lar tpc |
| gapList | the gap list |
| settingsFile | the pandora settings file |
| name | the pandora instance name |
|
protected |
Create a pandora worker instance to handle a number of LArTPCs.
| larTPCMap | the lar tpc map |
| gapList | the gap list |
| settingsFile | the pandora settings file |
| name | the pandora instance name |
|
protected |
Get the mapping from lar tpc volume id to lists of all hits, and truncated hits.
| volumeIdToHitListMap | to receive the populated volume id to hit list map |
Definition at line 265 of file MasterAlgorithm.cc.
|
protected |
Initialize pandora worker instances.
Definition at line 200 of file MasterAlgorithm.cc.
|
protected |
Read settings from external steering parameters block, if present, otherwise from xml as standard.
| pExternalParameters | the address of the external parameters (if present) |
| inputBool | the input boolean value, from the external parameters (if present) |
| xmlHandle | the xml handle |
| xmlTag | the xml tag |
| outputBool | to receive the output boolean value |
Definition at line 1223 of file MasterAlgorithm.cc.
|
protected |
Definition at line 1063 of file MasterAlgorithm.cc.
|
protected |
Recreate a specified list of pfos in the current pandora instance.
| inputPfoList | the input pfo list |
| newPfoList | to receive the list of new pfos |
|
protected |
Recreate a specified pfo in the current pandora instance.
| pInputPfo | the input pfo |
| pNewParentPfo | the new parent of the new output pfo (nullptr if none) |
| newPfoList | to receive the list of new pfos |
|
protected |
Recreate cosmic-ray pfos (created by worker instances) in the master instance.
| pfoToLArTPCMap | to receive the populated pfo to lar tpc map |
Definition at line 324 of file MasterAlgorithm.cc.
|
protectedvirtual |
Register custom content, such as algorithms or algorithm tools, with a specified pandora instance.
| pPandora | the address of the pandora instance |
Reimplemented in lar_dl_content::DLMasterAlgorithm.
Definition at line 1056 of file MasterAlgorithm.cc.
|
protected |
Reset all worker instances.
Definition at line 628 of file MasterAlgorithm.cc.
|
protected |
Definition at line 153 of file MasterAlgorithm.cc.
|
protected |
Run cosmic-ray hit removal, freeing hits in ambiguous pfos for further processing.
| ambiguousPfos | the list of ambiguous cosmic-ray pfos |
Definition at line 418 of file MasterAlgorithm.cc.
|
protected |
Run the cosmic-ray reconstruction worker instances.
| volumeIdToHitListMap | the volume id to hit list map |
Definition at line 298 of file MasterAlgorithm.cc.
|
protected |
Process each slice under different reconstruction hypotheses.
| sliceVector | the slice vector |
| nuSliceHypotheses | to receive the vector of slice neutrino hypotheses |
| crSliceHypotheses | to receive the vector of slice cosmic-ray hypotheses |
Definition at line 515 of file MasterAlgorithm.cc.
|
protected |
Run the event slicing procedures, dividing available hits up into distinct 3D regions.
| volumeIdToHitListMap | the volume id to hit list map |
| sliceVector | to receive the populated slice vector |
Definition at line 457 of file MasterAlgorithm.cc.
|
protected |
Examine slice hypotheses to identify the most appropriate to provide in final event output.
| nuSliceHypotheses | the vector of slice neutrino hypotheses |
| crSliceHypotheses | the vector of slice cosmic-ray hypotheses |
Definition at line 600 of file MasterAlgorithm.cc.
| void lar_content::MasterAlgorithm::ShiftPfoHierarchy | ( | const pandora::ParticleFlowObject *const | pParentPfo, |
| const PfoToLArTPCMap & | pfoToLArTPCMap, | ||
| const float | x0 | ||
| ) | const |
Shift a Pfo hierarchy by a specified x0 value.
| pPfo | the address of the parent pfo |
| stitchingInfo | the source for additional, local, stitching information |
| x0 | the x0 correction relative to the input pfo |
Definition at line 60 of file MasterAlgorithm.cc.
|
protected |
Stitch together cosmic-ray pfos crossing between adjacent lar tpcs.
| pfoToLArTPCMap | the pfo to lar tpc map |
| stitchedPfosToX0Map | to receive the map of cosmic-ray pfos that have been stitched between lar tpcs to the X0 shift |
Definition at line 345 of file MasterAlgorithm.cc.
| void lar_content::MasterAlgorithm::StitchPfos | ( | const pandora::ParticleFlowObject *const | pPfoToEnlarge, |
| const pandora::ParticleFlowObject *const | pPfoToDelete, | ||
| PfoToLArTPCMap & | pfoToLArTPCMap | ||
| ) | const |
Stitch together a pair of pfos.
| pPfoToEnlarge | the address of the pfo to enlarge |
| pPfoToDelete | the address of the pfo to delete (will become a dangling pointer) |
| stitchingInfo | the source for additional, local, stitching information |
Definition at line 112 of file MasterAlgorithm.cc.
|
protected |
Tag clear, unambiguous cosmic-ray pfos.
| stitchedPfosToX0Map | a map of cosmic-ray pfos that have been stitched between lar tpcs to the X0 shift |
| clearCosmicRayPfos | to receive the list of clear cosmic-ray pfos |
| ambiguousPfos | to receive the list of ambiguous cosmic-ray pfos for further analysis |
Definition at line 370 of file MasterAlgorithm.cc.
|
protected |
The cosmic-ray tagging tool vector.
Definition at line 339 of file MasterAlgorithm.h.
|
protected |
The cosmic-ray reconstruction settings file.
Definition at line 344 of file MasterAlgorithm.h.
|
protected |
The list of cosmic-ray reconstruction worker instances.
Definition at line 325 of file MasterAlgorithm.h.
|
protected |
The environment variable providing a list of paths to xml files.
Definition at line 343 of file MasterAlgorithm.h.
|
protected |
Whether wire-type line gaps in cosmic-ray worker instances should cover all drift time.
Definition at line 330 of file MasterAlgorithm.h.
|
protected |
The input hit list name.
Definition at line 349 of file MasterAlgorithm.h.
|
protected |
The input mc particle list name.
Definition at line 348 of file MasterAlgorithm.h.
|
protected |
Cut on X0 to determine whether particle is clear cosmic ray.
Definition at line 354 of file MasterAlgorithm.h.
|
protected |
Factory for creating LArCaloHits during hit copying.
Definition at line 355 of file MasterAlgorithm.h.
|
protected |
The LArCaloHit version for LArCaloHitFactory.
Definition at line 312 of file MasterAlgorithm.h.
|
protected |
The neutrino reconstruction settings file.
Definition at line 345 of file MasterAlgorithm.h.
|
protected |
Whether to pass mc particle details (and links to calo hits) to worker instances.
Definition at line 331 of file MasterAlgorithm.h.
|
protected |
Whether to print current operation status messages.
Definition at line 321 of file MasterAlgorithm.h.
|
protected |
The per-slice cosmic-ray reconstruction worker instance.
Definition at line 328 of file MasterAlgorithm.h.
|
protected |
The per-slice neutrino reconstruction worker instance.
Definition at line 327 of file MasterAlgorithm.h.
|
protected |
The slicing worker instance.
Definition at line 326 of file MasterAlgorithm.h.
|
protected |
The output recreated cluster list name.
Definition at line 351 of file MasterAlgorithm.h.
|
protected |
The output recreated pfo list name.
Definition at line 350 of file MasterAlgorithm.h.
|
protected |
The output recreated vertex list name.
Definition at line 352 of file MasterAlgorithm.h.
|
protected |
Whether to identify slices and select most appropriate pfos.
Definition at line 320 of file MasterAlgorithm.h.
|
protected |
Whether to remove out of time hits.
Definition at line 323 of file MasterAlgorithm.h.
|
protected |
Whether to run all hits cosmic-ray reconstruction.
Definition at line 314 of file MasterAlgorithm.h.
|
protected |
Whether to remove hits from tagged cosmic-rays.
Definition at line 316 of file MasterAlgorithm.h.
|
protected |
Whether to run cosmic-ray reconstruction for each slice.
Definition at line 319 of file MasterAlgorithm.h.
|
protected |
Whether to run neutrino reconstruction for each slice.
Definition at line 318 of file MasterAlgorithm.h.
|
protected |
Whether to slice events into separate regions for processing.
Definition at line 317 of file MasterAlgorithm.h.
|
protected |
Whether to stitch cosmic-ray muons crossing between volumes.
Definition at line 315 of file MasterAlgorithm.h.
|
protected |
The slice id tool vector.
Definition at line 340 of file MasterAlgorithm.h.
|
protected |
The slice selection tool vector.
Definition at line 341 of file MasterAlgorithm.h.
|
protected |
The slicing settings file.
Definition at line 346 of file MasterAlgorithm.h.
|
protected |
The stitching tool vector.
Definition at line 338 of file MasterAlgorithm.h.
|
protected |
Whether to display results of current operations.
Definition at line 322 of file MasterAlgorithm.h.
|
protected |
Whether all worker instances have been initialized.
Definition at line 310 of file MasterAlgorithm.h.
1.8.5