test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes
DTRunConditionVarClient Class Reference

#include <DTRunConditionVarClient.h>

Inheritance diagram for DTRunConditionVarClient:
DQMEDHarvester edm::one::EDAnalyzer< edm::one::WatchRuns, edm::one::WatchLuminosityBlocks, edm::one::SharedResources > edm::one::EDAnalyzerBase edm::EDConsumerBase

Public Member Functions

void beginRun (const edm::Run &r, const edm::EventSetup &c)
 
 DTRunConditionVarClient (const edm::ParameterSet &ps)
 Constructor. More...
 
virtual ~DTRunConditionVarClient ()
 Destructor. More...
 
- Public Member Functions inherited from DQMEDHarvester
virtual void analyze (edm::Event const &, edm::EventSetup const &) final
 
virtual void beginLuminosityBlock (edm::LuminosityBlock const &, edm::EventSetup const &) final
 
 DQMEDHarvester (void)
 
virtual void endJob () final
 
virtual void endLuminosityBlock (edm::LuminosityBlock const &, edm::EventSetup const &) final
 
virtual void endRun (edm::Run const &, edm::EventSetup const &)
 
- Public Member Functions inherited from edm::one::EDAnalyzer< edm::one::WatchRuns, edm::one::WatchLuminosityBlocks, edm::one::SharedResources >
 EDAnalyzer ()=default
 
- Public Member Functions inherited from edm::one::EDAnalyzerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzerBase ()
 
ModuleDescription const & moduleDescription () const
 
virtual ~EDAnalyzerBase ()
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
 EDConsumerBase ()
 
ProductHolderIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const
 
std::vector
< ProductHolderIndexAndSkipBit >
const & 
itemsToGetFromEvent () const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesDependentUpon (std::string const &iProcessName, std::string const &iModuleLabel, bool iPrint, std::vector< char const * > &oModuleLabels) const
 
void modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
bool registeredToConsume (ProductHolderIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
void updateLookup (BranchType iBranchType, ProductHolderIndexHelper const &)
 
virtual ~EDConsumerBase ()
 

Protected Member Functions

void bookWheelHistos (DQMStore::IBooker &, std::string histoType, std::string subfolder, int wh, int nbins, float min, float max, bool isVDCorr=false)
 book the report summary More...
 
void dqmEndJob (DQMStore::IBooker &, DQMStore::IGetter &) override
 
void dqmEndLuminosityBlock (DQMStore::IBooker &, DQMStore::IGetter &, edm::LuminosityBlock const &, edm::EventSetup const &)
 DQM Client Diagnostic. More...
 
void percDevVDrift (DTChamberId indexCh, float meanVD, float sigmaVD, float &devVD, float &errdevVD)
 
float varQuality (float var, float maxGood, float minBad)
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 

Private Member Functions

MonitorElementgetChamberHistos (DQMStore::IGetter &, const DTChamberId &, std::string)
 

Private Attributes

std::map< std::string,
MonitorElement * > 
allwheelHistos
 
bool bookingdone
 
MonitorElementglbT0Summary
 
MonitorElementglbVDriftSummary
 
float maxGoodT0
 
float maxGoodT0Sigma
 
float maxGoodVDriftDev
 
float maxGoodVDriftSigma
 
float maxRangeT0
 
float maxRangeVDrift
 
float minBadT0
 
float minBadT0Sigma
 
float minBadVDriftDev
 
float minBadVDriftSigma
 
float minRangeT0
 
float minRangeVDrift
 
edm::ESHandle< DTMtimemTime
 
const DTMtimemTimeMap_
 
int nevents
 
std::map< std::string,
MonitorElement * > 
summaryHistos
 
std::map< int, std::map
< std::string, MonitorElement * > > 
wheelHistos
 

Additional Inherited Members

- Public Types inherited from edm::one::EDAnalyzerBase
typedef EDAnalyzerBase ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::one::EDAnalyzerBase
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 

Detailed Description

Description:

Author
: Paolo Bellan, Antonio Branca $date : 23/09/2011 15:42:04 CET $

Modification:

threadsafe version (//-) oct/nov 2014 - WATWanAbdullah -ncpp-um-my

Definition at line 48 of file DTRunConditionVarClient.h.

Constructor & Destructor Documentation

DTRunConditionVarClient::DTRunConditionVarClient ( const edm::ParameterSet ps)

Constructor.

Definition at line 35 of file DTRunConditionVarClient.cc.

References edm::ParameterSet::getUntrackedParameter(), and cmsHarvester::nevents.

36 {
37 
38  LogVerbatim ("DTDQM|DTMonitorClient|DTRunConditionVarClient")
39  << "DTRunConditionVarClient: Constructor called";
40 
41 
42  minRangeVDrift = pSet.getUntrackedParameter<double>("minRangeVDrift");
43  maxRangeVDrift = pSet.getUntrackedParameter<double>("maxRangeVDrift");
44  minRangeT0 = pSet.getUntrackedParameter<double>("minRangeT0");
45  maxRangeT0 = pSet.getUntrackedParameter<double>("maxRangeT0");
46 
47  maxGoodVDriftDev = pSet.getUntrackedParameter<double>("maxGoodVDriftDev");
48  minBadVDriftDev = pSet.getUntrackedParameter<double>("minBadVDriftDev");
49  maxGoodT0 = pSet.getUntrackedParameter<double>("maxGoodT0");
50  minBadT0 = pSet.getUntrackedParameter<double>("minBadT0");
51 
52  maxGoodVDriftSigma = pSet.getUntrackedParameter<double>("maxGoodVDriftSigma");
53  minBadVDriftSigma = pSet.getUntrackedParameter<double>("minBadVDriftSigma");
54  maxGoodT0Sigma = pSet.getUntrackedParameter<double>("maxGoodT0Sigma");
55  minBadT0Sigma = pSet.getUntrackedParameter<double>("minBadT0Sigma");
56 
57  nevents = 0;
58 
59  bookingdone = 0;
60 
61 }
DTRunConditionVarClient::~DTRunConditionVarClient ( )
virtual

Destructor.

Definition at line 63 of file DTRunConditionVarClient.cc.

64 {
65  LogVerbatim ("DTDQM|DTMonitorClient|DTRunConditionVarClient")
66  << "DTRunConditionVarClient: Destructor called";
67 }

Member Function Documentation

void DTRunConditionVarClient::beginRun ( const edm::Run r,
const edm::EventSetup c 
)
virtual

Reimplemented from DQMEDHarvester.

Definition at line 69 of file DTRunConditionVarClient.cc.

References edm::EventSetup::get(), and LogTrace.

69  {
70 
71  LogTrace ("DTDQM|DTMonitorClient|DTResolutionAnalysisTest") <<"[DTRunConditionVarClient]: BeginRun";
72  // Get the map of vdrift from the setup
73  context.get<DTMtimeRcd>().get(mTime);
74  mTimeMap_ = &*mTime;
75 }
edm::ESHandle< DTMtime > mTime
#define LogTrace(id)
void DTRunConditionVarClient::bookWheelHistos ( DQMStore::IBooker ,
std::string  histoType,
std::string  subfolder,
int  wh,
int  nbins,
float  min,
float  max,
bool  isVDCorr = false 
)
protected

book the report summary

Definition at line 287 of file DTRunConditionVarClient.cc.

References DQMStore::IBooker::book1D(), DQMStore::IBooker::book2D(), hlt_dqm_clientPB-live_cfg::folder, hlt_dqm_clientPB-live_cfg::me, MonitorElement::setAxisTitle(), MonitorElement::setBinLabel(), and DQMStore::IBooker::setCurrentFolder().

289 {
290  stringstream wheel; wheel << wh;
291 
292  string folder = "DT/02-Segments/" + subfolder;
293 
294  ibooker.setCurrentFolder(folder);
295 
296  string histoName = histoType + "_W" + wheel.str();
297  string histoLabel = histoType;
298 
299  (wheelHistos[wh])[histoType] = ibooker.book1D(histoName, histoLabel, nbins, min, max);
300 
301  if( isVDCorr ) {
302  histoLabel = "Summary of corrections to VDrift DB values";
303  histoName = "CorrTo" + histoType + "Summary_W" + wheel.str();
304  } else {
305  histoLabel = histoType + "Summary";
306  histoName = histoType + "Summary_W" + wheel.str();
307  }
308 
309  MonitorElement* me = ibooker.book2D(histoName, histoLabel,12,1,13,4,1,5);
310 
311  me->setBinLabel(1,"MB1",2);
312  me->setBinLabel(2,"MB2",2);
313  me->setBinLabel(3,"MB3",2);
314  me->setBinLabel(4,"MB4",2);
315  me->setAxisTitle("Sector",1);
316 
317  (wheelHistos[wh])[histoType + "Summary"] = me;
318 
319  return;
320 }
void setBinLabel(int bin, const std::string &label, int axis=1)
set bin label for x, y or z axis (axis=1, 2, 3 respectively)
T min(T a, T b)
Definition: MathUtil.h:58
std::map< int, std::map< std::string, MonitorElement * > > wheelHistos
void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)
tuple folder
Histograms Source for live online DQM in P5
void DTRunConditionVarClient::dqmEndJob ( DQMStore::IBooker ibooker,
DQMStore::IGetter igetter 
)
overrideprotectedvirtual

Implements DQMEDHarvester.

Definition at line 85 of file DTRunConditionVarClient.cc.

References DQMStore::IBooker::book1D(), DQMStore::IBooker::book2D(), DTChamberId, HcalObjRepresent::Fill(), MonitorElement::getEntries(), MonitorElement::getMean(), MonitorElement::getRMS(), edm::max(), edm::min(), DQMStore::IBooker::setCurrentFolder(), and histoStyle::weight.

86 {
87  LogVerbatim ("DTDQM|DTMonitorClient|DTRunConditionVarClient")
88  << "DTRunConditionVarClient: end job";
89 
90  ibooker.setCurrentFolder("DT/02-Segments");
91 
92  glbVDriftSummary = ibooker.book2D("VDriftGlbSummary", "# of MBs with good mean and good sigma of vDrift",12,1,13,5,-2,3);
93  glbT0Summary = ibooker.book2D("T0GlbSummary", "# of MBs with good mean and good sigma of t0",12,1,13,5,-2,3);
94 
95  ibooker.setCurrentFolder("DT/02-Segments/02-MeanVDrift");
96 
97  summaryHistos["MeanVDriftGlbSummary"] = ibooker.book2D("MeanVDriftGlbSummary","mean VDrift average per sector",12,1.,13.,5,-2.,3.);
98  allwheelHistos["allMeanVDrift"] = ibooker.book1D("VDriftMeanAllWheels","mean VDrift for all chambers",60,0.0048,0.006);
99 
100  ibooker.setCurrentFolder("DT/02-Segments/02-SigmaVDrift");
101 
102  summaryHistos["SigmaVDriftGlbSummary"] = ibooker.book2D("SigmaVDriftGlbSummary","# of Chambers with good sigma VDrift",12,1.,13.,5,-2.,3.);
103  allwheelHistos["allSigmaVDrift"] = ibooker.book1D("VDriftSigmaAllWheels","sigma VDrift for all chambers",30,0.,0.0006);
104 
105  ibooker.setCurrentFolder("DT/02-Segments/03-MeanT0");
106 
107  summaryHistos["MeanT0GlbSummary"] = ibooker.book2D("MeanT0GlbSummary","mean T0 average per sector",12,1.,13.,5,-2.,3.);
108  allwheelHistos["allMeanT0"] = ibooker.book1D("T0MeanAllWheels","mean T0 for all chambers",100,-25.,25.);
109 
110  ibooker.setCurrentFolder("DT/02-Segments/03-SigmaT0");
111 
112  summaryHistos["SigmaT0GlbSummary"] = ibooker.book2D("SigmaT0GlbSummary","# of Chambers with good sigma T0",12,1.,13.,5,-2.,3.);
113  allwheelHistos["allSigmaT0"] = ibooker.book1D("T0SigmaAllWheels","sigma T0 for alla chambers",50,0,25);
114 
115  for(int wh=-2; wh<=2; wh++) {
116  bookWheelHistos(ibooker,"MeanVDrift","02-MeanVDrift",wh,60,0.0048,0.006,true);
117  bookWheelHistos(ibooker,"SigmaVDrift","02-SigmaVDrift",wh,30,0.,0.0006);
118  bookWheelHistos(ibooker,"MeanT0","03-MeanT0",wh,100,-25.,25.);
119  bookWheelHistos(ibooker,"SigmaT0","03-SigmaT0",wh,50,0,25);
120  }
121 
122 
123  for(int wheel=-2;wheel<=2;wheel++){
124  for(int sec=1; sec<=14; sec++) {
125  for(int stat=1; stat<=4; stat++) {
126 
127  if( (sec == 13 || sec == 14) && stat != 4 ) continue;
128 
129  // Get the ME produced by DTRunConditionVar Source
130  MonitorElement* VDriftME = getChamberHistos(igetter,DTChamberId(wheel,stat,sec),"VDrift_FromSegm");
131  MonitorElement* T0ME = getChamberHistos(igetter,DTChamberId(wheel,stat,sec),"T0_FromSegm");
132 
133  if (!VDriftME || !T0ME) {
134  edm::LogWarning("DTRunConditionVarClient") << "ME not available" << std::endl;
135  return;
136  }
137 
138 
139  // Get the means per chamber
140  float vDriftMean = VDriftME->getMean();
141  float t0Mean = T0ME->getMean();
142 
143  // Get the sigma per chamber
144  float vDriftSigma = VDriftME->getRMS();
145  float t0Sigma = T0ME->getRMS();
146 
147  if( VDriftME->getEntries() != 0 ) {
148 
149  allwheelHistos["allMeanVDrift"] -> Fill(vDriftMean);
150  allwheelHistos["allSigmaVDrift"] -> Fill(vDriftSigma);
151 
152  (wheelHistos[wheel])["MeanVDrift"] -> Fill(vDriftMean);
153  (wheelHistos[wheel])["SigmaVDrift"] -> Fill(vDriftSigma);
154 
155  }
156 
157 
158  if( T0ME->getEntries() != 0 ) {
159 
160  allwheelHistos["allMeanT0"] -> Fill(t0Mean);
161  allwheelHistos["allSigmaT0"] -> Fill(t0Sigma);
162 
163  (wheelHistos[wheel])["MeanT0"] -> Fill(t0Mean);
164  (wheelHistos[wheel])["SigmaT0"] -> Fill(t0Sigma);
165 
166  }
167 
168  DTChamberId indexCh(wheel,stat,sec);
169 
170  float vDriftDev(0.), errvDriftDev(0.);
171  percDevVDrift(indexCh, vDriftMean, vDriftSigma, vDriftDev, errvDriftDev);
172 
173  int sec_ = sec;
174  if( sec == 13 || sec == 14 ) sec_ = ( sec == 13 ) ? 4 : 10;
175 
176  float fillvDriftDev = max(min(vDriftDev,maxRangeVDrift),minRangeVDrift);
177  float fillT0Mean = max(min(t0Mean,maxRangeT0),minRangeT0);
178 
179  float vDriftDevQ = varQuality(fabs(vDriftDev),maxGoodVDriftDev,minBadVDriftDev);
180  float t0MeanQ = varQuality(fabs(t0Mean),maxGoodT0,minBadT0);
181 
182  float vDriftSigmQ = varQuality(vDriftSigma,maxGoodVDriftSigma,minBadVDriftSigma);
183  float t0SigmQ = varQuality(t0Sigma,maxGoodT0Sigma,minBadT0Sigma);
184 
185  if( sec == 13 || sec == 14 ) {
186 
187  float binVDriftDev = (wheelHistos[wheel])["MeanVDriftSummary"]->getBinContent(sec_,stat);
188  binVDriftDev = (fabs(binVDriftDev) > fabs(fillvDriftDev)) ? binVDriftDev : fillvDriftDev;
189  (wheelHistos[wheel])["MeanVDriftSummary"] -> setBinContent(sec_,stat,binVDriftDev);
190 
191  float binT0MeanVal = (wheelHistos[wheel])["MeanT0Summary"] -> getBinContent(sec_,stat);
192  binT0MeanVal = (fabs(binT0MeanVal) > fabs(fillT0Mean)) ? binT0MeanVal : fillT0Mean;
193  (wheelHistos[wheel])["MeanT0Summary"] -> setBinContent(sec_,stat,binT0MeanVal);
194 
195  float binVDriftSigmVal = (wheelHistos[wheel])["SigmaVDriftSummary"] -> getBinContent(sec_,stat);
196  binVDriftSigmVal = (binVDriftSigmVal > 0. && binVDriftSigmVal < vDriftSigmQ) ? binVDriftSigmVal : vDriftSigmQ;
197  (wheelHistos[wheel])["SigmaVDriftSummary"] -> setBinContent(sec_,stat,binVDriftSigmVal);
198 
199  float binT0SigmVal = (wheelHistos[wheel])["SigmaT0Summary"] -> getBinContent(sec_,stat);
200  binT0SigmVal = (binT0SigmVal > 0. && binT0SigmVal < t0SigmQ) ? binT0SigmVal : t0SigmQ;
201  (wheelHistos[wheel])["SigmaT0Summary"] -> setBinContent(sec_,stat,binT0SigmVal);
202 
203  } else {
204 
205  (wheelHistos[wheel])["MeanVDriftSummary"] -> setBinContent(sec_,stat,fillvDriftDev);
206  (wheelHistos[wheel])["MeanT0Summary"] -> setBinContent(sec_,stat,fillT0Mean);
207  (wheelHistos[wheel])["SigmaVDriftSummary"] -> setBinContent(sec_,stat,vDriftSigmQ);
208  (wheelHistos[wheel])["SigmaT0Summary"] -> setBinContent(sec_,stat,t0SigmQ);
209 
210  }
211 
212  double weight = 1/4.;
213  if(( sec_ == 4 || sec_ == 10) && stat == 4) weight = 1/8.;
214 
215  if( vDriftDevQ > 0.85 && vDriftSigmQ > 0.85 ) {
216  glbVDriftSummary -> Fill(sec_,wheel,weight);
217  summaryHistos["MeanVDriftGlbSummary"] -> Fill(sec_,wheel,weight);
218  summaryHistos["SigmaVDriftGlbSummary"] -> Fill(sec_,wheel,weight);
219 
220  } else {
221  if( vDriftDevQ > 0.85 && vDriftSigmQ < 0.85 ) {
222  summaryHistos["MeanVDriftGlbSummary"] -> Fill(sec_,wheel,weight);
223  }
224  if( vDriftDevQ < 0.85 && vDriftSigmQ > 0.85 ) {
225  summaryHistos["SigmaVDriftGlbSummary"] -> Fill(sec_,wheel,weight);
226  }
227  }
228 
229  if( t0MeanQ > 0.85 && t0SigmQ > 0.85 ) {
230  glbT0Summary -> Fill(sec_,wheel,weight);
231  summaryHistos["MeanT0GlbSummary"] -> Fill(sec_,wheel,weight);
232  summaryHistos["SigmaT0GlbSummary"] -> Fill(sec_,wheel,weight);
233  } else {
234  if( t0MeanQ > 0.85 && t0SigmQ < 0.85 ) {
235  summaryHistos["MeanT0GlbSummary"] -> Fill(sec_,wheel,weight);
236 
237  }
238  if( t0MeanQ < 0.85 && t0SigmQ > 0.85 ) {
239  summaryHistos["SigmaT0GlbSummary"] -> Fill(sec_,wheel,weight);
240  }
241  }
242 
243 
244  }// end loop on stations
245  }// end loop on sectors
246  }//end loop on wheels
247 
248  return;
249 }
std::map< std::string, MonitorElement * > summaryHistos
MonitorElement * getChamberHistos(DQMStore::IGetter &, const DTChamberId &, std::string)
double getEntries(void) const
get # of entries
double getMean(int axis=1) const
get mean value of histogram along x, y or z axis (axis=1, 2, 3 respectively)
float varQuality(float var, float maxGood, float minBad)
void Fill(HcalDetId &id, double val, std::vector< TH2F > &depth)
void percDevVDrift(DTChamberId indexCh, float meanVD, float sigmaVD, float &devVD, float &errdevVD)
MonitorElement * book1D(Args &&...args)
Definition: DQMStore.h:115
T min(T a, T b)
Definition: MathUtil.h:58
void bookWheelHistos(DQMStore::IBooker &, std::string histoType, std::string subfolder, int wh, int nbins, float min, float max, bool isVDCorr=false)
book the report summary
void setCurrentFolder(const std::string &fullpath)
Definition: DQMStore.cc:276
MonitorElement * book2D(Args &&...args)
Definition: DQMStore.h:133
std::map< std::string, MonitorElement * > allwheelHistos
std::map< int, std::map< std::string, MonitorElement * > > wheelHistos
double getRMS(int axis=1) const
get RMS of histogram along x, y or z axis (axis=1, 2, 3 respectively)
int weight
Definition: histoStyle.py:50
void DTRunConditionVarClient::dqmEndLuminosityBlock ( DQMStore::IBooker ibooker,
DQMStore::IGetter igetter,
edm::LuminosityBlock const &  lumiSeg,
edm::EventSetup const &  context 
)
protectedvirtual

DQM Client Diagnostic.

Reimplemented from DQMEDHarvester.

Definition at line 79 of file DTRunConditionVarClient.cc.

81 {
82 
83 }
MonitorElement * DTRunConditionVarClient::getChamberHistos ( DQMStore::IGetter ,
const DTChamberId ,
std::string   
)
private

Definition at line 322 of file DTRunConditionVarClient.cc.

References hlt_dqm_clientPB-live_cfg::folder, DQMStore::IGetter::get(), LogTrace, DTChamberId::sector(), DQMStore::IGetter::setCurrentFolder(), DTChamberId::station(), relativeConstraints::station, and DTChamberId::wheel().

322  {
323 
324  int wh = dtCh.wheel();
325  int sc = dtCh.sector();
326  int st = dtCh.station();
327  stringstream wheel; wheel << wh;
328  stringstream station; station << st;
329  stringstream sector; sector << sc;
330 
331  string folder = "DT/02-Segments/Wheel" + wheel.str() + "/Sector" + sector.str() + "/Station" + station.str();
332  string histoTag = "_W" + wheel.str() + "_Sec" + sector.str() + "_St" + station.str();
333  string MEpath = folder + "/" + histoType + histoTag;
334 
335  igetter.setCurrentFolder(folder);
336 
337  LogTrace ("DTDQM|DTMonitorModule|DTRunConditionVar")
338  << "[DTRunConditionVar]: getting ME from " << folder << endl;
339 
340  MonitorElement* ME = igetter.get(MEpath);
341 
342  return ME;
343 }
Definition: ME.h:11
#define LogTrace(id)
MonitorElement ME
tuple folder
Histograms Source for live online DQM in P5
void DTRunConditionVarClient::percDevVDrift ( DTChamberId  indexCh,
float  meanVD,
float  sigmaVD,
float &  devVD,
float &  errdevVD 
)
protected

Definition at line 261 of file DTRunConditionVarClient.cc.

References DTVelocityUnits::cm_per_ns, and Exception.

261  {
262 
263  DTSuperLayerId indexSLPhi1(indexCh,1);
264  DTSuperLayerId indexSLPhi2(indexCh,3);
265 
266  float vDriftPhi1(0.), vDriftPhi2(0.);
267  float ResPhi1(0.), ResPhi2(0.);
268  int status1 = mTimeMap_->get(indexSLPhi1,vDriftPhi1,ResPhi1,DTVelocityUnits::cm_per_ns);
269  int status2 = mTimeMap_->get(indexSLPhi2,vDriftPhi2,ResPhi2,DTVelocityUnits::cm_per_ns);
270 
271  if(status1 != 0 || status2 != 0) {
272  DTSuperLayerId sl = (status1 != 0) ? indexSLPhi1 : indexSLPhi2;
273  throw cms::Exception("DTRunConditionVarClient") << "Could not find vDrift entry in DB for"
274  << sl << endl;
275  }
276 
277  float vDriftMed = (vDriftPhi1 + vDriftPhi2) / 2.;
278 
279  devVD = (meanVD - vDriftMed) / vDriftMed;
280  devVD = devVD < 1. ? devVD : 1.;
281 
282  errdevVD = sigmaVD/vDriftMed;
283 
284  return;
285 }
int get(int wheelId, int stationId, int sectorId, int slId, float &mTime, float &mTrms, DTTimeUnits::type unit) const
Definition: DTMtime.cc:82
float DTRunConditionVarClient::varQuality ( float  var,
float  maxGood,
float  minBad 
)
protected

Definition at line 251 of file DTRunConditionVarClient.cc.

251  {
252 
253  float qual(0);
254  if( var <= maxGood ) {qual = 1.;}
255  else if( var > maxGood && var < minBad ) {qual = 0.9;}
256  else if( var >= minBad ) {qual = 0.1;}
257 
258  return qual;
259 }

Member Data Documentation

std::map<std::string, MonitorElement *> DTRunConditionVarClient::allwheelHistos
private

Definition at line 107 of file DTRunConditionVarClient.h.

bool DTRunConditionVarClient::bookingdone
private

Definition at line 100 of file DTRunConditionVarClient.h.

MonitorElement* DTRunConditionVarClient::glbT0Summary
private

Definition at line 103 of file DTRunConditionVarClient.h.

MonitorElement* DTRunConditionVarClient::glbVDriftSummary
private

Definition at line 102 of file DTRunConditionVarClient.h.

float DTRunConditionVarClient::maxGoodT0
private

Definition at line 89 of file DTRunConditionVarClient.h.

float DTRunConditionVarClient::maxGoodT0Sigma
private

Definition at line 94 of file DTRunConditionVarClient.h.

float DTRunConditionVarClient::maxGoodVDriftDev
private

Definition at line 87 of file DTRunConditionVarClient.h.

float DTRunConditionVarClient::maxGoodVDriftSigma
private

Definition at line 92 of file DTRunConditionVarClient.h.

float DTRunConditionVarClient::maxRangeT0
private

Definition at line 85 of file DTRunConditionVarClient.h.

float DTRunConditionVarClient::maxRangeVDrift
private

Definition at line 83 of file DTRunConditionVarClient.h.

float DTRunConditionVarClient::minBadT0
private

Definition at line 90 of file DTRunConditionVarClient.h.

float DTRunConditionVarClient::minBadT0Sigma
private

Definition at line 95 of file DTRunConditionVarClient.h.

float DTRunConditionVarClient::minBadVDriftDev
private

Definition at line 88 of file DTRunConditionVarClient.h.

float DTRunConditionVarClient::minBadVDriftSigma
private

Definition at line 93 of file DTRunConditionVarClient.h.

float DTRunConditionVarClient::minRangeT0
private

Definition at line 84 of file DTRunConditionVarClient.h.

float DTRunConditionVarClient::minRangeVDrift
private

Definition at line 82 of file DTRunConditionVarClient.h.

edm::ESHandle<DTMtime> DTRunConditionVarClient::mTime
private

Definition at line 97 of file DTRunConditionVarClient.h.

const DTMtime* DTRunConditionVarClient::mTimeMap_
private

Definition at line 98 of file DTRunConditionVarClient.h.

int DTRunConditionVarClient::nevents
private

Definition at line 80 of file DTRunConditionVarClient.h.

std::map<std::string, MonitorElement *> DTRunConditionVarClient::summaryHistos
private

Definition at line 106 of file DTRunConditionVarClient.h.

std::map<int, std::map<std::string, MonitorElement*> > DTRunConditionVarClient::wheelHistos
private

Definition at line 105 of file DTRunConditionVarClient.h.