LArSoft
v09_90_00
Liquid Argon Software toolkit - https://larsoft.org/
|
CheatingSliceSelectionTool class. More...
#include "CheatingSliceSelectionTool.h"
Public Types | |
typedef std::map< float, int, std::greater< float > > | MetricSliceIndexMap |
Public Member Functions | |
CheatingSliceSelectionTool () | |
Default constructor. More... | |
void | SelectSlices (const pandora::Algorithm *const pAlgorithm, const SliceVector &inputSliceVector, SliceVector &outputSliceVector) |
Select which slice(s) to use. More... | |
Protected Member Functions | |
virtual bool | IsTarget (const pandora::MCParticle *const mcParticle) const =0 |
Template method to determine if an MC particle matches the target criteria for slice selection. Return true if match. More... | |
pandora::StatusCode | ReadSettings (const pandora::TiXmlHandle xmlHandle) |
Protected Attributes | |
int | m_maxSlices |
The maximum number of slices to retain (0 to retain all) - default 0. More... | |
float | m_threshold |
The minimum cut threshold to retain a slice (< 0 for no threshold) - default -1. More... | |
std::string | m_cutVariable |
The variable to cut on ("purity" or "completeness") - default "completeness". More... | |
CheatingSliceSelectionTool class.
Definition at line 20 of file CheatingSliceSelectionTool.h.
typedef std::map<float, int, std::greater<float> > lar_content::CheatingSliceSelectionTool::MetricSliceIndexMap |
Definition at line 37 of file CheatingSliceSelectionTool.h.
lar_content::CheatingSliceSelectionTool::CheatingSliceSelectionTool | ( | ) |
Default constructor.
Definition at line 20 of file CheatingSliceSelectionTool.cc.
References m_cutVariable, and m_threshold.
|
protectedpure virtual |
Template method to determine if an MC particle matches the target criteria for slice selection. Return true if match.
mcParticle | the MC particle to check |
Implemented in lar_content::CheatingBeamParticleSliceSelectionTool, and lar_content::CheatingNeutrinoSliceSelectionTool.
Referenced by SelectSlices().
|
protected |
Definition at line 125 of file CheatingSliceSelectionTool.cc.
References m_cutVariable, m_maxSlices, and m_threshold.
|
virtual |
Select which slice(s) to use.
pAlgorithm | the address of the master instance, used to access MCParticles when in training mode |
inputSliceVector | the initial slice vector |
outputSliceVector | the output slice vector |
Implements lar_content::SliceSelectionBaseTool.
Definition at line 29 of file CheatingSliceSelectionTool.cc.
References lar_content::LArMCParticleHelper::GetParentMCParticle(), IsTarget(), m_cutVariable, m_maxSlices, m_threshold, lar_content::LArMCParticleHelper::SortByMomentum(), and weight.
|
protected |
The variable to cut on ("purity" or "completeness") - default "completeness".
Definition at line 52 of file CheatingSliceSelectionTool.h.
Referenced by CheatingSliceSelectionTool(), ReadSettings(), and SelectSlices().
|
protected |
The maximum number of slices to retain (0 to retain all) - default 0.
Definition at line 50 of file CheatingSliceSelectionTool.h.
Referenced by ReadSettings(), and SelectSlices().
|
protected |
The minimum cut threshold to retain a slice (< 0 for no threshold) - default -1.
Definition at line 51 of file CheatingSliceSelectionTool.h.
Referenced by CheatingSliceSelectionTool(), ReadSettings(), and SelectSlices().