CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
GlobalScales.h
Go to the documentation of this file.
1 #ifndef L1TGlobalScales_h
2 #define L1TGlobalScales_h
3 
15 // system include files
16 #include <vector>
17 #include <string>
18 #include <map>
19 #include <iosfwd>
20 
21 // class declaration
22 
23 namespace l1t {
24 
26 {
27 
28 public:
29 
30  // constructors
31  GlobalScales();
32 
33  // destructor
34  virtual ~GlobalScales();
35 
36 public:
37 
40  {
41  double etMin;
42  double etMax;
43  double etStep;
44  std::vector<std::pair<double,double>> etBins;
45 
46  double phiMin;
47  double phiMax;
48  double phiStep;
49  std::vector<std::pair<double,double>> phiBins;
50 
51  double etaMin;
52  double etaMax;
53  double etaStep;
54  std::vector<std::pair<double,double>> etaBins;
55 
56  };
57 
58  inline void setEGScales(ScaleParameters& scales) { m_egScales = scales; }
59  inline void setTauScales(ScaleParameters& scales) { m_tauScales = scales; }
60  inline void setMuonScales(ScaleParameters& scales) { m_muScales = scales; }
61 
62  inline void setJetScales(ScaleParameters& scales) { m_jetScales = scales; }
63 
64  inline void setETTScales(ScaleParameters& scales) { m_ettScales = scales; }
65  inline void setETTEmScales(ScaleParameters& scales) { m_ettEmScales = scales; }
66  inline void setHTTScales(ScaleParameters& scales) { m_httScales = scales; }
67  inline void setETMScales(ScaleParameters& scales) { m_etmScales = scales; }
68  inline void setETMHfScales(ScaleParameters& scales) { m_etmHfScales = scales; }
69  inline void setHTMScales(ScaleParameters& scales) { m_htmScales = scales; }
70 
71  virtual void setLUT_CalMuEta(std::string lutName, std::vector<long long> lut);
72  virtual void setLUT_CalMuPhi(std::string lutName, std::vector<long long> lut);
73  virtual void setLUT_DeltaEta(std::string lutName, std::vector<long long> lut, unsigned int precision);
74  virtual void setLUT_DeltaPhi(std::string lutName, std::vector<long long> lut, unsigned int precision);
75  virtual void setLUT_Pt(std::string lutName, std::vector<long long> lut, unsigned int precision);
76  virtual void setLUT_Cosh(std::string lutName, std::vector<long long> lut, unsigned int precision);
77  virtual void setLUT_Cos(std::string lutName, std::vector<long long> lut, unsigned int precision);
78 
80  virtual std::string getScalesName() const;
81 
82  inline ScaleParameters getMUScales() const { return m_muScales; }
83  inline ScaleParameters getEGScales() const { return m_egScales; }
84  inline ScaleParameters getTAUScales() const { return m_tauScales; }
85  inline ScaleParameters getJETScales() const { return m_jetScales; }
86  inline ScaleParameters getETTScales() const { return m_ettScales; }
87  inline ScaleParameters getETTEmScales() const { return m_ettEmScales; }
88  inline ScaleParameters getETMScales() const { return m_etmScales; }
89  inline ScaleParameters getETMHFScales() const { return m_etmHfScales; }
90  inline ScaleParameters getHTTScales() const { return m_httScales; }
91  inline ScaleParameters getHTMScales() const { return m_htmScales; }
92 
93 
94  long long getLUT_CalMuEta(std::string lutName, int element) const;
95  long long getLUT_CalMuPhi(std::string lutName, int element) const;
96  long long getLUT_DeltaEta(std::string lutName, int element) const;
97  long long getLUT_DeltaPhi(std::string lutName, int element) const;
98  long long getLUT_Pt(std::string lutName, int element) const;
99  long long getLUT_Cosh(std::string lutName, int element) const;
100  long long getLUT_Cos(std::string lutName, int element) const;
101 
102  unsigned int getPrec_DeltaEta(std::string lutName) const;
103  unsigned int getPrec_DeltaPhi(std::string lutName) const;
104  unsigned int getPrec_Pt(std::string lutName) const;
105  unsigned int getPrec_Cosh(std::string lutName) const;
106  unsigned int getPrec_Cos(std::string lutName) const;
107 
108 
109  virtual void dumpAllLUTs(std::ostream& myCout) const;
110  virtual void dumpLUT(std::ostream& myCout, int LUTtype, std::string name) const;
111  virtual void print(std::ostream& myCout) const;
112  virtual void printScale(ScaleParameters scale, std::ostream& myCout) const;
113 
114 private:
115 
116 
117 private:
118 
119 
121 
125 
127 
134 
135  //LUTs
136  std::map<std::string, std::vector<long long> > m_lut_CalMuEta;
137  std::map<std::string, std::vector<long long> > m_lut_CalMuPhi;
138  std::map<std::string, std::vector<long long> > m_lut_DeltaEta;
139  std::map<std::string, std::vector<long long> > m_lut_DeltaPhi;
140  std::map<std::string, std::vector<long long> > m_lut_Pt;
141  std::map<std::string, std::vector<long long> > m_lut_Cosh;
142  std::map<std::string, std::vector<long long> > m_lut_Cos;
143 
144  //LUTs Precision
145  std::map<std::string, unsigned int > m_Prec_DeltaEta;
146  std::map<std::string, unsigned int > m_Prec_DeltaPhi;
147  std::map<std::string, unsigned int > m_Prec_Pt;
148  std::map<std::string, unsigned int > m_Prec_Cosh;
149  std::map<std::string, unsigned int > m_Prec_Cos;
150 
151 };
152 
153 }
154 #endif
ScaleParameters getMUScales() const
Definition: GlobalScales.h:82
std::map< std::string, unsigned int > m_Prec_Pt
Definition: GlobalScales.h:147
virtual void setLUT_DeltaEta(std::string lutName, std::vector< long long > lut, unsigned int precision)
Definition: GlobalScales.cc:71
void setETMScales(ScaleParameters &scales)
Definition: GlobalScales.h:67
void setJetScales(ScaleParameters &scales)
Definition: GlobalScales.h:62
ScaleParameters m_ettScales
Definition: GlobalScales.h:128
ScaleParameters getETMScales() const
Definition: GlobalScales.h:88
std::map< std::string, std::vector< long long > > m_lut_DeltaPhi
Definition: GlobalScales.h:139
ScaleParameters m_tauScales
Definition: GlobalScales.h:123
ScaleParameters m_jetScales
Definition: GlobalScales.h:126
std::map< std::string, unsigned int > m_Prec_Cosh
Definition: GlobalScales.h:148
std::vector< std::pair< double, double > > etaBins
Definition: GlobalScales.h:54
virtual ~GlobalScales()
Definition: GlobalScales.cc:32
std::map< std::string, std::vector< long long > > m_lut_CalMuPhi
Definition: GlobalScales.h:137
unsigned int getPrec_Pt(std::string lutName) const
std::vector< std::pair< double, double > > phiBins
Definition: GlobalScales.h:49
virtual void setLUT_CalMuPhi(std::string lutName, std::vector< long long > lut)
Definition: GlobalScales.cc:55
std::string m_ScaleSetName
Definition: GlobalScales.h:120
long long getLUT_Cos(std::string lutName, int element) const
ScaleParameters getJETScales() const
Definition: GlobalScales.h:85
ScaleParameters getEGScales() const
Definition: GlobalScales.h:83
ScaleParameters getHTMScales() const
Definition: GlobalScales.h:91
unsigned int getPrec_Cosh(std::string lutName) const
long long getLUT_DeltaEta(std::string lutName, int element) const
std::map< std::string, unsigned int > m_Prec_Cos
Definition: GlobalScales.h:149
ScaleParameters m_etmScales
Definition: GlobalScales.h:131
virtual void setLUT_Cosh(std::string lutName, std::vector< long long > lut, unsigned int precision)
void setETMHfScales(ScaleParameters &scales)
Definition: GlobalScales.h:68
ScaleParameters m_egScales
Definition: GlobalScales.h:122
std::map< std::string, unsigned int > m_Prec_DeltaEta
Definition: GlobalScales.h:145
virtual void dumpAllLUTs(std::ostream &myCout) const
ScaleParameters m_ettEmScales
Definition: GlobalScales.h:129
ScaleParameters getTAUScales() const
Definition: GlobalScales.h:84
long long getLUT_Pt(std::string lutName, int element) const
ScaleParameters m_htmScales
Definition: GlobalScales.h:133
unsigned int getPrec_DeltaEta(std::string lutName) const
long long getLUT_Cosh(std::string lutName, int element) const
void setScalesName(std::string name)
Definition: GlobalScales.h:79
ScaleParameters m_etmHfScales
Definition: GlobalScales.h:132
long long getLUT_CalMuEta(std::string lutName, int element) const
void setEGScales(ScaleParameters &scales)
Definition: GlobalScales.h:58
void setTauScales(ScaleParameters &scales)
Definition: GlobalScales.h:59
virtual void print(std::ostream &myCout) const
std::map< std::string, std::vector< long long > > m_lut_Pt
Definition: GlobalScales.h:140
unsigned int getPrec_DeltaPhi(std::string lutName) const
virtual void setLUT_Cos(std::string lutName, std::vector< long long > lut, unsigned int precision)
void setETTEmScales(ScaleParameters &scales)
Definition: GlobalScales.h:65
tuple lut
Definition: lumiPlot.py:244
ScaleParameters getETTScales() const
Definition: GlobalScales.h:86
virtual void setLUT_CalMuEta(std::string lutName, std::vector< long long > lut)
Definition: GlobalScales.cc:39
ScaleParameters m_httScales
Definition: GlobalScales.h:130
virtual void dumpLUT(std::ostream &myCout, int LUTtype, std::string name) const
std::map< std::string, unsigned int > m_Prec_DeltaPhi
Definition: GlobalScales.h:146
std::vector< std::pair< double, double > > etBins
Definition: GlobalScales.h:44
ScaleParameters getHTTScales() const
Definition: GlobalScales.h:90
void setMuonScales(ScaleParameters &scales)
Definition: GlobalScales.h:60
long long getLUT_DeltaPhi(std::string lutName, int element) const
void setHTTScales(ScaleParameters &scales)
Definition: GlobalScales.h:66
ScaleParameters getETTEmScales() const
Definition: GlobalScales.h:87
std::map< std::string, std::vector< long long > > m_lut_DeltaEta
Definition: GlobalScales.h:138
std::map< std::string, std::vector< long long > > m_lut_CalMuEta
Definition: GlobalScales.h:136
virtual void setLUT_DeltaPhi(std::string lutName, std::vector< long long > lut, unsigned int precision)
Definition: GlobalScales.cc:87
void setHTMScales(ScaleParameters &scales)
Definition: GlobalScales.h:69
virtual void setLUT_Pt(std::string lutName, std::vector< long long > lut, unsigned int precision)
typedef for a single object template
Definition: GlobalScales.h:39
std::map< std::string, std::vector< long long > > m_lut_Cosh
Definition: GlobalScales.h:141
void setETTScales(ScaleParameters &scales)
Definition: GlobalScales.h:64
long long getLUT_CalMuPhi(std::string lutName, int element) const
std::map< std::string, std::vector< long long > > m_lut_Cos
Definition: GlobalScales.h:142
virtual std::string getScalesName() const
Definition: GlobalScales.cc:36
ScaleParameters getETMHFScales() const
Definition: GlobalScales.h:89
unsigned int getPrec_Cos(std::string lutName) const
virtual void printScale(ScaleParameters scale, std::ostream &myCout) const
ScaleParameters m_muScales
Definition: GlobalScales.h:124