CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Protected Attributes | Private Member Functions | Friends
GBRForest Class Reference

#include <GBRForest.h>

Public Member Functions

 GBRForest ()
 
 GBRForest (const TMVA::MethodBDT *bdt)
 
double GetAdaBoostClassifier (const float *vector) const
 
double GetClassifier (const float *vector) const
 
double GetGradBoostClassifier (const float *vector) const
 
double GetResponse (const float *vector) const
 
void SetInitialResponse (double response)
 
std::vector< GBRTree > & Trees ()
 
const std::vector< GBRTree > & Trees () const
 
virtual ~GBRForest ()
 

Protected Attributes

double fInitialResponse
 
std::vector< GBRTreefTrees
 

Private Member Functions

template<class Archive >
void serialize (Archive &ar, const unsigned int version)
 

Friends

class boost::serialization::access
 
template<typename CondSerializationT , typename Enabled >
struct cond::serialization::access
 

Detailed Description

Definition at line 30 of file GBRForest.h.

Constructor & Destructor Documentation

GBRForest::GBRForest ( )
GBRForest::GBRForest ( const TMVA::MethodBDT *  bdt)
explicit
virtual GBRForest::~GBRForest ( )
virtual

Member Function Documentation

double GBRForest::GetAdaBoostClassifier ( const float *  vector) const
inline

Definition at line 40 of file GBRForest.h.

References GetResponse().

40 { return GetResponse(vector); }
double GetResponse(const float *vector) const
Definition: GBRForest.h:59
double GBRForest::GetClassifier ( const float *  vector) const
inline

Definition at line 43 of file GBRForest.h.

References GetGradBoostClassifier().

Referenced by AntiElectronIDMVA5::MVAValue(), AntiElectronIDMVA6::MVAValue(), MultiTrackSelector::processMVA(), and HIMultiTrackSelector::processMVA().

43 { return GetGradBoostClassifier(vector); }
double GetGradBoostClassifier(const float *vector) const
Definition: GBRForest.h:68
double GBRForest::GetGradBoostClassifier ( const float *  vector) const
inline

Definition at line 68 of file GBRForest.h.

References create_public_lumi_plots::exp, and GetResponse().

Referenced by GetClassifier().

68  {
69  double response = GetResponse(vector);
70  return 2.0/(1.0+exp(-2.0*response))-1; //MVA output between -1 and 1
71 }
double GetResponse(const float *vector) const
Definition: GBRForest.h:59
double GBRForest::GetResponse ( const float *  vector) const
inline

Definition at line 59 of file GBRForest.h.

References fInitialResponse, and fTrees.

Referenced by RegressionHelper::applyCombinationRegression(), EGEnergyCorrector::CorrectedEnergyWithError(), EGEnergyCorrector::CorrectedEnergyWithErrorV3(), PFPhotonAlgo::EvaluateGCorrMVA(), PFPhotonAlgo::EvaluateLCorrMVA(), PFPhotonAlgo::EvaluateResMVA(), GetAdaBoostClassifier(), RegressionHelper::getEcalRegression(), GetGradBoostClassifier(), PFMETAlgorithmMVA::GetResponse(), EGExtraInfoModifierFromDB::modifyObject(), ElectronEnergyRegressionEvaluate::regressionUncertaintyNoTrkVar(), ElectronEnergyRegressionEvaluate::regressionUncertaintyNoTrkVarV1(), ElectronEnergyRegressionEvaluate::regressionUncertaintyWithSubClusters(), ElectronEnergyRegressionEvaluate::regressionUncertaintyWithTrkVar(), ElectronEnergyRegressionEvaluate::regressionUncertaintyWithTrkVarV1(), ElectronEnergyRegressionEvaluate::regressionUncertaintyWithTrkVarV2(), ElectronEnergyRegressionEvaluate::regressionValueNoTrkVar(), ElectronEnergyRegressionEvaluate::regressionValueNoTrkVarV1(), ElectronEnergyRegressionEvaluate::regressionValueWithSubClusters(), ElectronEnergyRegressionEvaluate::regressionValueWithTrkVar(), ElectronEnergyRegressionEvaluate::regressionValueWithTrkVarV1(), and ElectronEnergyRegressionEvaluate::regressionValueWithTrkVarV2().

59  {
60  double response = fInitialResponse;
61  for (std::vector<GBRTree>::const_iterator it=fTrees.begin(); it!=fTrees.end(); ++it) {
62  response += it->GetResponse(vector);
63  }
64  return response;
65 }
double fInitialResponse
Definition: GBRForest.h:51
std::vector< GBRTree > fTrees
Definition: GBRForest.h:52
template<class Archive >
void GBRForest::serialize ( Archive &  ar,
const unsigned int  version 
)
private
void GBRForest::SetInitialResponse ( double  response)
inline

Definition at line 45 of file GBRForest.h.

References fInitialResponse.

45 { fInitialResponse = response; }
double fInitialResponse
Definition: GBRForest.h:51
std::vector<GBRTree>& GBRForest::Trees ( )
inline

Definition at line 47 of file GBRForest.h.

References fTrees.

47 { return fTrees; }
std::vector< GBRTree > fTrees
Definition: GBRForest.h:52
const std::vector<GBRTree>& GBRForest::Trees ( ) const
inline

Definition at line 48 of file GBRForest.h.

References fTrees.

48 { return fTrees; }
std::vector< GBRTree > fTrees
Definition: GBRForest.h:52

Friends And Related Function Documentation

friend class boost::serialization::access
friend

Definition at line 55 of file GBRForest.h.

template<typename CondSerializationT , typename Enabled >
friend struct cond::serialization::access
friend

Definition at line 55 of file GBRForest.h.

Member Data Documentation

double GBRForest::fInitialResponse
protected

Definition at line 51 of file GBRForest.h.

Referenced by GetResponse(), and SetInitialResponse().

std::vector<GBRTree> GBRForest::fTrees
protected

Definition at line 52 of file GBRForest.h.

Referenced by GetResponse(), and Trees().