CMS 3D CMS Logo

PhotonMVAEstimator.h
Go to the documentation of this file.
1 #ifndef RecoEgamma_PhotonIdentification_PhotonMVAEstimator_H
2 #define RecoEgamma_PhotonIdentification_PhotonMVAEstimator_H
3 
13 
15 
16  public:
17 
18  // Constructor and destructor
20  ~PhotonMVAEstimator() override {};
21 
22  // Calculation of the MVA value
23  float mvaValue( const reco::Candidate* candPtr, std::vector<float> const& auxVars, int &iCategory) const override;
24 
25  int findCategory( const reco::Candidate* candPtr) const override;
26 
27  static void fillDescriptions(edm::ConfigurationDescriptions& descriptions);
28 
29  private:
30 
31  int findCategory(reco::Photon const& photon) const;
32 
33  // The number of categories and number of variables per category
35  std::vector<ThreadSafeStringCut<StringCutObjectSelector<reco::Photon>,reco::Photon>> categoryFunctions_;
36  std::vector<int> nVariables_;
37 
38  // Data members
39  std::vector< std::unique_ptr<const GBRForest> > gbrForests_;
40 
41  // There might be different variables for each category, so the variables
42  // names vector is itself a vector of length nCategories
43  std::vector<std::vector<int>> variables_;
44 
45  // The variable manager which stores how to obtain the variables
47 
48  // Other objects needed by the MVA
49  std::unique_ptr<EffectiveAreas> effectiveAreas_;
50  std::vector<double> phoIsoPtScalingCoeff_;
51  double phoIsoCutoff_;
52 
53 };
54 
55 #endif
float mvaValue(const reco::Candidate *candPtr, std::vector< float > const &auxVars, int &iCategory) const override
PhotonMVAEstimator(const edm::ParameterSet &conf)
MVAVariableManager< reco::Photon > mvaVarMngr_
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
std::vector< std::unique_ptr< const GBRForest > > gbrForests_
std::vector< int > nVariables_
std::vector< double > phoIsoPtScalingCoeff_
std::unique_ptr< EffectiveAreas > effectiveAreas_
std::vector< std::vector< int > > variables_
~PhotonMVAEstimator() override
std::vector< ThreadSafeStringCut< StringCutObjectSelector< reco::Photon >, reco::Photon > > categoryFunctions_
int findCategory(const reco::Candidate *candPtr) const override