8 #ifndef LAR_ADABOOST_DECISION_TREE_H
9 #define LAR_ADABOOST_DECISION_TREE_H 1
15 #include "Pandora/StatusCodes.h"
62 pandora::StatusCode
Initialize(
const std::string ¶meterLocation,
const std::string &bdtName);
103 Node(
const pandora::TiXmlHandle *
const pXmlHandle);
311 pandora::StatusCode
ReadComponent(pandora::TiXmlElement *pCurrentXmlElement);
339 return m_parentNodeId;
346 return m_leftChildNodeId;
353 return m_rightChildNodeId;
400 #endif // #ifndef LAR_ADABOOST_DECISION_TREE_H
int m_rightChildNodeId
Right child node id.
WeakClassifiers m_weakClassifiers
Vector of weak classifers.
WeakClassifier & operator=(const WeakClassifier &rhs)
Assignment operator.
int GetLeftChildNodeId() const
Return left child node id.
int GetVariableId() const
Return cut variable.
MvaTypes::MvaFeatureVector MvaFeatureVector
IdToNodeMap m_idToNodeMap
Decision tree nodes.
bool GetOutcome() const
Return outcome.
WeakClassifier(const pandora::TiXmlHandle *const pXmlHandle)
Constructor using xml handle to set member variables.
double GetWeight() const
Get boost weight for weak classifier.
bool Classify(const LArMvaHelper::MvaFeatureVector &features) const
Classify the set of input features based on the trained model.
WeakClassifier class containing a decision tree and a weight.
int m_treeId
Decision tree id.
double m_threshold
Threshold used for decision if decision node.
int GetNodeId() const
Return node id.
double Predict(const LArMvaHelper::MvaFeatureVector &features) const
Predict signal or background based on trained data.
AdaBoostDecisionTree class.
int m_parentNodeId
Parent node id.
double GetThreshold() const
Return node threshold.
bool m_outcome
Outcome if leaf node.
StrongClassifier class used in application of adaptive boost decision tree.
Node & operator=(const Node &rhs)
Assignment operator.
int GetParentNodeId() const
Return parent node id.
bool EvaluateNode(const int nodeId, const LArMvaHelper::MvaFeatureVector &features) const
Evalute node and return outcome.
int m_leftChildNodeId
Left child node id.
~WeakClassifier()
Destructor.
std::vector< const WeakClassifier * > WeakClassifiers
Node class used for representing a decision tree.
std::map< int, const Node * > IdToNodeMap
Node(const pandora::TiXmlHandle *const pXmlHandle)
Constructor using xml handle to set member variables.
double CalculateProbability(const LArMvaHelper::MvaFeatureVector &features) const
Calculate the classification probability for a set of input features, based on the trained model...
pandora::StatusCode ReadComponent(pandora::TiXmlElement *pCurrentXmlElement)
Read xml element and if weak classifier add to member variables.
StrongClassifier(const pandora::TiXmlHandle *const pXmlHandle)
Constructor using xml handle to set member variables.
int GetRightChildNodeId() const
Return right child node id.
~AdaBoostDecisionTree()
Destructor.
AdaBoostDecisionTree()
Constructor.
int GetTreeId() const
Get tree id for weak classifier.
double m_weight
Boost weight.
double CalculateClassificationScore(const LArMvaHelper::MvaFeatureVector &features) const
Calculate the classification score for a set of input features, based on the trained model...
pandora::StatusCode Initialize(const std::string ¶meterLocation, const std::string &bdtName)
Initialize the bdt model.
AdaBoostDecisionTree & operator=(const AdaBoostDecisionTree &rhs)
Assignment operator.
double CalculateScore(const LArMvaHelper::MvaFeatureVector &features) const
Calculate score for input features using strong classifier.
StrongClassifier & operator=(const StrongClassifier &rhs)
Assignment operator.
StrongClassifier * m_pStrongClassifier
Strong adaptive boost tree classifier.
bool Predict(const LArMvaHelper::MvaFeatureVector &features) const
Predict signal or background based on trained data.
Header file for the lar multivariate analysis interface class.
int m_variableId
Variable cut on for decision if decision node.
bool IsLeaf() const
Return is the node a leaf.
bool m_isLeaf
Is node a leaf.
~StrongClassifier()
Destructor.