PandaRoot
PndProjectedKNN Class Reference

#include <PndProjectedKNN.h>

Inheritance diagram for PndProjectedKNN:
PndMvaClassifier

Public Member Functions

 PndProjectedKNN (std::string const &inputFile, std::vector< std::string > const &classNames, std::vector< std::string > const &varNames, std::vector< std::vector< std::string >> const &varCombinations)
 Constructor. More...
 
virtual ~PndProjectedKNN ()
 Destructor. More...
 
void GetMvaValues (std::vector< float > eventData, std::map< std::string, float > &result)
 Get pdf's. More...
 
std::string * Classify (std::vector< float > EvtData)
 Classify Current event. More...
 
void SetEvtParam (float const scFact, double const weight)
 Set params. More...
 
void SetKnn (unsigned int const val)
 Set number of neighbors. More...
 
void InitKNN ()
 Init classifiers. More...
 
- Public Member Functions inherited from PndMvaClassifier
 PndMvaClassifier (std::string const &InPut, std::vector< std::string > const &ClassNames, std::vector< std::string > const &VarNames)
 Constructor. More...
 
virtual ~PndMvaClassifier ()
 Destructor. More...
 
virtual void Initialize ()
 
std::vector< PndMvaClass > const & GetClasses () const
 Get the list of available classes (labels). More...
 
std::vector< PndMvaVariable > const & GetVariables () const
 Get the list of available variables. More...
 

Additional Inherited Members

- Protected Member Functions inherited from PndMvaClassifier
virtual void NormalizeEvent (std::vector< float > &EvtVector) const
 Normalize the given event vector. More...
 
void SetAppType (AppType t)
 
- Protected Attributes inherited from PndMvaClassifier
PndMvaDataSet m_dataSets
 Data set. Holds event Weights. More...
 

Detailed Description

Definition at line 16 of file PndProjectedKNN.h.

Constructor & Destructor Documentation

◆ PndProjectedKNN()

PndProjectedKNN::PndProjectedKNN ( std::string const &  inputFile,
std::vector< std::string > const &  classNames,
std::vector< std::string > const &  varNames,
std::vector< std::vector< std::string >> const &  varCombinations 
)
explicit

Constructor.

◆ ~PndProjectedKNN()

virtual PndProjectedKNN::~PndProjectedKNN ( )
virtual

Destructor.

Member Function Documentation

◆ Classify()

std::string* PndProjectedKNN::Classify ( std::vector< float >  EvtData)
virtual

Classify Current event.

Implements PndMvaClassifier.

◆ GetMvaValues()

void PndProjectedKNN::GetMvaValues ( std::vector< float >  eventData,
std::map< std::string, float > &  result 
)
virtual

Get pdf's.

Implements PndMvaClassifier.

◆ InitKNN()

void PndProjectedKNN::InitKNN ( )

Init classifiers.

◆ SetEvtParam()

void PndProjectedKNN::SetEvtParam ( float const  scFact,
double const  weight 
)
inline

Set params.

Definition at line 58 of file PndProjectedKNN.h.

59 {
60  m_ScaleFact = scFact;
61  m_weight = weight;
62 };

◆ SetKnn()

void PndProjectedKNN::SetKnn ( unsigned int const  val)
inline

Set number of neighbors.

Definition at line 64 of file PndProjectedKNN.h.

65 {
66  m_knn = val;
67 };

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