CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
SiPixelInformationExtractor.h
Go to the documentation of this file.
1 #ifndef _SiPixelInformationExtractor_h_
2 #define _SiPixelInformationExtractor_h_
3 
5 
10 
15 
22 
23 #include "TCanvas.h"
24 #include "TPaveText.h"
25 #include "TF1.h"
26 #include "TH2F.h"
27 #include "TGaxis.h"
28 
29 #include <fstream>
30 #include <sstream>
31 #include <map>
32 #include <vector>
33 #include <string>
34 #include <map>
35 #include <boost/cstdint.hpp>
36 
37 class DQMStore;
38 class SiPixelEDAClient;
39 class SiPixelWebInterface;
42 
43  public:
44 
45  SiPixelInformationExtractor( bool offlineXMLfile);
47 
48  //
49  // void getSingleModuleHistos( DQMStore * bei,
50  // const std::multimap<std::string, std::string>& req_map,
51  // xgi::Output * out);
52  // void getHistosFromPath( DQMStore * bei,
53  // const std::multimap<std::string, std::string>& req_map,
54  // xgi::Output * out);
55  // void getTrackerMapHistos( DQMStore * bei,
56  // const std::multimap<std::string, std::string>& req_map,
57  // xgi::Output * out);
58 
59 
60  // void readModuleAndHistoList( DQMStore * bei,
61  // xgi::Output * out);
62  // void readModuleHistoTree( DQMStore * bei,
63  // std::string & str_name,
64  // xgi::Output * out);
65  // void readSummaryHistoTree( DQMStore * bei,
66  // std::string & str_name,
67  // xgi::Output * out);
68  // void readAlarmTree( DQMStore * bei,
69  // std::string & str_name,
70  // xgi::Output * out);
71  // void readStatusMessage( DQMStore * bei,
72  // std::multimap<std::string, std::string>& req_map,
73  // xgi::Output * out);
74 
75  void computeStatus( MonitorElement * mE,
76  double & colorValue,
77  std::pair<double,double> & norm) ;
79  std::pair<double,double> & norm,
80  std::string theMEType) ;
82  std::pair<double,double> & normX,
83  std::pair<double,double> & normY,
84  std::string theMEType) ;
85 
86  // void sendTkUpdatedStatus( DQMStore * bei,
87  // xgi::Output * out,
88  // std::string & meName,
89  // std::string & theTKType) ;
90  void selectMEList( DQMStore * bei,
91  std::string & name,
92  std::vector<MonitorElement*> & mes);
93  void getMEList( DQMStore * bei,
94  std::map<std::string, int> & mEHash);
95  int getDetId( MonitorElement * mE) ;
96  // void getIMGCImage( const std::multimap<std::string, std::string>& req_map,
97  // xgi::Output * out);
98  // void getIMGCImage( std::multimap<std::string, std::string>& req_map,
99  // xgi::Output * out);
101 
102  void readConfiguration();
103  bool readConfiguration( std::map<std::string,std::vector< std::string> > & layoutMap,
104  std::map<std::string,std::map<std::string,std::string> > & qtestsMap,
105  std::map<std::string,std::vector<std::string> > & meQTestsMap);
106 
107  void bookNoisyPixels( DQMStore * bei,
108  float noiseRate,
109  bool Tier0Flag);
110 
111  void findNoisyPixels ( DQMStore * bei,
112  bool init,
113  float noiseRate,
114  int noiseRateDenominator,
115  edm::EventSetup const & eSetup);
116 
117  void createImages (DQMStore * bei);
118 
119  private:
120 
121  void fillModuleAndHistoList( DQMStore * bei,
122  std::vector<std::string> & modules,
123  std::map<std::string,std::string> & histos);
124  void getItemList( const std::multimap<std::string, std::string> & req_map,
125  std::string item_name,
126  std::vector<std::string> & items);
127  void printModuleHistoList( DQMStore * bei,
128  std::ostringstream & str_val);
129  void printSummaryHistoList( DQMStore * bei,
130  std::ostringstream & str_val);
131  void printAlarmList( DQMStore * bei,
132  std::ostringstream & str_val);
133  bool goToDir( DQMStore * bei,
134  std::string & sname);
135  bool hasItem( std::multimap<std::string, std::string> & req_map,
136  std::string item_name);
137  std::string getItemValue( const std::multimap<std::string, std::string> & req_map,
138  std::string item_name);
139  std::string getItemValue( std::multimap<std::string, std::string> & req_map,
140  std::string item_name);
141  void createDummiesFromLayout();
142  void selectImage( std::string & name,
143  int status);
144  void selectImage( std::string & name,
145  std::vector<QReport*> & reports);
146  void selectColor( std::string & col,
147  int status);
148  void selectColor( std::string & col,
149  std::vector<QReport*> & reports);
150 
151  // void setHTMLHeader( xgi::Output * out);
152  // void setXMLHeader( xgi::Output * out);
153  // void setPlainHeader( xgi::Output * out);
154 
156 
161 
163  std::vector< std::string> > layoutMap;
168  std::vector<std::string> > meQTestsMap;
169 
170 
176 
177  int count;
178  int errcount;
179  bool gotDigis;
180 
181  std::ofstream myfile_;
182  int nevents_;
183  std::map< uint32_t , std::vector< std::pair< std::pair<int,int> , float > > > noisyDetIds_;
188 
191 
192 
194 };
195 #endif
SiPixelInformationExtractor(bool offlineXMLfile)
Constructor of the SiPixelInformationExtractor class.
void fillModuleAndHistoList(DQMStore *bei, std::vector< std::string > &modules, std::map< std::string, std::string > &histos)
(Documentation under construction).
void getNormalization(MonitorElement *mE, std::pair< double, double > &norm, std::string theMEType)
(Documentation under construction).
std::map< std::string, std::vector< std::string > > meQTestsMap
int init
Definition: HydjetWrapper.h:62
void computeStatus(MonitorElement *mE, double &colorValue, std::pair< double, double > &norm)
(Documentation under construction).
void getMEList(DQMStore *bei, std::map< std::string, int > &mEHash)
(Documentation under construction).
std::map< uint32_t, std::vector< std::pair< std::pair< int, int >, float > > > noisyDetIds_
std::map< std::string, std::vector< std::string > > layoutMap
bool hasItem(std::multimap< std::string, std::string > &req_map, std::string item_name)
(Documentation under construction).
void readConfiguration()
Read Configuration File.
std::map< std::string, std::map< std::string, std::string > > qtestsMap
void printAlarmList(DQMStore *bei, std::ostringstream &str_val)
(Documentation under construction).
void printSummaryHistoList(DQMStore *bei, std::ostringstream &str_val)
(Documentation under construction).
void selectImage(std::string &name, int status)
void getNormalization2D(MonitorElement *mE, std::pair< double, double > &normX, std::pair< double, double > &normY, std::string theMEType)
(Documentation under construction).
std::string getMEType(MonitorElement *mE)
void selectMEList(DQMStore *bei, std::string &name, std::vector< MonitorElement * > &mes)
(Documentation under construction).
void printModuleHistoList(DQMStore *bei, std::ostringstream &str_val)
(Documentation under construction).
std::string getItemValue(const std::multimap< std::string, std::string > &req_map, std::string item_name)
(Documentation under construction).
bool goToDir(DQMStore *bei, std::string &sname)
(Documentation under construction).
void selectColor(std::string &col, int status)
void getItemList(const std::multimap< std::string, std::string > &req_map, std::string item_name, std::vector< std::string > &items)
(Documentation under construction).
int getDetId(MonitorElement *mE)
(Documentation under construction).
~SiPixelInformationExtractor()
Destructor of the SiPixelInformationExtractor class.
void findNoisyPixels(DQMStore *bei, bool init, float noiseRate, int noiseRateDenominator, edm::EventSetup const &eSetup)
tuple status
Definition: ntuplemaker.py:245
int col
Definition: cuy.py:1008
edm::ESHandle< SiPixelFedCablingMap > theCablingMap
void bookNoisyPixels(DQMStore *bei, float noiseRate, bool Tier0Flag)