CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
ElectronEnergyCalibrator.h
Go to the documentation of this file.
1 #ifndef ElectronEnergyCalibrator_H
2 #define ElectronEnergyCalibrator_H
3 
5 #include <string>
6 #include <vector>
7 #include <fstream>
8 #include <sstream>
9 #include <iostream>
10 
11 using std::string;
12 using std::vector;
13 using std::ifstream;
14 using std::istringstream;
15 using std::cout;
16 
17 namespace edm {
18  class StreamID;
19 }
20 
22 {
23  double nRunMin;
24  double nRunMax;
25  double corrCat0;
26  double corrCat1;
27  double corrCat2;
28  double corrCat3;
29  double corrCat4;
30  double corrCat5;
31  double corrCat6;
32  double corrCat7;
33 };
34 
36 {
37  double ptMin;
38  double ptMax;
39  double corrCat0;
40  double corrCat1;
41  double corrCat2;
42  double corrCat3;
43  double corrCat4;
44  double corrCat5;
45 };
46 
48 {
49  public:
51  const std::string pathLinData,
52  const std::string dataset,
53  int correctionsType,
54  bool applyLinearityCorrection,
55  double lumiRatio,
56  bool isMC,
57  bool updateEnergyErrors,
58  bool verbose,
59  bool synchronization
60  ) :
61  pathData_(pathData),
62  pathLinData_(pathLinData),
63  dataset_(dataset),
64  correctionsType_(correctionsType),
65  applyLinearityCorrection_(applyLinearityCorrection),
66  lumiRatio_(lumiRatio),
67  isMC_(isMC),
68  updateEnergyErrors_(updateEnergyErrors),
69  verbose_(verbose),
70  synchronization_(synchronization)
71  {
72  init();
73  }
74 
77 
78  private:
79  void init();
80  void splitString( const string &fullstr,
81  vector<string> &elements,
82  const string &delimiter
83  );
84  double stringToDouble(const string &str);
85 
86  double newEnergy_ ;
87  double newEnergyError_ ;
88 
94  double lumiRatio_;
95  bool isMC_;
97  bool verbose_;
99 
104 };
105 
106 #endif
107 
correctionValues corrValArray[100]
list elements
Definition: asciidump.py:414
void calibrate(SimpleElectron &electron, edm::StreamID const &)
void splitString(const string &fullstr, vector< string > &elements, const string &delimiter)
double stringToDouble(const string &str)
void correctLinearity(SimpleElectron &electron)
linearityCorrectionValues linCorrValArray[100]
tuple dataset
Definition: dataset.py:400
tuple cout
Definition: gather_cfg.py:121
ElectronEnergyCalibrator(const std::string pathData, const std::string pathLinData, const std::string dataset, int correctionsType, bool applyLinearityCorrection, double lumiRatio, bool isMC, bool updateEnergyErrors, bool verbose, bool synchronization)