32 for(
int k=0;
k<4;
k++)
state.push_back(
true);
53 if(m_pedValflag<0) m_pedValflag=0;
55 cout<<
"WARNING - incompatible cfg options: nevtsample = "<<
m_nevtsample<<
", pedValflag = "<<m_pedValflag<<endl;
56 cout<<
"Setting pedValflag = 0"<<endl;
59 if(m_pedValflag>1) m_pedValflag=1;
66 hbHists.ALLPEDS =
new TH1F(
"HBHE All Pedestals",
"HBHE All Peds",10,0,9);
67 hbHists.PEDRMS=
new TH1F(
"HBHE All Pedestal Widths",
"HBHE All Pedestal RMS",100,0,3);
68 hbHists.PEDMEAN=
new TH1F(
"HBHE All Pedestal Means",
"HBHE All Pedestal Means",100,0,9);
69 hbHists.CHI2=
new TH1F(
"HBHE Chi2/ndf for whole range Gauss fit",
"HBHE Chi2/ndf Gauss",200,0.,50.);
71 hoHists.ALLPEDS =
new TH1F(
"HO All Pedestals",
"HO All Peds",10,0,9);
72 hoHists.PEDRMS=
new TH1F(
"HO All Pedestal Widths",
"HO All Pedestal RMS",100,0,3);
73 hoHists.PEDMEAN=
new TH1F(
"HO All Pedestal Means",
"HO All Pedestal Means",100,0,9);
74 hoHists.CHI2=
new TH1F(
"HO Chi2/ndf for whole range Gauss fit",
"HO Chi2/ndf Gauss",200,0.,50.);
76 hfHists.ALLPEDS =
new TH1F(
"HF All Pedestals",
"HF All Peds",10,0,9);
77 hfHists.PEDRMS=
new TH1F(
"HF All Pedestal Widths",
"HF All Pedestal RMS",100,0,3);
78 hfHists.PEDMEAN=
new TH1F(
"HF All Pedestal Means",
"HF All Pedestal Means",100,0,9);
79 hfHists.CHI2=
new TH1F(
"HF Chi2/ndf for whole range Gauss fit",
"HF Chi2/ndf Gauss",200,0.,50.);
86 for(
int i=0;
i<16;
i++)
_meot->second[
i].first->Delete();
89 for(
int i=0;
i<16;
i++)
_meot->second[
i].first->Delete();
92 for(
int i=0;
i<16;
i++)
_meot->second[
i].first->Delete();
113 m_file=
new TFile(m_outputFileROOT.c_str(),
"RECREATE");
217 static const int bins=10;
218 static const int bins2=100;
219 float lo=-0.5;
float hi=9.5;
220 map<int,PEDBUNCH> _mei;
221 static map<HcalDetId, map<int,float> > QieCalibMap;
222 string type =
"HBHE";
225 if(detid.
ieta()<16) type =
"HB";
226 if(detid.
ieta()>16) type =
"HE";
227 if(detid.
ieta()==16){
228 if(detid.
depth()<3) type =
"HB";
229 if(detid.
depth()==3) type =
"HE";
232 else if(
id==1) type =
"HO";
233 else if(
id==2) type =
"HF";
235 _meot = toolT.find(detid);
238 if (
_meot==toolT.end()){
240 map<int,float> qiecalib;
242 for(
int i=0;
i<4;
i++){
248 sprintf(name,
"%s Pedestal, eta=%d phi=%d d=%d cap=%d",type.c_str(),detid.
ieta(),detid.
iphi(),detid.
depth(),
i);
249 insert[
i].first =
new TH1F(name,name,bins,lo,hi);
250 sprintf(name,
"%s Product, eta=%d phi=%d d=%d caps=%d*%d",type.c_str(),detid.
ieta(),detid.
iphi(),detid.
depth(),
i,(
i+1)%4);
251 insert[4+
i].first =
new TH1F(name,name,bins2,0.,100.);
252 sprintf(name,
"%s Product, eta=%d phi=%d d=%d caps=%d*%d",type.c_str(),detid.
ieta(),detid.
iphi(),detid.
depth(),
i,(
i+2)%4);
253 insert[8+
i].first =
new TH1F(name,name,bins2,0.,100.);
254 sprintf(name,
"%s Product, eta=%d phi=%d d=%d caps=%d*%d",type.c_str(),detid.
ieta(),detid.
iphi(),detid.
depth(),
i,(
i+3)%4);
255 insert[12+
i].first =
new TH1F(name,name,bins2,0.,100.);
257 sprintf(name,
"%s Signal in TS 4+5, eta=%d phi=%d d=%d",type.c_str(),detid.
ieta(),detid.
iphi(),detid.
depth());
258 insert[16].first =
new TH1F(name,name,21,-0.5,20.5);
259 sprintf(name,
"%s Signal in TS 4+5-2-3, eta=%d phi=%d d=%d",type.c_str(),detid.
ieta(),detid.
iphi(),detid.
depth());
260 insert[17].first =
new TH1F(name,name,21,-10.5,10.5);
261 sprintf(name,
"%s Signal in TS 4+5-(0+1+2+3)/2., eta=%d phi=%d d=%d",type.c_str(),detid.
ieta(),detid.
iphi(),detid.
depth());
262 insert[18].first =
new TH1F(name,name,21,-10.5,10.5);
264 _meot = toolT.find(detid);
266 QieCalibMap[detid]=qiecalib;
269 _mei =
_meot->second;
281 _mei[qie1.
capid()].first->Reset();
282 _mei[qie1.
capid()+4].first->Reset();
283 _mei[qie1.
capid()+8].first->Reset();
284 _mei[qie1.
capid()+12].first->Reset();
289 else _mei[qie1.
capid()].first->Fill(charge1);
292 _mei[qie1.
capid()].first->AddBinContent(bins+1,1);
298 map<int,float> qiecalib = QieCalibMap[detid];
301 if (charge1*charge2<bins2){
302 _mei[qie1.
capid()+4*
flag].first->Fill(charge1*charge2);
305 _mei[qie1.
capid()+4*
flag].first->Fill(bins2);
311 else if(
id==1)
hoHists.ALLPEDS->Fill(qie1.
adc());
312 else if(
id==2)
hfHists.ALLPEDS->Fill(qie1.
adc());
321 _meot = toolT.find(detid);
322 map<int,PEDBUNCH> _mei =
_meot->second;
323 _mei[16].first->Fill(qie4.
adc()+qie5.
adc()-1.);
324 _mei[17].first->Fill(qie4.
adc()+qie5.
adc()-qie2.
adc()-qie3.
adc());
325 _mei[18].first->Fill(qie4.
adc()+qie5.
adc()-(qie0.
adc()+qie1.
adc()+qie2.
adc()+qie3.
adc())/2.);
331 char PedSampleNum[20];
334 sprintf(PedSampleNum,
"HB_Sample%d",
sample);
336 m_file->mkdir(PedSampleNum);
339 sprintf(PedSampleNum,
"HO_Sample%d",
sample);
341 m_file->mkdir(PedSampleNum);
344 sprintf(PedSampleNum,
"HF_Sample%d",
sample);
346 m_file->mkdir(PedSampleNum);
356 float cap[4];
float sig[4][4];
float dcap[4];
float dsig[4][4];
float chi2[4];
363 for (
int i=0;
i<4;
i++) {
364 TF1 *
fit =
_meot->second[
i].first->GetFunction(
"gaus");
366 if(fit->GetNDF()!=0) chi2[
i]=fit->GetChisquare()/fit->GetNDF();
367 cap[
i]=fit->GetParameter(1);
368 sig[
i][
i]=fit->GetParameter(2);
369 dcap[
i]=fit->GetParError(1);
370 dsig[
i][
i]=fit->GetParError(2);
374 for (
int i=0;
i<4;
i++) {
375 cap[
i]=
_meot->second[
i].first->GetMean();
376 sig[
i][
i]=
_meot->second[
i].first->GetRMS();
389 for (
int i=0;
i<4;
i++) {
392 _meot->second[
i].first->GetXaxis()->SetTitle(
"ADC");
393 else _meot->second[
i].first->GetXaxis()->SetTitle(
"Charge, fC");
394 _meot->second[
i].first->GetYaxis()->SetTitle(
"CapID samplings");
395 _meot->second[
i].first->Write();
398 _meot->second[
i].second.first[0].push_back(cap[
i]);
399 _meot->second[
i].second.first[1].push_back(dcap[i]);
400 _meot->second[
i].second.first[2].push_back(sig[i][i]);
401 _meot->second[
i].second.first[3].push_back(dsig[i][i]);
402 _meot->second[
i].second.first[4].push_back(chi2[i]);
404 PedMeans->Fill(cap[
i]);
405 PedWidths->Fill(sig[i][i]);
410 for(
int i=16;
i<19;
i++){
412 _meot->second[
i].first->GetXaxis()->SetTitle(
"ADC");
413 else _meot->second[
i].first->GetXaxis()->SetTitle(
"Charge, fC");
414 _meot->second[
i].first->GetYaxis()->SetTitle(
"Events");
415 _meot->second[
i].first->Write();
420 sig[0][0]=sig[0][0]*sig[0][0];
421 sig[1][1]=sig[1][1]*sig[1][1];
422 sig[2][2]=sig[2][2]*sig[2][2];
423 sig[3][3]=sig[3][3]*sig[3][3];
427 sig[0][1]=
_meot->second[4].first->GetMean()-cap[0]*cap[1];
428 sig[0][2]=
_meot->second[8].first->GetMean()-cap[0]*cap[2];
429 sig[1][2]=
_meot->second[5].first->GetMean()-cap[1]*cap[2];
430 sig[1][3]=
_meot->second[9].first->GetMean()-cap[1]*cap[3];
431 sig[2][3]=
_meot->second[6].first->GetMean()-cap[2]*cap[3];
432 sig[0][3]=
_meot->second[12].first->GetMean()-cap[0]*cap[3];
433 sig[1][0]=
_meot->second[13].first->GetMean()-cap[1]*cap[0];
434 sig[2][0]=
_meot->second[10].first->GetMean()-cap[2]*cap[0];
435 sig[2][1]=
_meot->second[14].first->GetMean()-cap[2]*cap[1];
436 sig[3][1]=
_meot->second[11].first->GetMean()-cap[3]*cap[1];
437 sig[3][2]=
_meot->second[15].first->GetMean()-cap[3]*cap[2];
438 sig[3][0]=
_meot->second[7].first->GetMean()-cap[3]*cap[0];
441 for(
int i=0;
i<4;
i++){
443 _meot->second[
i].second.first[5].push_back(sig[
i][(
i+1)%4]);
444 _meot->second[
i].second.first[6].push_back(2*sig[
i][
i]*dsig[
i][
i]);
445 _meot->second[
i].second.first[7].push_back(sig[i][(i+2)%4]);
446 _meot->second[
i].second.first[8].push_back(2*sig[i][i]*dsig[i][i]);
447 _meot->second[
i].second.first[9].push_back(sig[i][(i+3)%4]);
448 _meot->second[
i].second.first[10].push_back(2*sig[i][i]*dsig[i][i]);
453 _meot->second[
i+4].first->GetXaxis()->SetTitle(
"ADC^2");
454 else _meot->second[
i+4].first->GetXaxis()->SetTitle(
"Charge^2, fC^2");
455 _meot->second[
i+4].first->GetYaxis()->SetTitle(
"2-CapID samplings");
456 _meot->second[
i+4].first->Write();
458 _meot->second[
i+8].first->GetXaxis()->SetTitle(
"ADC^2");
459 else _meot->second[
i+8].first->GetXaxis()->SetTitle(
"Charge^2, fC^2");
460 _meot->second[
i+8].first->GetYaxis()->SetTitle(
"2-CapID samplings");
461 _meot->second[
i+8].first->Write();
463 _meot->second[
i+12].first->GetXaxis()->SetTitle(
"ADC^2");
464 else _meot->second[
i+12].first->GetXaxis()->SetTitle(
"Charge^2, fC^2");
465 _meot->second[
i+12].first->GetYaxis()->SetTitle(
"2-CapID samplings");
466 _meot->second[
i+12].first->Write();
600 map<int, std::vector<double> > AverageValues;
603 for(
int i=0;
i<4;
i++){
606 sprintf(name,
"Pedestal trend, eta=%d phi=%d d=%d cap=%d",detid.
ieta(),detid.
iphi(),detid.
depth(),
i);
607 int bins =
_meot->second[
i].second.first[0].size();
610 _meot->second[
i].second.second.push_back(
new TH1F(name,name,bins,lo,hi));
611 sprintf(name,
"Width trend, eta=%d phi=%d d=%d cap=%d",detid.
ieta(),detid.
iphi(),detid.
depth(),
i);
612 bins =
_meot->second[
i].second.first[2].size();
613 hi = (
float)bins+0.5;
614 _meot->second[
i].second.second.push_back(
new TH1F(name,name,bins,lo,hi));
615 sprintf(name,
"Correlation trend, eta=%d phi=%d d=%d caps=%d*%d",detid.
ieta(),detid.
iphi(),detid.
depth(),
i,(
i+1)%4);
616 bins =
_meot->second[
i].second.first[5].size();
617 hi = (
float)bins+0.5;
618 _meot->second[
i].second.second.push_back(
new TH1F(name,name,bins,lo,hi));
628 std::vector<double>::iterator sample_it;
631 for(sample_it=
_meot->second[
i].second.first[0].begin();
632 sample_it!=
_meot->second[
i].second.first[0].end();++sample_it){
633 _meot->second[
i].second.second[0]->SetBinContent(++j,*sample_it);
636 for(sample_it=
_meot->second[
i].second.first[1].begin();
637 sample_it!=
_meot->second[
i].second.first[1].end();++sample_it){
638 _meot->second[
i].second.second[0]->SetBinError(++j,*sample_it);
641 _meot->second[
i].second.second[0]->Fit(
"pol0",
"Q");
642 TF1 *
fit =
_meot->second[
i].second.second[0]->GetFunction(
"pol0");
643 AverageValues[0].push_back(fit->GetParameter(0));
644 AverageValues[1].push_back(fit->GetParError(0));
646 AverageValues[2].push_back(fit->GetChisquare()/fit->GetNDF());
648 AverageValues[2].push_back(fit->GetChisquare());
650 _meot->second[
i].second.second[0]->GetXaxis()->SetTitle(name);
651 _meot->second[
i].second.second[0]->GetYaxis()->SetTitle(
"Pedestal value");
652 _meot->second[
i].second.second[0]->Write();
655 for(sample_it=
_meot->second[
i].second.first[2].begin();
656 sample_it!=
_meot->second[
i].second.first[2].end();++sample_it){
657 _meot->second[
i].second.second[1]->SetBinContent(++j,*sample_it);
660 for(sample_it=
_meot->second[
i].second.first[3].begin();
661 sample_it!=
_meot->second[
i].second.first[3].end();++sample_it){
662 _meot->second[
i].second.second[1]->SetBinError(++j,*sample_it);
664 _meot->second[
i].second.second[1]->GetXaxis()->SetTitle(name);
665 _meot->second[
i].second.second[1]->GetYaxis()->SetTitle(
"Pedestal width");
666 _meot->second[
i].second.second[1]->Write();
669 for(sample_it=
_meot->second[
i].second.first[5].begin();
670 sample_it!=
_meot->second[
i].second.first[5].end();++sample_it){
671 _meot->second[
i].second.second[2]->SetBinContent(++j,*sample_it);
674 for(sample_it=
_meot->second[
i].second.first[6].begin();
675 sample_it!=
_meot->second[
i].second.first[6].end();++sample_it){
676 _meot->second[
i].second.second[2]->SetBinError(++j,*sample_it);
678 _meot->second[
i].second.second[2]->GetXaxis()->SetTitle(name);
679 _meot->second[
i].second.second[2]->GetYaxis()->SetTitle(
"Close correlation");
680 _meot->second[
i].second.second[2]->Write();
709 for(sample_it=
_meot->second[
i].second.first[4].begin();
710 sample_it!=
_meot->second[
i].second.first[4].end();++sample_it){
711 Chi2->Fill(*sample_it);
715 CapidAverage=
new TH1F(
"Constant fit: Pedestal Values",
716 "Constant fit: Pedestal Values",
717 AverageValues[0].
size(),0.,AverageValues[0].
size());
718 std::vector<double>::iterator sample_it;
720 for(sample_it=AverageValues[0].
begin();
721 sample_it!=AverageValues[0].end();++sample_it){
722 CapidAverage->SetBinContent(++j,*sample_it);
725 for(sample_it=AverageValues[1].
begin();
726 sample_it!=AverageValues[1].end();++sample_it){
727 CapidAverage->SetBinError(++j,*sample_it);
729 CapidChi2=
new TH1F(
"Constant fit: Chi2/ndf",
730 "Constant fit: Chi2/ndf",
731 AverageValues[2].
size(),0.,AverageValues[2].
size());
733 for(sample_it=AverageValues[2].
begin();
734 sample_it!=AverageValues[2].end();++sample_it){
735 CapidChi2->SetBinContent(++j,*sample_it);
738 Chi2->GetXaxis()->SetTitle(
"Chi2/ndf");
739 Chi2->GetYaxis()->SetTitle(
"50 x [(16+2) x 4 x 4] `events`");
741 CapidAverage->GetYaxis()->SetTitle(
"Pedestal value");
742 CapidAverage->GetXaxis()->SetTitle(
"(16+2) x 4 x 4 `events`");
743 CapidAverage->Write();
744 CapidChi2->GetYaxis()->SetTitle(
"Chi2/ndf");
745 CapidChi2->GetXaxis()->SetTitle(
"(16+2) x 4 x 4 `events`");
762 float RefPedVals[4];
float RefPedSigs[4][4];
763 float RawPedVals[4];
float RawPedSigs[4][4];
764 map<HcalDetId,bool> isinRaw;
765 map<HcalDetId,bool> isinRef;
768 std::ofstream PedValLog;
769 PedValLog.open(
"HcalPedVal.log");
771 if(nstat[0]+nstat[1]+nstat[2]+nstat[3]<2500) PedValLog<<
"HcalPedVal: warning - low statistics"<<std::endl;
773 for (
int i=0;
i<(
int)RawChanns.size();
i++){
776 for (
int i=0;
i<(
int)RefChanns.size();
i++){
778 isinRaw[detid]=
false;
781 for (
int i=0;
i<(
int)RawChanns.size();
i++){
784 if (isinRef[detid]==
false) {
785 PedValLog<<
"HcalPedVal: channel "<<detid<<
" not found in reference set"<<std::endl;
786 std::cerr<<
"HcalPedVal: channel "<<detid<<
" not found in reference set"<<std::endl;
792 for (
int i=0;
i<(
int)RefChanns.size();
i++){
794 for (
int icap=0; icap<4; icap++) {
796 for (
int icap2=icap; icap2<4; icap2++) {
797 RefPedSigs[icap][icap2]=fRefPedestalWidths->
getValues(detid)->
getSigma(icap,icap2);
798 if(icap2!=icap)RefPedSigs[icap2][icap]=RefPedSigs[icap][icap2];
804 for (
int icap=0; icap<4; icap++) {
806 for (
int icap2=icap; icap2<4; icap2++) {
807 RawPedSigs[icap][icap2]=fRawPedestalWidths->
getValues(detid)->
getSigma(icap,icap2);
808 if(icap2!=icap)RawPedSigs[icap2][icap]=RawPedSigs[icap][icap2];
813 for (
int icap=0; icap<4; icap++) {
814 if(RawPedVals[icap]<1. || RawPedSigs[icap][icap]<0.01) isinRaw[detid]=
false;
815 for (
int icap2=icap; icap2<4; icap2++){
816 if(fabs(RawPedSigs[icap][icap2]/
sqrt(RawPedSigs[icap][icap]*RawPedSigs[icap2][icap2]))>1.) isinRaw[detid]=
false;
823 for (
int icap=0; icap<4; icap++) {
824 int icap2=(icap+1)%4;
825 float width=
sqrt(RawPedSigs[icap][icap]);
826 float erof1=width/
sqrt((
float)nstat[icap]);
827 float erof2=
sqrt(erof1*erof1+RawPedSigs[icap][icap]/(
float)nstat[icap]);
828 float erofwidth=width/
sqrt(2.*nstat[icap]);
829 float diffof1=RawPedVals[icap]-RefPedVals[icap];
830 float diffof2=RawPedVals[icap]+RawPedVals[icap2]-RefPedVals[icap]-RefPedVals[icap2];
831 float diffofw=width-
sqrt(RefPedSigs[icap][icap]);
836 if(nTS==1 && fabs(diffof1)>0.5+erof1) {
838 PedValLog<<
"HcalPedVal: drift in channel "<<detid<<
" cap "<<icap<<
": "<<RawPedVals[icap]<<
" - "<<RefPedVals[icap]<<
" = "<<diffof1<<std::endl;
840 if(nTS==2 && fabs(diffof2)>0.5+erof2) {
842 PedValLog<<
"HcalPedVal: drift in channel "<<detid<<
" caps "<<icap<<
"+"<<icap2<<
": "<<RawPedVals[icap]<<
"+"<<RawPedVals[icap2]<<
" - "<<RefPedVals[icap]<<
"+"<<RefPedVals[icap2]<<
" = "<<diffof2<<std::endl;
844 if(fabs(diffofw)>0.15*width+erofwidth) {
846 PedValLog<<
"HcalPedVal: width changed in channel "<<detid<<
" cap "<<icap<<
": "<<width<<
" - "<<
sqrt(RefPedSigs[icap][icap])<<
" = "<<diffofw<<std::endl;
853 PedValLog<<
"HcalPedVal: no valid data from channel "<<detid<<std::endl;
855 HcalPedestal item(detid,RefPedVals[0],RefPedVals[1],RefPedVals[2],RefPedVals[3]);
858 for (
int icap=0; icap<4; icap++) {
859 for (
int icap2=icap; icap2<4; icap2++) widthsp.
setSigma(icap2,icap,RefPedSigs[icap2][icap]);
867 if(erflag==0) PedValLog<<
"HcalPedVal: all pedestals checked OK"<<std::endl;
871 if(erflag%100000 == 0) {
872 for (
int i=0;
i<(
int)RefChanns.size();
i++){
874 if (isinRaw[detid]) {
876 for (
int icap=0; icap<4; icap++) {
878 for (
int icap2=icap; icap2<4; icap2++) {
879 RefPedSigs[icap][icap2]=fRefPedestalWidths->
getValues(detid)->
getSigma(icap,icap2);
880 if(icap2!=icap)RefPedSigs[icap2][icap]=RefPedSigs[icap][icap2];
881 widthsp.
setSigma(icap2,icap,RefPedSigs[icap2][icap]);
885 HcalPedestal item(detid,RefPedVals[0],RefPedVals[1],RefPedVals[2],RefPedVals[3]);
893 for (
int i=0;
i<(
int)RawChanns.size();
i++){
895 if (isinRaw[detid]) {
897 for (
int icap=0; icap<4; icap++) {
899 for (
int icap2=icap; icap2<4; icap2++) {
900 RawPedSigs[icap][icap2]=fRawPedestalWidths->
getValues(detid)->
getSigma(icap,icap2);
901 if(icap2!=icap)RawPedSigs[icap2][icap]=RawPedSigs[icap][icap2];
902 widthsp.
setSigma(icap2,icap,RawPedSigs[icap2][icap]);
906 HcalPedestal item(detid,RawPedVals[0],RawPedVals[1],RawPedVals[2],RawPedVals[3]);
T getUntrackedParameter(std::string const &, T const &) const
HcalPedestals * fRawPedestals
void per2CapsHists(int flag, int id, const HcalDetId detid, const HcalQIESample &qie1, const HcalQIESample &qie2, std::map< HcalDetId, std::map< int, PEDBUNCH > > &toolT, const HcalDbService &cond)
HcalPedestalAnalysis(const edm::ParameterSet &ps)
Constructor.
float getSigma(int fCapId1, int fCapId2) const
get correlation element for capId1/2 = 0..3
int adc() const
get the ADC sample
int size() const
total number of samples in the digi
std::string m_outputFileMean
std::vector< HBHEDataFrame >::const_iterator const_iterator
const HcalTopology * fTopology
const Item * getValues(DetId fId, bool throwOnFail=true) const
struct HcalPedestalAnalysis::@57 hoHists
const HcalQIESample & sample(int i) const
access a sample
std::vector< bool > state
const HcalPedestalWidths * fRefPedestalWidths
void processEvent(const HBHEDigiCollection &hbhe, const HODigiCollection &ho, const HFDigiCollection &hf, const HcalDbService &cond)
const HcalDetId & id() const
const HcalQIECoder * m_coder
~HcalPedestalAnalysis()
Destructor.
int depth() const
get the tower depth
int done(const HcalPedestals *fInputPedestals, const HcalPedestalWidths *fInputWidths, HcalPedestals *fOutputPedestals, HcalPedestalWidths *fOutputWidths)
const HcalQIEShape * m_shape
void GetPedConst(std::map< HcalDetId, std::map< int, PEDBUNCH > > &toolT, TH1F *PedMeans, TH1F *PedWidths)
void setup(const std::string &m_outputFileROOT)
std::vector< DetId > getAllChannels() const
int ieta() const
get the cell ieta
int size() const
total number of samples in the digi
const HcalQIESample & sample(int i) const
access a sample
float getValue(int fCapId) const
get value for capId = 0..3
bool insert(Storage &iStorage, ItemType *iItem, const IdTag &iIdTag)
std::string m_outputFileWidth
HcalPedestals * fValPedestals
std::string m_outputFileROOT
const_iterator end() const
int iphi() const
get the cell iphi
int size() const
total number of samples in the digi
std::map< HcalDetId, std::map< int, PEDBUNCH > >::iterator _meot
int capid() const
get the Capacitor id
const HcalQIESample & sample(int i) const
access a sample
const HcalQIECoder * getHcalCoder(const HcalGenericDetId &fId) const
struct HcalPedestalAnalysis::@57 hfHists
void AllChanHists(const HcalDetId detid, const HcalQIESample &qie0, const HcalQIESample &qie1, const HcalQIESample &qie2, const HcalQIESample &qie3, const HcalQIESample &qie4, const HcalQIESample &qie5, std::map< HcalDetId, std::map< int, PEDBUNCH > > &toolT)
const HcalQIEShape * getHcalShape(const HcalGenericDetId &fId) const
const HcalPedestals * fRefPedestals
const HcalDetId & id() const
HcalPedestalWidths * fValPedestalWidths
const HcalDetId & id() const
bool addValues(const Item &myItem)
static int HcalPedVal(int nstat[4], const HcalPedestals *fRefPedestals, const HcalPedestalWidths *fRefPedestalWidths, HcalPedestals *fRawPedestals, HcalPedestalWidths *fRawPedestalWidths, HcalPedestals *fValPedestals, HcalPedestalWidths *fValPedestalWidths)
HcalPedestalWidths * fRawPedestalWidths
void Trendings(std::map< HcalDetId, std::map< int, PEDBUNCH > > &toolT, TH1F *Chi2, TH1F *CapidAverage, TH1F *CapidChi2)
struct HcalPedestalAnalysis::@57 hbHists
void setSigma(int fCapId1, int fCapId2, float fSigma)
const_iterator begin() const
float charge(const HcalQIEShape &fShape, unsigned fAdc, unsigned fCapId) const
ADC [0..127] + capid [0..3] -> fC conversion.