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 "xgi/Utils.h"
24 #include "xgi/Method.h"
25 
26 #include "TCanvas.h"
27 #include "TPaveText.h"
28 #include "TF1.h"
29 #include "TH2F.h"
30 #include "TGaxis.h"
31 
32 #include <fstream>
33 #include <sstream>
34 #include <map>
35 #include <vector>
36 #include <string>
37 #include <map>
38 #include <boost/cstdint.hpp>
39 
40 class DQMStore;
41 class SiPixelEDAClient;
45 
46  public:
47 
48  SiPixelInformationExtractor( bool offlineXMLfile);
50 
51  void getSingleModuleHistos( DQMStore * bei,
52  const std::multimap<std::string, std::string>& req_map,
53  xgi::Output * out);
54  void getHistosFromPath( DQMStore * bei,
55  const std::multimap<std::string, std::string>& req_map,
56  xgi::Output * out);
57  void getTrackerMapHistos( DQMStore * bei,
58  const std::multimap<std::string, std::string>& req_map,
59  xgi::Output * out);
60 
61 
62  void readModuleAndHistoList( DQMStore * bei,
63  xgi::Output * out);
64  void readModuleHistoTree( DQMStore * bei,
65  std::string & str_name,
66  xgi::Output * out);
67  void readSummaryHistoTree( DQMStore * bei,
68  std::string & str_name,
69  xgi::Output * out);
70  void readAlarmTree( DQMStore * bei,
71  std::string & str_name,
72  xgi::Output * out);
73  void readStatusMessage( DQMStore * bei,
74  std::multimap<std::string, std::string>& req_map,
75  xgi::Output * out);
76  void computeStatus( MonitorElement * mE,
77  double & colorValue,
78  std::pair<double,double> & norm) ;
80  std::pair<double,double> & norm,
81  std::string theMEType) ;
83  std::pair<double,double> & normX,
84  std::pair<double,double> & normY,
85  std::string theMEType) ;
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);
100  std::string getMEType( MonitorElement * mE) ;
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 
162  std::map<std::string,
163  std::vector< std::string> > layoutMap;
164  std::map<std::string,
165  std::map<std::string,
166  std::string> > qtestsMap;
167  std::map<std::string,
168  std::vector<std::string> > meQTestsMap;
169 
170 
176 
177  int count;
178  int errcount;
179  bool gotDigis;
180 
181  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).
void getTrackerMapHistos(DQMStore *bei, const std::multimap< std::string, std::string > &req_map, xgi::Output *out)
std::map< std::string, std::vector< std::string > > meQTestsMap
void getIMGCImage(const std::multimap< std::string, std::string > &req_map, xgi::Output *out)
int init
Definition: HydjetWrapper.h:63
void computeStatus(MonitorElement *mE, double &colorValue, std::pair< double, double > &norm)
(Documentation under construction).
void readModuleHistoTree(DQMStore *bei, std::string &str_name, xgi::Output *out)
(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_
void sendTkUpdatedStatus(DQMStore *bei, xgi::Output *out, std::string &meName, std::string &theTKType)
(Documentation under construction).
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.
dictionary map
Definition: Association.py:160
std::map< std::string, std::map< std::string, std::string > > qtestsMap
void printAlarmList(DQMStore *bei, std::ostringstream &str_val)
(Documentation under construction).
void readStatusMessage(DQMStore *bei, std::multimap< std::string, std::string > &req_map, xgi::Output *out)
tuple norm
Definition: lumiNorm.py:78
void printSummaryHistoList(DQMStore *bei, std::ostringstream &str_val)
(Documentation under construction).
void getHistosFromPath(DQMStore *bei, const std::multimap< std::string, std::string > &req_map, xgi::Output *out)
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).
tuple out
Definition: dbtoconf.py:99
void readModuleAndHistoList(DQMStore *bei, xgi::Output *out)
(Documentation under construction).
dictionary histos
Definition: combine.py:3
void getSingleModuleHistos(DQMStore *bei, const std::multimap< std::string, std::string > &req_map, xgi::Output *out)
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).
#define Output(cl)
Definition: vmac.h:193
void readAlarmTree(DQMStore *bei, std::string &str_name, xgi::Output *out)
(Documentation under construction).
~SiPixelInformationExtractor()
Destructor of the SiPixelInformationExtractor class.
void findNoisyPixels(DQMStore *bei, bool init, float noiseRate, int noiseRateDenominator, edm::EventSetup const &eSetup)
void readSummaryHistoTree(DQMStore *bei, std::string &str_name, xgi::Output *out)
(Documentation under construction).
tuple status
Definition: ntuplemaker.py:245
edm::ESHandle< SiPixelFedCablingMap > theCablingMap
void bookNoisyPixels(DQMStore *bei, float noiseRate, bool Tier0Flag)