CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
IsolatorByNominalEfficiency.h
Go to the documentation of this file.
1 #ifndef MuonIsolation_IsolatorByNominalEfficiency_H
2 #define MuonIsolation_IsolatorByNominalEfficiency_H
3 
15 #include <vector>
16 #include <string>
17 
18 namespace muonisolation { class NominalEfficiencyThresholds; }
19 
20 namespace muonisolation {
22  public:
24 
26  IsolatorByNominalEfficiency(const std::string & thrFile,
27  const std::vector<std::string> & ceff,
28  const std::vector<double> & weights);
29 
30  IsolatorByNominalEfficiency(const std::string & thrFile,
31  const std::vector<std::string> & ceff,
32  const std::vector<double> & weights, const std::vector<double> & thresh );
33 
34 
36 
38  virtual Result result(DepositContainer deposits) const;
39 
40  Cuts cuts(float nominalEfficiency) const;
41 
42  private:
43 
44  class ConeSizes {
45  private:
46  enum IsoDim { DIM = 15};
47  static float cone_dr[DIM];
48  public:
49  int dim() const { return DIM;}
50  double size(int i) const;
51  int index(float dr) const;
52  };
53 
54  // Compute the weighted sum of deposits of different type within dRcone
55  virtual double weightedSum(const DepositContainer& deposits, float dRcone) const;
56 
57  // Size of cone for a given nominal efficiency value.
58  int bestConeForEfficiencyIndex(float eff_thr) const;
59 
60  typedef std::multimap<float,int> mapNomEff_Cone;
61  mapNomEff_Cone cones(const std::vector<std::string>& names);
62 
63  std::string findPath(const std::string& fileName);
64 
65  virtual ResultType resultType() const { return ISOL_FLOAT_TYPE;}
66 
67  private:
70  std::vector<double> theWeights;
71  std::vector<double> theDepThresholds;
73  };
74 }
75 
76 #endif
int i
Definition: DBlmapReader.cc:9
virtual Result result(DepositContainer deposits) const
Compute the deposit within the cone and return the isolation result.
MuIsoBaseIsolator::DepositContainer DepositContainer
IsolatorByNominalEfficiency(const std::string &thrFile, const std::vector< std::string > &ceff, const std::vector< double > &weights)
Constructor.
mapNomEff_Cone cones(const std::vector< std::string > &names)
virtual double weightedSum(const DepositContainer &deposits, float dRcone) const
std::vector< DepositAndVetos > DepositContainer
static const HistoName names[]
std::string findPath(const std::string &fileName)