EnergyKickFeatureTool.h
Go to the documentation of this file.
1 /**
2  * @file larpandoracontent/LArVertex/EnergyKickFeatureTool.h
3  *
4  * @brief Header file for the energy kick feature tool class.
5  *
6  * $Log: $
7  */
8 #ifndef LAR_ENERGY_KICK_FEATURE_TOOL_H
9 #define LAR_ENERGY_KICK_FEATURE_TOOL_H 1
10 
12 
13 namespace lar_content
14 {
15 
16 /**
17  * @brief EnergyKickFeatureTool class
18  */
20 {
21 public:
22  /**
23  * @brief Default constructor
24  */
26 
27  /**
28  * @brief Run the tool
29  *
30  * @param pAlgorithm address of the calling algorithm
31  * @param pVertex address of the vertex
32  * @param slidingFitDataListMap map of the sliding fit data lists
33  *
34  * @return the energy kick feature
35  */
36  void Run(LArMvaHelper::MvaFeatureVector &featureVector, const VertexSelectionBaseAlgorithm *const pAlgorithm, const pandora::Vertex *const pVertex,
39 
40 private:
41  pandora::StatusCode ReadSettings(const pandora::TiXmlHandle xmlHandle);
42 
43  /**
44  * @brief Get the energy kick feature for a given view
45  *
46  * @param vertexPosition2D the projection of the vertex position in this view
47  * @param slidingFitDataList the list of sliding fit data objects in this view
48  *
49  * @return the energy kick feature
50  */
52  const pandora::CartesianVector &vertexPosition2D, const VertexSelectionBaseAlgorithm::SlidingFitDataList &slidingFitDataList) const;
53 
54  /**
55  * @brief Increment the energy kick parameters for a given cluster
56  *
57  * @param pCluster address of the cluster
58  * @param clusterDisplacement the cluster displacement
59  * @param clusterDirection the cluster direction
60  * @param totEnergyKick the total energy kick
61  * @param totEnergy the total energy
62  * @param totHitKick the total hit kick
63  * @param totHits the total number of hits
64  */
65  void IncrementEnergyKickParameters(const pandora::Cluster *const pCluster, const pandora::CartesianVector &clusterDisplacement,
66  const pandora::CartesianVector &clusterDirection, float &totEnergyKick, float &totEnergy, float &totHitKick, unsigned int &totHits) const;
67 
68  float m_rOffset; ///< The r offset parameter in the energy score
69  float m_xOffset; ///< The x offset parameter in the energy score
70 };
71 
72 } // namespace lar_content
73 
74 #endif // #ifndef LAR_ENERGY_KICK_FEATURE_TOOL_H
MvaTypes::MvaFeatureVector MvaFeatureVector
Definition: LArMvaHelper.h:58
void Run(LArMvaHelper::MvaFeatureVector &featureVector, const VertexSelectionBaseAlgorithm *const pAlgorithm, const pandora::Vertex *const pVertex, const VertexSelectionBaseAlgorithm::SlidingFitDataListMap &slidingFitDataListMap, const VertexSelectionBaseAlgorithm::ClusterListMap &, const VertexSelectionBaseAlgorithm::KDTreeMap &, const VertexSelectionBaseAlgorithm::ShowerClusterListMap &, const float, float &)
Run the tool.
void IncrementEnergyKickParameters(const pandora::Cluster *const pCluster, const pandora::CartesianVector &clusterDisplacement, const pandora::CartesianVector &clusterDirection, float &totEnergyKick, float &totEnergy, float &totHitKick, unsigned int &totHits) const
Increment the energy kick parameters for a given cluster.
float m_xOffset
The x offset parameter in the energy score.
float m_rOffset
The r offset parameter in the energy score.
EnergyKickFeatureTool()
Default constructor.
std::map< pandora::HitType, const ShowerClusterList > ShowerClusterListMap
Map of shower cluster lists for passing to tools.
std::map< pandora::HitType, const pandora::ClusterList & > ClusterListMap
Map array of cluster lists for passing to tools.
Header file for the vertex selection base algorithm class.
EnergyKickFeatureTool class.
std::map< pandora::HitType, const SlidingFitDataList > SlidingFitDataListMap
Map of sliding fit data lists for passing to tools.
pandora::StatusCode ReadSettings(const pandora::TiXmlHandle xmlHandle)
float GetEnergyKickForView(const pandora::CartesianVector &vertexPosition2D, const VertexSelectionBaseAlgorithm::SlidingFitDataList &slidingFitDataList) const
Get the energy kick feature for a given view.
boost::graph_traits< ModuleGraph >::vertex_descriptor Vertex
Definition: ModuleGraph.h:25
std::map< pandora::HitType, const std::reference_wrapper< HitKDTree2D > > KDTreeMap
Map array of hit kd trees for passing to tools.
MvaFeatureTool class template.
Definition: LArMvaHelper.h:27