CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
SignAlgoResolutions.h
Go to the documentation of this file.
1 #ifndef RECOMET_METALGORITHMS_SIGNALGORESOLUTIONS_H
2 #define RECOMET_METALGORITHMS_SIGNALGORESOLUTIONS_H
3 
4 // -*- C++ -*-
5 //
6 // Package: METAlgorithms
7 // Class: SignAlgoResolutions
8 //
16 //
17 // Original Author: Kyle Story, Freya Blekman (Cornell University)
18 // Created: Fri Apr 18 11:58:33 CEST 2008
19 //
20 //
21 
33 
34 #include <map>
35 #include <iostream>
36 #include <vector>
37 
38 namespace metsig {
39 
47  jet,
49  tau,
58  };
60 
62  public:
65 
67  double eval(const resolutionType &type,
68  const resolutionFunc &func,
69  const double &et,
70  const double &phi,
71  const double &eta,
72  const double &p) const; // for example getvalue(caloHF,ET,et,phi,eta,p);
73  double eval(const resolutionType &type,
74  const resolutionFunc &func,
75  const double &et,
76  const double &phi,
77  const double &eta) const; // for example getvalue(caloHF,ET,et,phi,eta,p);
78  metsig::SigInputObj evalPF(const reco::PFCandidate *candidate) const;
80  bool isFilled() const { return !functionmap_.empty(); }
81 
82  private:
83  double getfunc(const resolutionType &type, const resolutionFunc &func, std::vector<double> &x) const;
84  void addfunction(const resolutionType type, const resolutionFunc func, const std::vector<double> &parameters);
86 
87  typedef std::pair<metsig::resolutionType, metsig::resolutionFunc> functionCombo;
88  typedef std::vector<double> functionPars;
89  std::map<functionCombo, functionPars> functionmap_;
90 
91  double EtFunction(const functionPars &x, const functionPars &par) const;
92  double PhiFunction(const functionPars &x, const functionPars &par) const;
93  double PFunction(const functionPars &x, const functionPars &par) const;
94  double PhiConstFunction(const functionPars &x, const functionPars &par) const;
95  double ElectronPtResolution(const reco::PFCandidate *c) const;
96 
98  //temporary fix for low pT jet resolutions
99  //First index, eta bins, from 0 to 5;
100  //Second index, pt bins, from 3 to 23 GeV;
101  std::vector<double> jdpt[10];
102  std::vector<double> jdphi[10];
103 
107  };
108 } // namespace metsig
109 #endif
const edm::EventSetup & c
double PhiFunction(const functionPars &x, const functionPars &par) const
void addfunction(const resolutionType type, const resolutionFunc func, const std::vector< double > &parameters)
double getfunc(const resolutionType &type, const resolutionFunc &func, std::vector< double > &x) const
Base class for all types of Jets.
Definition: Jet.h:20
metsig::SigInputObj evalPF(const reco::PFCandidate *candidate) const
uint32_t T const *__restrict__ uint32_t const *__restrict__ int32_t int Histo::index_type cudaStream_t Func __host__ __device__ V int Func func
std::vector< double > jdpt[10]
double eval(const resolutionType &type, const resolutionFunc &func, const double &et, const double &phi, const double &eta, const double &p) const
metsig::SigInputObj evalPFJet(const reco::Jet *jet) const
double ElectronPtResolution(const reco::PFCandidate *c) const
std::map< functionCombo, functionPars > functionmap_
double EtFunction(const functionPars &x, const functionPars &par) const
std::vector< double > functionPars
Particle reconstructed by the particle flow algorithm.
Definition: PFCandidate.h:41
void initializeJetResolutions(const edm::ParameterSet &iConfig)
double PhiConstFunction(const functionPars &x, const functionPars &par) const
std::vector< double > jdphi[10]
std::pair< metsig::resolutionType, metsig::resolutionFunc > functionCombo
double PFunction(const functionPars &x, const functionPars &par) const
void addResolutions(const edm::ParameterSet &iConfig)