63 LogVerbatim (
"DTDQM|DTMonitorClient|DTChamberEfficiencyClient")
64 <<
"DTChamberEfficiencyClient: endRun";
72 for(
int wheel=-2;wheel<=2;wheel++){
73 stringstream wheel_str; wheel_str << wheel;
78 MonitorElement* MECountAll = igetter.
get(
"DT/05-ChamberEff/Task/hCountSectVsChamb_All_W" + wheel_str.str());
79 MonitorElement* MECountQual = igetter.
get(
"DT/05-ChamberEff/Task/hCountSectVsChamb_Qual_W" + wheel_str.str());
80 MonitorElement* MEExtrap = igetter.
get(
"DT/05-ChamberEff/Task/hExtrapSectVsChamb_W" + wheel_str.str());
83 if(!MECountAll || !(MECountAll->
getTH2F())) {
84 edm::LogWarning(
"DTChamberEfficiencyClient") <<
"ME not available" << std::endl;
88 TH2F* hCountAll = MECountAll->
getTH2F();
89 TH2F* hCountQual = MECountQual->
getTH2F();
90 TH2F* hExtrap = MEExtrap->
getTH2F();
97 for(
int j=1;
j<=nBinX;
j++){
98 for(
int k=1;
k<=nBinY;
k++){
102 const float numerAll = hCountAll->GetBinContent(
j,
k);
103 const float numerQual = hCountQual->GetBinContent(
j,
k);
104 const float denom = hExtrap->GetBinContent(
j,
k);
107 const float effAll= numerAll/denom;
108 const float eff_error_All =
sqrt((effAll+effAll*effAll)/denom);
110 const float effQual= numerQual/denom;
111 const float eff_error_Qual =
sqrt((effQual+effQual*effQual)/denom);
130 for(
int wheel=-2; wheel<=2; wheel++) {
133 if(segmentWheelSummary != 0) {
135 for(
int sector=1; sector<=12; sector++) {
136 float nFailingChambers = 0.;
139 double errorsum = 0.;
146 if(tmpefficiency < 0.2 || tmpvariance == 0){
151 meaneff += tmpefficiency/tmpvariance;
152 errorsum += 1./tmpvariance;
154 LogTrace(
"DTDQM|DTMonitorClient|DTChamberEfficiencyClient")
155 <<
"Wheel: " << wheel <<
" Stat: " <<
station
156 <<
" Sect: " << sector <<
" status: " << meaneff/errorsum << endl;
159 if(sector == 4 || sector == 10) {
160 int whichSector = (sector == 4) ? 13 : 14;
162 const double tmpefficiency = segmentWheelSummary->
getBinContent(whichSector, 4);
163 const double tmpvariance =
pow(segmentWheelSummary->
getBinError(whichSector, 4),2);
165 if(tmpefficiency > 0.2 && tmpvariance != 0) {
166 meaneff += tmpefficiency/tmpvariance;
167 errorsum += 1./tmpvariance;
169 else nFailingChambers++;
173 double eff_result = 0;
174 if(errorsum != 0) eff_result = meaneff/errorsum;
176 if(nFailingChambers != 0) {
177 if(sector != 4 && sector != 10) eff_result = eff_result*(4.-nFailingChambers)/4.;
178 else eff_result = eff_result*(5.-nFailingChambers)/5.;
void setBinContent(int binx, double content)
set content of bin (1-D)
MonitorElement * get(const std::string &path)
int getNbinsY(void) const
get # of bins in Y-axis
void Fill(HcalDetId &id, double val, std::vector< TH2F > &depth)
void setBinError(int binx, double error)
set uncertainty on content of bin (1-D)
void bookHistos(DQMStore::IBooker &)
book the report summary
std::map< int, MonitorElement * > EffDistrPerWh
double getBinError(int binx) const
get uncertainty on content of bin (1-D) - See TH1::GetBinError for details
MonitorElement * summaryHistos[5][2]
double getBinContent(int binx) const
get content of bin (1-D)
int getNbinsX(void) const
get # of bins in X-axis
MonitorElement * globalEffSummary
TH2F * getTH2F(void) const
void Reset(void)
reset ME (ie. contents, errors, etc)
MonitorElement * globalEffDistr
Power< A, B >::type pow(const A &a, const B &b)