CMS 3D CMS Logo

HcalSubdetDigiMonitor.h

Go to the documentation of this file.
00001 #ifndef HcalDigis_HcalSubdetDigiMonitor_h
00002 #define HcalDigis_HcalSubdetDigiMonitor_h
00003 
00004 #include "DQMServices/Core/interface/DQMStore.h"
00005 #include <string>
00006 #include "DQMServices/Core/interface/MonitorElement.h"
00007 
00008 class HcalSubdetDigiMonitor
00009 {
00010 public:
00011 
00012   HcalSubdetDigiMonitor(DQMStore* dbe, const std::string & subdet, int noise);
00013   void fillmeAmplIetaIphi(double v1, double v2, double v3)
00014   {fillElements(meAmplIetaIphi, v1, v2, v3);}
00015   
00016   void fillmeSumAmp(double v1)
00017   {fillElement(meSumAmp, v1);}
00018 
00019   void fillmenDigis(double v1)
00020   {fillElement(menDigis, v1 );}
00021 
00022   void fillmeADC0_depth1(double v1)
00023   {fillElement(meADC0_depth1, v1 );}
00024   void fillmeADC0_depth2(double v1)
00025   {fillElement(meADC0_depth2, v1 );}
00026   void fillmeADC0_depth3(double v1)
00027   {fillElement(meADC0_depth3, v1);}
00028   void fillmeADC0_depth4(double v1)
00029   {fillElement(meADC0_depth4, v1);}
00030 
00031   void fillmeADC0fC_depth1(double v1)
00032   {fillElement(meADC0fC_depth1, v1);}
00033   void fillmeADC0fC_depth2(double v1)
00034   {fillElement(meADC0fC_depth2, v1);}
00035   void fillmeADC0fC_depth3(double v1)
00036   {fillElement(meADC0fC_depth3, v1);}
00037   void fillmeADC0fC_depth4(double v1)
00038   {fillElement(meADC0fC_depth4, v1);}
00039 
00040   void fillmeSignalAmp(double v1)
00041   {fillElement(meSignalAmp, v1);}
00042   void fillmeSignalAmp1(double v1)
00043   {fillElement(meSignalAmp1, v1);}
00044   void fillmeSignalAmp2(double v1)
00045   {fillElement(meSignalAmp2, v1);}
00046   void fillmeSignalAmp3(double v1)
00047   {fillElement(meSignalAmp3, v1);}
00048   void fillmeSignalAmp4(double v1)
00049   {fillElement(meSignalAmp4, v1);}
00050 
00051   void fillmeSignalTimeSlice(double v1, double v2)
00052   {fillElements(meSignalTimeSlice, v1, v2);}
00053 
00054   void fillmeAll10slices(double v1, double v2)
00055   {fillElements(meAll10slices, v1, v2);}
00056 
00057   void fillmeBin5Frac(double v1)
00058   {fillElement(meBin5Frac, v1);}
00059   void fillmeBin67Frac(double v1)
00060   {fillElement(meBin67Frac, v1);}
00061 
00062   void fillmeDigiSimhit(double v1, double v2)
00063   {fillElements(meDigiSimhit, v1, v2);}
00064   void fillmeDigiSimhit1(double v1, double v2)
00065   {fillElements(meDigiSimhit1, v1, v2);}
00066   void fillmeDigiSimhit2(double v1, double v2)
00067   {fillElements(meDigiSimhit2, v1, v2);}
00068   void fillmeDigiSimhit3(double v1, double v2)
00069   {fillElements(meDigiSimhit3, v1, v2);}
00070   void fillmeDigiSimhit4(double v1, double v2)
00071   {fillElements(meDigiSimhit4, v1, v2);}
00072 
00073   void fillmeDigiSimhitProfile(double v1, double v2)
00074   {fillElements(meDigiSimhitProfile, v1, v2);}
00075   void fillmeDigiSimhitProfile1(double v1, double v2)
00076   {fillElements(meDigiSimhitProfile1, v1, v2);}
00077   void fillmeDigiSimhitProfile2(double v1, double v2)
00078   {fillElements(meDigiSimhitProfile2, v1, v2);}
00079   void fillmeDigiSimhitProfile3(double v1, double v2)
00080   {fillElements(meDigiSimhitProfile3, v1, v2);}
00081   void fillmeDigiSimhitProfile4(double v1, double v2)
00082   {fillElements(meDigiSimhitProfile4, v1, v2);}
00083 
00084   void fillmeRatioDigiSimhit(double v1)
00085   {fillElement(meRatioDigiSimhit, v1);}
00086   void fillmeRatioDigiSimhit1(double v1)
00087   {fillElement(meRatioDigiSimhit1, v1);}
00088   void fillmeRatioDigiSimhit2(double v1)
00089   {fillElement(meRatioDigiSimhit2, v1);}
00090   void fillmeRatioDigiSimhit3(double v1)
00091   {fillElement(meRatioDigiSimhit3, v1);}
00092   void fillmeRatioDigiSimhit4(double v1)
00093   {fillElement(meRatioDigiSimhit4, v1);}
00094 
00095 
00096   // DB constants 
00097 
00098   void fillmeGain0Depth1(double v1)
00099   {fillElement(meGain0Depth1, v1);}
00100   void fillmeGain1Depth1(double v1)
00101   {fillElement(meGain1Depth1, v1);}
00102   void fillmeGain2Depth1(double v1)
00103   {fillElement(meGain2Depth1, v1);}
00104   void fillmeGain3Depth1(double v1)
00105   {fillElement(meGain3Depth1, v1);}
00106   void fillmeGain0Depth2(double v1)
00107   {fillElement(meGain0Depth2, v1);}
00108   void fillmeGain1Depth2(double v1)
00109   {fillElement(meGain1Depth2, v1);}
00110   void fillmeGain2Depth2(double v1)
00111   {fillElement(meGain2Depth2, v1);}
00112   void fillmeGain3Depth2(double v1)
00113   {fillElement(meGain3Depth2, v1);}
00114   void fillmeGain0Depth3(double v1)
00115   {fillElement(meGain0Depth3, v1);}
00116   void fillmeGain1Depth3(double v1)
00117   {fillElement(meGain1Depth3, v1);}
00118   void fillmeGain2Depth3(double v1)
00119   {fillElement(meGain2Depth3, v1);}
00120   void fillmeGain3Depth3(double v1)
00121   {fillElement(meGain3Depth3, v1);}
00122   void fillmeGain0Depth4(double v1)
00123   {fillElement(meGain0Depth4, v1);}
00124   void fillmeGain1Depth4(double v1)
00125   {fillElement(meGain1Depth4, v1);}
00126   void fillmeGain2Depth4(double v1)
00127   {fillElement(meGain2Depth4, v1);}
00128   void fillmeGain3Depth4(double v1)
00129   {fillElement(meGain3Depth4, v1);}
00130 
00131   void fillmeGainWidth0Depth1(double v1)
00132   {fillElement(meGainWidth0Depth1, v1);}
00133   void fillmeGainWidth1Depth1(double v1)
00134   {fillElement(meGainWidth1Depth1, v1);}
00135   void fillmeGainWidth2Depth1(double v1)
00136   {fillElement(meGainWidth2Depth1, v1);}
00137   void fillmeGainWidth3Depth1(double v1)
00138   {fillElement(meGainWidth3Depth1, v1);}
00139   void fillmeGainWidth0Depth2(double v1)
00140   {fillElement(meGainWidth0Depth2, v1);}
00141   void fillmeGainWidth1Depth2(double v1)
00142   {fillElement(meGainWidth1Depth2, v1);}
00143   void fillmeGainWidth2Depth2(double v1)
00144   {fillElement(meGainWidth2Depth2, v1);}
00145   void fillmeGainWidth3Depth2(double v1)
00146   {fillElement(meGainWidth3Depth2, v1);}
00147   void fillmeGainWidth0Depth3(double v1)
00148   {fillElement(meGainWidth0Depth3, v1);}
00149   void fillmeGainWidth1Depth3(double v1)
00150   {fillElement(meGainWidth1Depth3, v1);}
00151   void fillmeGainWidth2Depth3(double v1)
00152   {fillElement(meGainWidth2Depth3, v1);}
00153   void fillmeGainWidth3Depth3(double v1)
00154   {fillElement(meGainWidth3Depth3, v1);}
00155   void fillmeGainWidth0Depth4(double v1)
00156   {fillElement(meGainWidth0Depth4, v1);}
00157   void fillmeGainWidth1Depth4(double v1)
00158   {fillElement(meGainWidth1Depth4, v1);}
00159   void fillmeGainWidth2Depth4(double v1)
00160   {fillElement(meGainWidth2Depth4, v1);}
00161   void fillmeGainWidth3Depth4(double v1)
00162   {fillElement(meGainWidth3Depth4, v1);}
00163 
00164   void fillmePed0Depth1(double v1)
00165   {fillElement(mePed0Depth1, v1);}
00166   void fillmePed1Depth1(double v1)
00167   {fillElement(mePed1Depth1, v1);}
00168   void fillmePed2Depth1(double v1)
00169   {fillElement(mePed2Depth1, v1);}
00170   void fillmePed3Depth1(double v1)
00171   {fillElement(mePed3Depth1, v1);}
00172   void fillmePed0Depth2(double v1)
00173   {fillElement(mePed0Depth2, v1);}
00174   void fillmePed1Depth2(double v1)
00175   {fillElement(mePed1Depth2, v1);}
00176   void fillmePed2Depth2(double v1)
00177   {fillElement(mePed2Depth2, v1);}
00178   void fillmePed3Depth2(double v1)
00179   {fillElement(mePed3Depth2, v1);}
00180   void fillmePed0Depth3(double v1)
00181   {fillElement(mePed0Depth3, v1);}
00182   void fillmePed1Depth3(double v1)
00183   {fillElement(mePed1Depth3, v1);}
00184   void fillmePed2Depth3(double v1)
00185   {fillElement(mePed2Depth3, v1);}
00186   void fillmePed3Depth3(double v1)
00187   {fillElement(mePed3Depth3, v1);}
00188   void fillmePed0Depth4(double v1)
00189   {fillElement(mePed0Depth4, v1);}
00190   void fillmePed1Depth4(double v1)
00191   {fillElement(mePed1Depth4, v1);}
00192   void fillmePed2Depth4(double v1)
00193   {fillElement(mePed2Depth4, v1);}
00194   void fillmePed3Depth4(double v1)
00195   {fillElement(mePed3Depth4, v1);}
00196 
00197 
00198   void fillmePedWidth0Depth1(double v1)
00199   {fillElement(mePedWidth0Depth1, v1);}
00200   void fillmePedWidth1Depth1(double v1)
00201   {fillElement(mePedWidth1Depth1, v1);}
00202   void fillmePedWidth2Depth1(double v1)
00203   {fillElement(mePedWidth2Depth1, v1);}
00204   void fillmePedWidth3Depth1(double v1)
00205   {fillElement(mePedWidth3Depth1, v1);}
00206   void fillmePedWidth0Depth2(double v1)
00207   {fillElement(mePedWidth0Depth2, v1);}
00208   void fillmePedWidth1Depth2(double v1)
00209   {fillElement(mePedWidth1Depth2, v1);}
00210   void fillmePedWidth2Depth2(double v1)
00211   {fillElement(mePedWidth2Depth2, v1);}
00212   void fillmePedWidth3Depth2(double v1)
00213   {fillElement(mePedWidth3Depth2, v1);}
00214   void fillmePedWidth0Depth3(double v1)
00215   {fillElement(mePedWidth0Depth3, v1);}
00216   void fillmePedWidth1Depth3(double v1)
00217   {fillElement(mePedWidth1Depth3, v1);}
00218   void fillmePedWidth2Depth3(double v1)
00219   {fillElement(mePedWidth2Depth3, v1);}
00220   void fillmePedWidth3Depth3(double v1)
00221   {fillElement(mePedWidth3Depth3, v1);}
00222   void fillmePedWidth0Depth4(double v1)
00223   {fillElement(mePedWidth0Depth4, v1);}
00224   void fillmePedWidth1Depth4(double v1)
00225   {fillElement(mePedWidth1Depth4, v1);}
00226   void fillmePedWidth2Depth4(double v1)
00227   {fillElement(mePedWidth2Depth4, v1);}
00228   void fillmePedWidth3Depth4(double v1)
00229   {fillElement(mePedWidth3Depth4, v1);}
00230 
00231   void fillmeGainMap1(double v1, double v2, double v3)
00232   {fillElements(meGainMap1, v1, v2, v3);}
00233   void fillmeGainMap2(double v1, double v2, double v3)
00234   {fillElements(meGainMap2, v1, v2, v3);}
00235   void fillmeGainMap3(double v1, double v2, double v3)
00236   {fillElements(meGainMap3, v1, v2, v3);}
00237   void fillmeGainMap4(double v1, double v2, double v3)
00238   {fillElements(meGainMap4, v1, v2, v3);}
00239 
00240   void fillmePwidthMap1(double v1, double v2, double v3)
00241   {fillElements(mePwidthMap1, v1, v2, v3);}
00242   void fillmePwidthMap2(double v1, double v2, double v3)
00243   {fillElements(mePwidthMap2, v1, v2, v3);}
00244   void fillmePwidthMap3(double v1, double v2, double v3)
00245   {fillElements(mePwidthMap3, v1, v2, v3);}
00246   void fillmePwidthMap4(double v1, double v2, double v3)
00247   {fillElements(mePwidthMap4, v1, v2, v3);}
00248 
00249 private:
00250 
00251   void fillElement(MonitorElement* me, double value)
00252   {
00253     if(me) me->Fill(value);
00254   }
00255   void fillElements(MonitorElement* me, double v1, double v2)
00256   {
00257     if(me) me->Fill(v1, v2);
00258   }
00259   void fillElements(MonitorElement* me, double v1, double v2, double v3)
00260   {
00261     if(me) me->Fill(v1, v2, v3);
00262   }
00263 
00264   // little embedded struct
00265   struct HistLim
00266   {
00267     HistLim(int nbin, float mini, float maxi)
00268     : n(nbin), min(mini), max(maxi) {}
00269     int n;
00270     float min;
00271     float max;
00272   };
00273  
00274   // utilities to create MonitorElements
00275   MonitorElement * book1D(const std::string & name, HistLim lim);
00276   MonitorElement * book2D(const std::string & name, HistLim lim1,
00277                                                     HistLim lim2);
00278   MonitorElement * bookProfile(const std::string & name, HistLim lim1, 
00279                                                          HistLim lim2);
00280 
00281   DQMStore* dbe_;
00282   std::string subdet_;
00283   int noise_;
00284 
00285   MonitorElement* meAmplIetaIphi;
00286   MonitorElement* meSumAmp;
00287   MonitorElement* menDigis;
00288 
00289   MonitorElement* meADC0_depth1;
00290   MonitorElement* meADC0_depth2;
00291   MonitorElement* meADC0_depth3;
00292   MonitorElement* meADC0_depth4; 
00293   MonitorElement* meADC0fC_depth1;
00294   MonitorElement* meADC0fC_depth2;
00295   MonitorElement* meADC0fC_depth3;
00296   MonitorElement* meADC0fC_depth4;
00297 
00298   MonitorElement* meSignalAmp;
00299   MonitorElement* meSignalAmp1;
00300   MonitorElement* meSignalAmp2;
00301   MonitorElement* meSignalAmp3;
00302   MonitorElement* meSignalAmp4;
00303 
00304   MonitorElement* meSignalTimeSlice;
00305   MonitorElement* meAll10slices;
00306   MonitorElement* meBin5Frac;
00307   MonitorElement* meBin67Frac;
00308 
00309   MonitorElement* meDigiSimhit;
00310   MonitorElement* meDigiSimhit1;
00311   MonitorElement* meDigiSimhit2;
00312   MonitorElement* meDigiSimhit3;
00313   MonitorElement* meDigiSimhit4;
00314 
00315   MonitorElement* meRatioDigiSimhit;
00316   MonitorElement* meRatioDigiSimhit1;
00317   MonitorElement* meRatioDigiSimhit2;
00318   MonitorElement* meRatioDigiSimhit3;
00319   MonitorElement* meRatioDigiSimhit4;
00320 
00321   MonitorElement* meDigiSimhitProfile;
00322   MonitorElement* meDigiSimhitProfile1;
00323   MonitorElement* meDigiSimhitProfile2;
00324   MonitorElement* meDigiSimhitProfile3;
00325   MonitorElement* meDigiSimhitProfile4;
00326 
00327   // DB constants 
00328 
00329   MonitorElement* meGain0Depth1;
00330   MonitorElement* meGain1Depth1;
00331   MonitorElement* meGain2Depth1;
00332   MonitorElement* meGain3Depth1;
00333   MonitorElement* meGain0Depth2;
00334   MonitorElement* meGain1Depth2;
00335   MonitorElement* meGain2Depth2;
00336   MonitorElement* meGain3Depth2;
00337   MonitorElement* meGain0Depth3;
00338   MonitorElement* meGain1Depth3;
00339   MonitorElement* meGain2Depth3;
00340   MonitorElement* meGain3Depth3;
00341   MonitorElement* meGain0Depth4;
00342   MonitorElement* meGain1Depth4;
00343   MonitorElement* meGain2Depth4;
00344   MonitorElement* meGain3Depth4;
00345 
00346   MonitorElement* meGainWidth0Depth1;
00347   MonitorElement* meGainWidth1Depth1;
00348   MonitorElement* meGainWidth2Depth1;
00349   MonitorElement* meGainWidth3Depth1;
00350   MonitorElement* meGainWidth0Depth2;
00351   MonitorElement* meGainWidth1Depth2;
00352   MonitorElement* meGainWidth2Depth2;
00353   MonitorElement* meGainWidth3Depth2;
00354   MonitorElement* meGainWidth0Depth3;
00355   MonitorElement* meGainWidth1Depth3;
00356   MonitorElement* meGainWidth2Depth3;
00357   MonitorElement* meGainWidth3Depth3;
00358   MonitorElement* meGainWidth0Depth4;
00359   MonitorElement* meGainWidth1Depth4;
00360   MonitorElement* meGainWidth2Depth4;
00361   MonitorElement* meGainWidth3Depth4;
00362 
00363   MonitorElement* mePed0Depth1;
00364   MonitorElement* mePed1Depth1;
00365   MonitorElement* mePed2Depth1;
00366   MonitorElement* mePed3Depth1;
00367   MonitorElement* mePed0Depth2;
00368   MonitorElement* mePed1Depth2;
00369   MonitorElement* mePed2Depth2;
00370   MonitorElement* mePed3Depth2;
00371   MonitorElement* mePed0Depth3;
00372   MonitorElement* mePed1Depth3;
00373   MonitorElement* mePed2Depth3;
00374   MonitorElement* mePed3Depth3;
00375   MonitorElement* mePed0Depth4;
00376   MonitorElement* mePed1Depth4;
00377   MonitorElement* mePed2Depth4;
00378   MonitorElement* mePed3Depth4;
00379 
00380   MonitorElement* mePedWidth0Depth1;
00381   MonitorElement* mePedWidth1Depth1;
00382   MonitorElement* mePedWidth2Depth1;
00383   MonitorElement* mePedWidth3Depth1;
00384   MonitorElement* mePedWidth0Depth2;
00385   MonitorElement* mePedWidth1Depth2;
00386   MonitorElement* mePedWidth2Depth2;
00387   MonitorElement* mePedWidth3Depth2;
00388   MonitorElement* mePedWidth0Depth3;
00389   MonitorElement* mePedWidth1Depth3;
00390   MonitorElement* mePedWidth2Depth3;
00391   MonitorElement* mePedWidth3Depth3;
00392   MonitorElement* mePedWidth0Depth4;
00393   MonitorElement* mePedWidth1Depth4;
00394   MonitorElement* mePedWidth2Depth4;
00395   MonitorElement* mePedWidth3Depth4;
00396 
00397 
00398   // CapID-0 only 
00399   MonitorElement* meGainMap1;
00400   MonitorElement* meGainMap2;
00401   MonitorElement* meGainMap3;
00402   MonitorElement* meGainMap4;
00403   MonitorElement* mePwidthMap1;
00404   MonitorElement* mePwidthMap2; 
00405   MonitorElement* mePwidthMap3; 
00406   MonitorElement* mePwidthMap4; 
00407 
00408 };
00409 
00410 #endif
00411 

Generated on Tue Jun 9 17:49:23 2009 for CMSSW by  doxygen 1.5.4