CMS 3D CMS Logo

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

#include <DQM/HcalDetDiagLaserMonitor/src/HcalDetDiagLaserMonitor.cc>

Inheritance diagram for HcalDetDiagLaserMonitor:
HcalBaseDQMonitor edm::EDAnalyzer

Public Member Functions

 HcalDetDiagLaserMonitor (const edm::ParameterSet &)
 
 ~HcalDetDiagLaserMonitor ()
 
- Public Member Functions inherited from HcalBaseDQMonitor
 HcalBaseDQMonitor (const edm::ParameterSet &ps)
 
 HcalBaseDQMonitor ()
 
 ~HcalBaseDQMonitor ()
 
- Public Member Functions inherited from edm::EDAnalyzer
 EDAnalyzer ()
 
std::string workerType () const
 
virtual ~EDAnalyzer ()
 

Private Member Functions

void analyze (const edm::Event &, const edm::EventSetup &)
 
void beginLuminosityBlock (const edm::LuminosityBlock &lumiSeg, const edm::EventSetup &c)
 
void beginRun (const edm::Run &run, const edm::EventSetup &c)
 
void endLuminosityBlock (const edm::LuminosityBlock &lumiSeg, const edm::EventSetup &c)
 
void endRun (const edm::Run &run, const edm::EventSetup &c)
 
void fillHistos (int sd)
 
void fillProblems (int sd)
 
bool get_ave_rbx (int sd, int side, int rbx, float *ave, float *rms)
 
bool get_ave_subdet (int sd, float *ave_t, float *ave_e, float *ave_t_r, float *ave_e_r)
 
HcalDetDiagLaserDataGetCalib (std::string sd, int eta, int phi)
 
void LoadDataset ()
 
void LoadReference ()
 
void SaveRaddamData ()
 
void SaveReference ()
 

Private Attributes

std::string baseFolder_
 
HcalDetDiagLaserData calib_data [5][5][72]
 
edm::InputTag calibDigiLabel_
 
bool createHTMLonly
 
int dataset_seq_number
 
std::string DatasetName
 
const HcalElectronicsMapemap
 
MonitorElementEnergy2Dhbhehf
 
MonitorElementEnergy2Dho
 
HcalDetDiagLaserData hb_data [85][72][4]
 
MonitorElementhb_time_rbx
 
MonitorElementhbheEnergy
 
MonitorElementhbheEnergyRMS
 
MonitorElementhbheTime
 
MonitorElementhbheTimeRMS
 
HcalDetDiagLaserData he_data [85][72][4]
 
MonitorElementhe_time_rbx
 
HcalDetDiagLaserData hf_data [85][72][4]
 
MonitorElementhf_time_rbx
 
MonitorElementhfEnergy
 
MonitorElementhfEnergyRMS
 
MonitorElementhfTime
 
MonitorElementhfTimeRMS
 
HcalDetDiagLaserData ho_data [85][72][4]
 
MonitorElementho_time_rbx
 
MonitorElementhoEnergy
 
MonitorElementhoEnergyRMS
 
MonitorElementhoTime
 
MonitorElementhoTimeRMS
 
MonitorElementhtmlFolder
 
std::string htmlOutputPath
 
int ievt_
 
edm::InputTag inputLabelDigi_
 
bool IsReference
 
std::map< unsigned int, int > KnownBadCells_
 
double LaserEnergyThreshold
 
double LaserTimingThreshold
 
bool LocalRun
 
MonitorElementmeEVT_
 
MonitorElementmeRUN_
 
int nHB
 
int nHBHEchecks
 
int nHE
 
int nHF
 
int nHFchecks
 
int nHO
 
int nHOchecks
 
bool Online_
 
std::string OutputFilePath
 
bool Overwrite
 
std::string prefixME_
 
EtaPhiHistsProblemCellsByDepth_energy
 
EtaPhiHistsProblemCellsByDepth_energy_val
 
EtaPhiHistsProblemCellsByDepth_timing
 
EtaPhiHistsProblemCellsByDepth_timing_val
 
std::vector< std::string > problemnames_
 
MonitorElementRaddam [56]
 
bool RaddamRun
 
double RaddamThreshold1
 
double RaddamThreshold2
 
edm::InputTag rawDataLabel_
 
MonitorElementrefEnergy2Dhbhehf
 
MonitorElementrefEnergy2Dho
 
std::string ReferenceData
 
std::string ReferenceRun
 
MonitorElementRefRun_
 
MonitorElementrefTime2Dhbhehf
 
MonitorElementrefTime2Dho
 
int run_number
 
TH1F * S1 [56]
 
TH1F * S2 [56]
 
MonitorElementTime2Dhbhehf
 
MonitorElementTime2Dho
 
std::string XmlFilePath
 

Additional Inherited Members

- Public Types inherited from edm::EDAnalyzer
typedef EDAnalyzer ModuleType
 
typedef WorkerT< EDAnalyzerWorkerType
 
- Static Public Member Functions inherited from edm::EDAnalyzer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &)
 
- Protected Member Functions inherited from HcalBaseDQMonitor
virtual void beginJob ()
 
virtual void cleanup (void)
 
virtual void endJob (void)
 
bool IsAllowedCalibType ()
 
bool LumiInOrder (int lumisec)
 
virtual void reset (void)
 
virtual void setup (void)
 
void SetupEtaPhiHists (EtaPhiHists &hh, std::string Name, std::string Units)
 
- Protected Member Functions inherited from edm::EDAnalyzer
CurrentProcessingContext const * currentContext () const
 
- Protected Attributes inherited from HcalBaseDQMonitor
std::vector< int > AllowedCalibTypes_
 
int badChannelStatusMask_
 
int currentLS
 
int currenttype_
 
DQMStoredbe_
 
int debug_
 
bool enableCleanup_
 
bool eventAllowed_
 
bool HBpresent_
 
bool HEpresent_
 
bool HFpresent_
 
bool HOpresent_
 
int ievt_
 
std::map< unsigned int, int > KnownBadCells_
 
int levt_
 
bool makeDiagnostics_
 
MonitorElementmeIevt_
 
MonitorElementmeLevt_
 
bool mergeRuns_
 
MonitorElementmeTevt_
 
MonitorElementmeTevtHist_
 
int NLumiBlocks_
 
bool Online_
 
std::string prefixME_
 
MonitorElementProblemsCurrentLB
 
MonitorElementProblemsVsLB
 
MonitorElementProblemsVsLB_HB
 
MonitorElementProblemsVsLB_HBHEHF
 
MonitorElementProblemsVsLB_HE
 
MonitorElementProblemsVsLB_HF
 
MonitorElementProblemsVsLB_HO
 
bool skipOutOfOrderLS_
 
std::string subdir_
 
int tevt_
 

Detailed Description

Description: [one line class summary]

Implementation: [Notes on implementation]

Definition at line 247 of file HcalDetDiagLaserMonitor.cc.

Constructor & Destructor Documentation

HcalDetDiagLaserMonitor::HcalDetDiagLaserMonitor ( const edm::ParameterSet iConfig)
explicit

Definition at line 372 of file HcalDetDiagLaserMonitor.cc.

References calibDigiLabel_, createHTMLonly, dataset_seq_number, DatasetName, HcalBaseDQMonitor::debug_, emap, edm::ParameterSet::getUntrackedParameter(), htmlOutputPath, ievt_, inputLabelDigi_, IsReference, LaserEnergyThreshold, LaserTimingThreshold, LocalRun, nHB, nHBHEchecks, nHE, nHF, nHFchecks, nHO, nHOchecks, Online_, OutputFilePath, Overwrite, prefixME_, RaddamRun, RaddamThreshold1, RaddamThreshold2, rawDataLabel_, ReferenceData, run_number, HcalBaseDQMonitor::subdir_, and XmlFilePath.

372  {
373  ievt_=-1;
374  emap=0;
376  run_number=-1;
377  IsReference=false;
378  LocalRun=RaddamRun=false;
379  createHTMLonly=false;
380  nHB=nHE=nHO=nHF=0;
382 
383  inputLabelDigi_ = iConfig.getUntrackedParameter<edm::InputTag>("digiLabel",edm::InputTag("hcalDigis"));
384  calibDigiLabel_ = iConfig.getUntrackedParameter<edm::InputTag>("calibDigiLabel",edm::InputTag("hcalDigis"));
385  rawDataLabel_ = iConfig.getUntrackedParameter<edm::InputTag>("RawDataLabel",edm::InputTag("source"));
386 
387  ReferenceData = iConfig.getUntrackedParameter<std::string>("LaserReferenceData" ,"");
388  OutputFilePath = iConfig.getUntrackedParameter<std::string>("OutputFilePath", "");
389  DatasetName = iConfig.getUntrackedParameter<std::string>("LaserDatasetName", "");
390  htmlOutputPath = iConfig.getUntrackedParameter<std::string>("htmlOutputPath", "");
391  XmlFilePath = iConfig.getUntrackedParameter<std::string>("XmlFilePath", "");
392  Online_ = iConfig.getUntrackedParameter<bool> ("online",false);
393  Overwrite = iConfig.getUntrackedParameter<bool> ("Overwrite",true);
394  prefixME_ = iConfig.getUntrackedParameter<std::string>("subSystemFolder","Hcal/");
395  if (prefixME_.size()>0 && prefixME_.substr(prefixME_.size()-1,prefixME_.size())!="/")
396  prefixME_.append("/");
397  subdir_ = iConfig.getUntrackedParameter<std::string>("TaskFolder","DetDiagPedestalMonitor_Hcal/");
398  if (subdir_.size()>0 && subdir_.substr(subdir_.size()-1,subdir_.size())!="/")
399  subdir_.append("/");
400  subdir_=prefixME_+subdir_;
401  debug_ = iConfig.getUntrackedParameter<int>("debug",0);
402 
403  LaserTimingThreshold = iConfig.getUntrackedParameter<double>("LaserTimingThreshold",0.2);
404  LaserEnergyThreshold = iConfig.getUntrackedParameter<double>("LaserEnergyThreshold",0.1);
405  RaddamThreshold1 = iConfig.getUntrackedParameter<double>("RaddamThreshold1",10.0);
406  RaddamThreshold2 = iConfig.getUntrackedParameter<double>("RaddamThreshold2",0.95);
407 }
T getUntrackedParameter(std::string const &, T const &) const
const HcalElectronicsMap * emap
HcalDetDiagLaserMonitor::~HcalDetDiagLaserMonitor ( )

Definition at line 543 of file HcalDetDiagLaserMonitor.cc.

543  {
544 
545 }

Member Function Documentation

void HcalDetDiagLaserMonitor::analyze ( const edm::Event iEvent,
const edm::EventSetup iSetup 
)
privatevirtual

Reimplemented from HcalBaseDQMonitor.

Definition at line 548 of file HcalDetDiagLaserMonitor.cc.

References adc2fC, HcalDetDiagLaserData::add_statistics(), HcalBaseDQMonitor::analyze(), calib, calib_data, calibDigiLabel_, createHTMLonly, HcalRaddamData::CUT1EVNT, HcalRaddamData::CUT2EVNT, FEDRawData::data(), data, HcalBaseDQMonitor::dbe_, alignCSCRings::e, eta(), MonitorElement::Fill(), HcalObjRepresent::Fill(), fillHistos(), fillProblems(), edm::Event::getByLabel(), edm::Event::getByType(), hb_data, hc_HBHEHPD, hc_HFPMT, hc_HOHPD, hc_RADDAM, HcalBarrel, HcalEndcap, HcalForward, HcalOuter, he_data, hf_data, ho_data, i, edm::EventBase::id(), ievt_, inputLabelDigi_, edm::HandleBase::isValid(), j, gen::k, LocalRun, FEDNumbering::MAXHCALFEDID, meEVT_, meRUN_, FEDNumbering::MINHCALFEDID, N, Online_, edm::EventBase::orbitNumber(), phi, Raddam, RaddamRun, RaddamThreshold1, RaddamThreshold2, lumiPlot::rawdata, rawDataLabel_, HcalBaseDQMonitor::reset(), edm::EventID::run(), run_number, HcalRaddamData::s1_adc, S2, HcalRaddamData::s2_adc, SaveReference(), FEDRawData::size(), HcalRaddamData::TOTEVNT, and relativeConstraints::value.

548  {
549  if(createHTMLonly) return;
550  HcalBaseDQMonitor::analyze(iEvent,iSetup); // base class increments ievt_, etc. counters
551 
552 int eta,phi,depth,nTS;
553 static bool HBHEseq,HOseq,HFseq;
554 static int lastHBHEorbit,lastHOorbit,lastHForbit,nChecksHBHE,nChecksHO,nChecksHF,ievt_hbhe,ievt_ho,ievt_hf;
555  if(ievt_==-1){
556  ievt_=0;HBHEseq=HOseq=HFseq=false; lastHBHEorbit=lastHOorbit=lastHForbit=-1;nChecksHBHE=nChecksHO=nChecksHF=0;
557  ievt_hbhe=0,ievt_ho=0,ievt_hf=0;
558  }
559 
560  if(!dbe_) return;
561  bool LaserEvent=false;
562  bool LaserRaddam=false;
563  int orbit=iEvent.orbitNumber();
564  meRUN_->Fill(iEvent.id().run());
565  // for local runs
566  edm::Handle<HcalTBTriggerData> trigger_data;
567  iEvent.getByType(trigger_data);
568  if(trigger_data.isValid()){
569  if(trigger_data->wasLaserTrigger()) LaserEvent=true;
570  LocalRun=true;
571  }
572  if(!LocalRun && Online_){
573  if(HBHEseq && (orbit-lastHBHEorbit)>(11223*10) && ievt_hbhe>40){
574  HBHEseq=false;
578  nChecksHBHE++;
579  ievt_hbhe=0;
580  for(int i=0;i<85;i++)for(int j=0;j<72;j++)for(int k=0;k<4;k++) hb_data[i][j][k].reset();
581  for(int i=0;i<85;i++)for(int j=0;j<72;j++)for(int k=0;k<4;k++) he_data[i][j][k].reset();
582  }
583  if(HOseq && (orbit-lastHOorbit)>(11223*10) && ievt_ho>40){
584  HOseq=false;
587  nChecksHO++;
588  ievt_ho=0;
589  for(int i=0;i<85;i++)for(int j=0;j<72;j++)for(int k=0;k<4;k++) ho_data[i][j][k].reset();
590  }
591  if(HFseq && (orbit-lastHForbit)>(11223*10) && ievt_hf>40){
592  HFseq=false;
595  nChecksHF++;
596  ievt_hf=0;
597  if(nChecksHF==1 || (nChecksHF>1 && ((nChecksHF-1)%12)==0)){
598  SaveReference();
599  }
600  for(int i=0;i<85;i++)for(int j=0;j<72;j++)for(int k=0;k<4;k++) hf_data[i][j][k].reset();
601  }
602  }
603 
604  // Abort Gap laser
605  if(LocalRun==false || LaserEvent==false){
607  iEvent.getByLabel(rawDataLabel_ ,rawdata);
608  // edm::Handle<FEDRawDataCollection> rawdata;
609  // iEvent.getByType(rawdata);
610  //checking FEDs for calibration information
612  const FEDRawData& fedData = rawdata->FEDData(i) ;
613  if ( fedData.size() < 24 ) continue ;
614  int value = ((const HcalDCCHeader*)(fedData.data()))->getCalibType() ;
615  if(value==hc_HBHEHPD){ HBHEseq=true; HOseq=HFseq=false; lastHBHEorbit=orbit; ievt_hbhe++; }
616  if(value==hc_HOHPD){ HOseq=true; HBHEseq=HFseq=false; lastHOorbit=orbit; ievt_ho++; }
617  if(value==hc_HFPMT){ HFseq=true; HBHEseq=HOseq=false; lastHForbit=orbit; ievt_hf++; }
618 
619  if(value==hc_HBHEHPD || value==hc_HOHPD || value==hc_HFPMT){ LaserEvent=true; break;}
620  if(value==hc_RADDAM){ LaserEvent=true; LaserRaddam=true; break;}
621  }
622  }
623  if(!LaserEvent) return;
625  iEvent.getByLabel(inputLabelDigi_,hbhe);
627  iEvent.getByLabel(inputLabelDigi_,ho);
629  iEvent.getByLabel(inputLabelDigi_,hf);
631  iEvent.getByLabel(calibDigiLabel_, calib);
632 
633  if(LocalRun && LaserEvent){
634  int N=0;
635  if(hf.isValid()){
636  for(HFDigiCollection::const_iterator digi=hf->begin();digi!=hf->end();digi++){
637  eta=digi->id().ieta(); phi=digi->id().iphi(); depth=digi->id().depth();
638  float e=0;
639  for(int i=0;i<digi->size();i++) e+=adc2fC[digi->sample(i).adc()&0xff]-2.5;
640  if(e>40){ N++;}
641  }
642  }
643  if(N>50 && N<57){ RaddamRun=true; /*LaserRaddam=true;*/}
644  }
645  if(RaddamRun){
646  if(hf.isValid()){
647  for(HFDigiCollection::const_iterator digi=hf->begin();digi!=hf->end();digi++){
648  eta=digi->id().ieta(); phi=digi->id().iphi(); depth=digi->id().depth(); nTS=digi->size();
649  int N;
650  for(N=0;N<56;N++)if(eta==RADDAM_CH[N].eta && phi==RADDAM_CH[N].phi && depth==RADDAM_CH[N].depth) break;
651  if(N==56) continue;
652  float max1=0,max2=0;
653  int nmax1=0,nmax2=0;
654  for(int i=0;i<nTS;i++){
655  if(max1<adc2fC[digi->sample(i).adc()&0xff]){ nmax1=i; max1=adc2fC[digi->sample(i).adc()&0xff]; }
656  }
657  Raddam_data[N].TOTEVNT++;
658  for(int i=0;i<nTS;i++){
659  if(i==nmax1) continue;
660  if(max2<adc2fC[digi->sample(i).adc()&0xff]){ nmax2=i; max2=adc2fC[digi->sample(i).adc()&0xff]; }
661  }
662  if(nmax1>nmax2){
663  int tmp1=nmax2;
664  nmax2=nmax1;nmax1=tmp1;
665  }
666  if(nmax1==0 || nmax2==(nTS-1)) continue;
667  if(nmax2!=(nmax1+1)) continue;
668 
669  if(max1<RaddamThreshold1 || max2<RaddamThreshold1) continue;
671  max1-=2.5; max2-=2.5;
672  float S2=max1+max2;
673  float S4=S2+adc2fC[digi->sample(nmax1-1).adc()&0xff]+adc2fC[digi->sample(nmax2+1).adc()&0xff]-5.0;
674  if((S2/S4)<RaddamThreshold2) continue;
676  Raddam_data[N].s1_adc[digi->sample(nmax1).adc()&0xff]++;
677  Raddam_data[N].s2_adc[digi->sample(nmax2).adc()&0xff]++;
678  }
679  }
680  }
681 
682  meEVT_->Fill(++ievt_);
683  run_number=iEvent.id().run();
684  double data[20];
685  if(!LaserRaddam){
686  if(hbhe.isValid()){
687  for(HBHEDigiCollection::const_iterator digi=hbhe->begin();digi!=hbhe->end();digi++){
688  eta=digi->id().ieta(); phi=digi->id().iphi(); depth=digi->id().depth(); nTS=digi->size();
689  double ped=(adc2fC[digi->sample(0).adc()&0xff]+adc2fC[digi->sample(1).adc()&0xff])/2.0;
690  if(digi->id().subdet()==HcalBarrel){
691  for(int i=0;i<nTS;i++) data[i]=adc2fC[digi->sample(i).adc()&0xff]-ped;
692  hb_data[eta+42][phi-1][depth-1].add_statistics(data,nTS);
693  }
694  if(digi->id().subdet()==HcalEndcap){
695  for(int i=0;i<nTS;i++) data[i]=adc2fC[digi->sample(i).adc()&0xff]-ped;
696  he_data[eta+42][phi-1][depth-1].add_statistics(data,nTS);
697  }
698  }
699  }
700  if(ho.isValid()){
701  for(HODigiCollection::const_iterator digi=ho->begin();digi!=ho->end();digi++){
702  eta=digi->id().ieta(); phi=digi->id().iphi(); depth=digi->id().depth(); nTS=digi->size();
703  double ped=(adc2fC[digi->sample(0).adc()&0xff]+adc2fC[digi->sample(1).adc()&0xff])/2.0;
704  if((eta>=11 && eta<=15 && phi>=59 && phi<=70) || (eta>=5 && eta<=10 && phi>=47 && phi<=58)){
705  for(int i=0;i<nTS;i++) data[i]=adc2fC[digi->sample(i).adc()&0xff]-ped;
706  }else{
707  for(int i=0;i<nTS;i++) data[i]=adc2fC[digi->sample(i).adc()&0xff]-ped;
708  }
709  ho_data[eta+42][phi-1][depth-1].add_statistics(data,nTS);
710  }
711  }
712  if(hf.isValid()){
713  for(HFDigiCollection::const_iterator digi=hf->begin();digi!=hf->end();digi++){
714  eta=digi->id().ieta(); phi=digi->id().iphi(); depth=digi->id().depth(); nTS=digi->size();
715  double ped=adc2fC[digi->sample(0).adc()&0xff];
716  for(int i=0;i<nTS;i++) data[i]=adc2fC[digi->sample(i).adc()&0xff]-ped;
717  hf_data[eta+42][phi-1][depth-1].add_statistics(data,nTS);
718  }
719  }
720  if(calib.isValid())for(HcalCalibDigiCollection::const_iterator digi=calib->begin();digi!=calib->end();digi++){
721  if(digi->id().cboxChannel()!=0 || digi->id().hcalSubdet()==0) continue;
722  nTS=digi->size();
723  float e=0;
724  for(int i=0;i<nTS;i++){ data[i]=adc2fC[digi->sample(i).adc()&0xff]; e+=data[i];}
725  if(e<15000) calib_data[digi->id().hcalSubdet()][digi->id().ieta()+2][digi->id().iphi()-1].add_statistics(data,nTS);
726  }
727  }else{ //Raddam
728  if(hf.isValid()){
729  for(HFDigiCollection::const_iterator digi=hf->begin();digi!=hf->end();digi++){
730  eta=digi->id().ieta(); phi=digi->id().iphi(); depth=digi->id().depth(); nTS=digi->size();
731  int N;
732  for(N=0;N<56;N++)if(eta==RADDAM_CH[N].eta && phi==RADDAM_CH[N].phi && depth==RADDAM_CH[N].depth) break;
733  if(N==56) continue;
734  for(int i=0;i<nTS;i++) Raddam[N]->Fill(i,adc2fC[digi->sample(i).adc()&0xff]-2.5);
735 
736  }
737  }
738  }
739 }
RunNumber_t run() const
Definition: EventID.h:42
int i
Definition: DBlmapReader.cc:9
void add_statistics(double *data, int nTS)
virtual void analyze(const edm::Event &e, const edm::EventSetup &c)
static const float adc2fC[128]
std::vector< T >::const_iterator const_iterator
bool getByType(Handle< PROD > &result) const
Definition: Event.h:398
HcalRaddamData Raddam_data[56]
T eta() const
size_t size() const
Lenght of the data buffer in bytes.
Definition: FEDRawData.h:49
void Fill(long long x)
Raddam_ch RADDAM_CH[56]
MVATrainerComputer * calib
Definition: MVATrainer.cc:64
void Fill(HcalDetId &id, double val, std::vector< TH2F > &depth)
int j
Definition: DBlmapReader.cc:9
int orbitNumber() const
Definition: EventBase.h:63
bool isValid() const
Definition: HandleBase.h:76
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
Definition: Event.h:356
int k[5][pyjets_maxn]
HcalDetDiagLaserData hb_data[85][72][4]
#define N
Definition: blowfish.cc:9
virtual void reset(void)
edm::EventID id() const
Definition: EventBase.h:56
HcalDetDiagLaserData hf_data[85][72][4]
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:82
const unsigned char * data() const
Return a const pointer to the beginning of the data buffer.
Definition: FEDRawData.cc:29
dictionary rawdata
Definition: lumiPlot.py:393
HcalDetDiagLaserData he_data[85][72][4]
HcalDetDiagLaserData ho_data[85][72][4]
HcalDetDiagLaserData calib_data[5][5][72]
Definition: DDAxes.h:10
void HcalDetDiagLaserMonitor::beginLuminosityBlock ( const edm::LuminosityBlock lumiSeg,
const edm::EventSetup c 
)
privatevirtual

Reimplemented from HcalBaseDQMonitor.

Definition at line 2023 of file HcalDetDiagLaserMonitor.cc.

2023 {}
void HcalDetDiagLaserMonitor::beginRun ( const edm::Run run,
const edm::EventSetup c 
)
privatevirtual

Reimplemented from HcalBaseDQMonitor.

Definition at line 408 of file HcalDetDiagLaserMonitor.cc.

References DQMStore::book1D(), DQMStore::book2D(), DQMStore::bookInt(), DQMStore::bookString(), createHTMLonly, dataset_seq_number, DatasetName, HcalBaseDQMonitor::dbe_, EtaPhiHists::depth, emap, Energy2Dhbhehf, Energy2Dho, eta(), MonitorElement::Fill(), edm::EventSetup::get(), HcalCondObjectContainer< Item >::getAllChannels(), reco::JetExtendedAssociation::getValue(), HcalCondObjectContainer< Item >::getValues(), hb_time_rbx, hbheEnergy, hbheEnergyRMS, hbheTime, hbheTimeRMS, DetId::Hcal, HcalChannelStatus::HcalCellMask, HcalChannelStatus::HcalCellOff, he_time_rbx, hf_time_rbx, hfEnergy, hfEnergyRMS, hfTime, hfTimeRMS, ho_time_rbx, hoEnergy, hoEnergyRMS, hoTime, hoTimeRMS, htmlFolder, htmlOutputPath, i, KnownBadCells_, LoadDataset(), LoadReference(), meEVT_, meRUN_, mergeVDriftHistosByStation::name, nHB, nHE, nHF, nHO, AlCaHLTBitMon_ParallelJobs::p, phi, prefixME_, ProblemCellsByDepth_energy, ProblemCellsByDepth_energy_val, ProblemCellsByDepth_timing, ProblemCellsByDepth_timing_val, problemnames_, edm::ESHandle< class >::product(), Raddam, refEnergy2Dhbhehf, refEnergy2Dho, ReferenceRun, RefRun_, refTime2Dhbhehf, refTime2Dho, run_number, MonitorElement::setAxisRange(), MonitorElement::setAxisTitle(), MonitorElement::setBinLabel(), DQMStore::setCurrentFolder(), EtaPhiHists::setup(), HcalBaseDQMonitor::setup(), ntuplemaker::status, HcalBaseDQMonitor::subdir_, Time2Dhbhehf, and Time2Dho.

408  {
410  c.get<HcalChannelQualityRcd>().get(p);
411  HcalChannelQuality* chanquality= new HcalChannelQuality(*p.product());
412  std::vector<DetId> mydetids = chanquality->getAllChannels();
413  KnownBadCells_.clear();
414 
415  for (std::vector<DetId>::const_iterator i = mydetids.begin();i!=mydetids.end();++i){
416  if (i->det()!=DetId::Hcal) continue; // not an hcal cell
417  HcalDetId id=HcalDetId(*i);
418  int status=(chanquality->getValues(id))->getValue();
420  KnownBadCells_[id.rawId()]=status;
421  }
422  }
423 
424  edm::ESHandle<HcalDbService> conditions_;
425  c.get<HcalDbRecord>().get(conditions_);
426  emap=conditions_->getHcalMapping();
427 
429  if (!dbe_) return;
430  std::string name;
431 
433  meEVT_ = dbe_->bookInt("HcalDetDiagLaserMonitor Event Number");
434  meRUN_ = dbe_->bookInt("HcalDetDiagLaserMonitor Run Number");
435 
436  ReferenceRun="UNKNOWN";
437  LoadReference();
438  LoadDataset();
439  if(DatasetName.size()>0 && createHTMLonly){
440  char str[200]; sprintf(str,"%sHcalDetDiagLaserData_run%i_%i/",htmlOutputPath.c_str(),run_number,dataset_seq_number);
441  htmlFolder=dbe_->bookString("HcalDetDiagLaserMonitor HTML folder",str);
442  MonitorElement *me;
443  dbe_->setCurrentFolder(prefixME_+"HcalInfo");
444  me=dbe_->bookInt("HBpresent");
445  if(nHB>0) me->Fill(1);
446  me=dbe_->bookInt("HEpresent");
447  if(nHE>0) me->Fill(1);
448  me=dbe_->bookInt("HOpresent");
449  if(nHO>0) me->Fill(1);
450  me=dbe_->bookInt("HFpresent");
451  if(nHF>0) me->Fill(1);
452  }
454  ProblemCellsByDepth_timing->setup(dbe_," Problem Bad Laser Timing");
455  for(unsigned int i=0;i<ProblemCellsByDepth_timing->depth.size();i++)
456  problemnames_.push_back(ProblemCellsByDepth_timing->depth[i]->getName());
458  ProblemCellsByDepth_energy->setup(dbe_," Problem Bad Laser Energy");
459  for(unsigned int i=0;i<ProblemCellsByDepth_energy->depth.size();i++)
460  problemnames_.push_back(ProblemCellsByDepth_energy->depth[i]->getName());
461 
462  dbe_->setCurrentFolder(subdir_+"Summary Plots");
463 
464  name="HBHE Laser Energy Distribution"; hbheEnergy = dbe_->book1D(name,name,200,0,3000);
465  name="HBHE Laser Timing Distribution"; hbheTime = dbe_->book1D(name,name,200,0,10);
466  name="HBHE Laser Energy RMS_div_Energy Distribution"; hbheEnergyRMS = dbe_->book1D(name,name,200,0,0.5);
467  name="HBHE Laser Timing RMS Distribution"; hbheTimeRMS = dbe_->book1D(name,name,200,0,1);
468  name="HO Laser Energy Distribution"; hoEnergy = dbe_->book1D(name,name,200,0,3000);
469  name="HO Laser Timing Distribution"; hoTime = dbe_->book1D(name,name,200,0,10);
470  name="HO Laser Energy RMS_div_Energy Distribution"; hoEnergyRMS = dbe_->book1D(name,name,200,0,0.5);
471  name="HO Laser Timing RMS Distribution"; hoTimeRMS = dbe_->book1D(name,name,200,0,1);
472  name="HF Laser Energy Distribution"; hfEnergy = dbe_->book1D(name,name,200,0,3000);
473  name="HF Laser Timing Distribution"; hfTime = dbe_->book1D(name,name,200,0,10);
474  name="HF Laser Energy RMS_div_Energy Distribution"; hfEnergyRMS = dbe_->book1D(name,name,200,0,0.7);
475  name="HF Laser Timing RMS Distribution"; hfTimeRMS = dbe_->book1D(name,name,200,0,1);
476 
477  name="Laser Timing HBHEHF"; Time2Dhbhehf = dbe_->book2D(name,name,87,-43,43,74,0,73);
478  name="Laser Timing HO"; Time2Dho = dbe_->book2D(name,name,33,-16,16,74,0,73);
479  name="Laser Energy HBHEHF"; Energy2Dhbhehf = dbe_->book2D(name,name,87,-43,43,74,0,73);
480  name="Laser Energy HO"; Energy2Dho = dbe_->book2D(name,name,33,-16,16,74,0,73);
481  name="HBHEHF Laser (Timing-Ref)+1"; refTime2Dhbhehf = dbe_->book2D(name,name,87,-43,43,74,0,73);
482  name="HO Laser (Timing-Ref)+1"; refTime2Dho = dbe_->book2D(name,name,33,-16,16,74,0,73);
483  name="HBHEHF Laser Energy_div_Ref"; refEnergy2Dhbhehf = dbe_->book2D(name,name,87,-43,43,74,0,73);
484  name="HO Laser Energy_div_Ref"; refEnergy2Dho = dbe_->book2D(name,name,33,-16,16,74,0,73);
485 
486  name="HB RBX average Time-Ref"; hb_time_rbx = dbe_->book1D(name,name,36,0.5,36.5);
487  name="HE RBX average Time-Ref"; he_time_rbx = dbe_->book1D(name,name,36,0.5,36.5);
488  name="HO RBX average Time-Ref"; ho_time_rbx = dbe_->book1D(name,name,36,0.5,36.5);
489  name="HF RoBox average Time-Ref"; hf_time_rbx = dbe_->book1D(name,name,24,0.5,24.5);
490 
491  char str[200];
492  for(int i=1;i<=18;i++){ sprintf(str,"HBM%02i",i); hb_time_rbx->setBinLabel(i,str); }
493  for(int i=1;i<=18;i++){ sprintf(str,"HBP%02i",i); hb_time_rbx->setBinLabel(i+18,str); }
494  for(int i=1;i<=18;i++){ sprintf(str,"HEM%02i",i); he_time_rbx->setBinLabel(i,str); }
495  for(int i=1;i<=18;i++){ sprintf(str,"HEP%02i",i); he_time_rbx->setBinLabel(i+18,str); }
496  for(int i=1;i<=12;i++){ sprintf(str,"HFM%02i",i); hf_time_rbx->setBinLabel(i,str); }
497  for(int i=1;i<=12;i++){ sprintf(str,"HFP%02i",i); hf_time_rbx->setBinLabel(i+12,str); }
498  for(int i=1;i<=6;i++){ sprintf(str,"HO2M%02i",i*2); ho_time_rbx->setBinLabel(i,str); }
499  for(int i=1;i<=6;i++){ sprintf(str,"HO1M%02i",i*2); ho_time_rbx->setBinLabel(i+6,str); }
500  for(int i=1;i<=12;i++){ sprintf(str,"HO0%02i",i); ho_time_rbx->setBinLabel(i+12,str); }
501  for(int i=1;i<=6;i++){ sprintf(str,"HO1P%02i",i*2); ho_time_rbx->setBinLabel(i+24,str); }
502  for(int i=1;i<=6;i++){ sprintf(str,"HO2P%02i",i*2); ho_time_rbx->setBinLabel(i+30,str); }
503 
504  Time2Dhbhehf->setAxisTitle("i#eta",1);
505  Time2Dhbhehf->setAxisTitle("i#phi",2);
506  Time2Dho->setAxisTitle("i#eta",1);
507  Time2Dho->setAxisTitle("i#phi",2);
508  Energy2Dhbhehf->setAxisTitle("i#eta",1);
509  Energy2Dhbhehf->setAxisTitle("i#phi",2);
510  Energy2Dho->setAxisTitle("i#eta",1);
511  Energy2Dho->setAxisTitle("i#phi",2);
512  refTime2Dhbhehf->setAxisTitle("i#eta",1);
513  refTime2Dhbhehf->setAxisTitle("i#phi",2);
514  refTime2Dho->setAxisTitle("i#eta",1);
515  refTime2Dho->setAxisTitle("i#phi",2);
516  refEnergy2Dhbhehf->setAxisTitle("i#eta",1);
517  refEnergy2Dhbhehf->setAxisTitle("i#phi",2);
518  refEnergy2Dho->setAxisTitle("i#eta",1);
519  refEnergy2Dho->setAxisTitle("i#phi",2);
520 
522  refTime2Dho->setAxisRange(0,2,3);
523  refEnergy2Dhbhehf->setAxisRange(0.5,1.5,3);
524  refEnergy2Dho->setAxisRange(0.5,1.5,3);
525 
527  RefRun_= dbe_->bookString("HcalDetDiagLaserMonitor Reference Run",ReferenceRun);
528 
529  dbe_->setCurrentFolder(subdir_+"Raddam Plots");
530  for(int i=0;i<56;i++){
531  sprintf(str,"RADDAM (%i %i)",RADDAM_CH[i].eta,RADDAM_CH[i].phi);
532  Raddam[i] = dbe_->book1D(str,str,10,-0.5,9.5);
533  }
534 
535  dbe_->setCurrentFolder(subdir_+"Plots for client");
537  ProblemCellsByDepth_timing_val->setup(dbe_," Laser Timing difference");
539  ProblemCellsByDepth_energy_val->setup(dbe_," Laser Energy difference");
540 }
int i
Definition: DBlmapReader.cc:9
MonitorElement * book1D(const char *name, const char *title, int nchX, double lowX, double highX)
Book 1D histogram.
Definition: DQMStore.cc:717
void setAxisRange(double xmin, double xmax, int axis=1)
set x-, y- or z-axis range (axis=1, 2, 3 respectively)
const HcalElectronicsMap * emap
void setup(DQMStore *&m_dbe, std::string Name, std::string Units="")
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 eta() const
std::map< unsigned int, int > KnownBadCells_
void Fill(long long x)
Raddam_ch RADDAM_CH[56]
std::vector< MonitorElement * > depth
MonitorElement * bookString(const char *name, const char *value)
Book string.
Definition: DQMStore.cc:683
std::vector< DetId > getAllChannels() const
const T & get() const
Definition: EventSetup.h:55
T const * product() const
Definition: ESHandle.h:62
const JetExtendedData & getValue(const Container &, const reco::JetBaseRef &)
get value for the association. Throw exception if no association found
tuple status
Definition: ntuplemaker.py:245
MonitorElement * bookInt(const char *name)
Book int.
Definition: DQMStore.cc:624
MonitorElement * book2D(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY)
Book 2D histogram.
Definition: DQMStore.cc:845
virtual void setup(void)
const Item * getValues(DetId fId) const
void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)
std::vector< std::string > problemnames_
void setCurrentFolder(const std::string &fullpath)
Definition: DQMStore.cc:429
Definition: DDAxes.h:10
void HcalDetDiagLaserMonitor::endLuminosityBlock ( const edm::LuminosityBlock lumiSeg,
const edm::EventSetup c 
)
privatevirtual

Reimplemented from HcalBaseDQMonitor.

Definition at line 2024 of file HcalDetDiagLaserMonitor.cc.

2024 {}
void HcalDetDiagLaserMonitor::endRun ( const edm::Run run,
const edm::EventSetup c 
)
privatevirtual

Reimplemented from HcalBaseDQMonitor.

Definition at line 2007 of file HcalDetDiagLaserMonitor.cc.

References createHTMLonly, fillHistos(), fillProblems(), HcalBarrel, HcalEndcap, HcalForward, HcalOuter, ievt_, LocalRun, Online_, RaddamRun, SaveRaddamData(), and SaveReference().

void HcalDetDiagLaserMonitor::fillHistos ( int  sd)
private

Definition at line 1111 of file HcalDetDiagLaserMonitor.cc.

References abs, Energy2Dhbhehf, Energy2Dho, eta(), MonitorElement::Fill(), get_ave_rbx(), HcalDetDiagLaserData::get_average_amp(), HcalDetDiagLaserData::get_average_time(), hb_data, hb_time_rbx, hbheEnergy, hbheEnergyRMS, hbheTime, hbheTimeRMS, HcalBarrel, HcalEndcap, HcalForward, HcalOuter, he_data, he_time_rbx, hf_data, hf_time_rbx, hfEnergy, hfEnergyRMS, hfTime, hfTimeRMS, ho_data, ho_time_rbx, hoEnergy, hoEnergyRMS, hoTime, hoTimeRMS, i, isSiPM(), max(), min, phi, refEnergy2Dhbhehf, refEnergy2Dho, refTime2Dhbhehf, refTime2Dho, MonitorElement::Reset(), plotscripts::rms(), MonitorElement::setAxisRange(), MonitorElement::setBinContent(), MonitorElement::setBinError(), cond::rpcobgas::time, Time2Dhbhehf, and Time2Dho.

Referenced by analyze(), and endRun().

1111  {
1112  if(sd==HcalBarrel || sd==HcalEndcap){
1113  hbheEnergy->Reset();
1114  hbheTime->Reset();
1115  hbheEnergyRMS->Reset();
1116  hbheTimeRMS->Reset();
1117  hb_time_rbx->Reset();
1118  he_time_rbx->Reset();
1119  }
1120  if(sd==HcalOuter){
1121  hoEnergy->Reset();
1122  hoTime->Reset();
1123  hoEnergyRMS->Reset();
1124  hoTimeRMS->Reset();
1125  Time2Dho->Reset();
1126  Energy2Dho->Reset();
1127  refTime2Dho->Reset();
1128  refEnergy2Dho->Reset();
1129  ho_time_rbx->Reset();
1130  }
1131  if(sd==HcalForward){
1132  hfEnergy->Reset();
1133  hfTime->Reset();
1134  hfEnergyRMS->Reset();
1135  hfTimeRMS->Reset();
1136  hf_time_rbx->Reset();
1137  }
1138  if(sd==HcalBarrel || sd==HcalEndcap){
1139  // HB histograms
1140  for(int eta=-16;eta<=16;eta++) for(int phi=1;phi<=72;phi++){
1141  double T=0,nT=0,E=0,nE=0;
1142  for(int depth=1;depth<=2;depth++){
1143  if(hb_data[eta+42][phi-1][depth-1].get_statistics()>10){
1144  double ave=0;
1145  double rms=0;
1146  double time=0;
1147  double time_rms=0;
1148  hb_data[eta+42][phi-1][depth-1].get_average_amp(&ave,&rms);
1149  hb_data[eta+42][phi-1][depth-1].get_average_time(&time,&time_rms);
1150  hbheEnergy->Fill(ave);
1151  if(ave>0)hbheEnergyRMS->Fill(rms/ave);
1152  hbheTime->Fill(time);
1153  hbheTimeRMS->Fill(time_rms);
1154  T+=time; nT++; E+=ave; nE++;
1155  }
1156  }
1157  if(nT>0){Time2Dhbhehf->setBinContent(eta+44,phi+1,T/nT);Energy2Dhbhehf->setBinContent(eta+44,phi+1,E/nE); }
1158  }
1159  // HE histograms
1160  for(int eta=-29;eta<=29;eta++) for(int phi=1;phi<=72;phi++){
1161  double T=0,nT=0,E=0,nE=0;
1162  for(int depth=1;depth<=3;depth++){
1163  if(he_data[eta+42][phi-1][depth-1].get_statistics()>10){
1164  double ave=0; double rms=0; double time=0; double time_rms=0;
1165  he_data[eta+42][phi-1][depth-1].get_average_amp(&ave,&rms);
1166  he_data[eta+42][phi-1][depth-1].get_average_time(&time,&time_rms);
1167  hbheEnergy->Fill(ave);
1168  if(ave>0)hbheEnergyRMS->Fill(rms/ave);
1169  hbheTime->Fill(time);
1170  hbheTimeRMS->Fill(time_rms);
1171  T+=time; nT++; E+=ave; nE++;
1172  }
1173  }
1174  if(nT>0 && abs(eta)>16 ){Time2Dhbhehf->setBinContent(eta+44,phi+1,T/nT); Energy2Dhbhehf->setBinContent(eta+44,phi+1,E/nE); }
1175  if(nT>0 && abs(eta)>20 ){Time2Dhbhehf->setBinContent(eta+44,phi+2,T/nT); Energy2Dhbhehf->setBinContent(eta+44,phi+2,E/nE);}
1176  }
1177  }
1178  if(sd==HcalForward){
1179  // HF histograms
1180  for(int eta=-42;eta<=42;eta++) for(int phi=1;phi<=72;phi++){
1181  double T=0,nT=0,E=0,nE=0;
1182  for(int depth=1;depth<=2;depth++){
1183  if(hf_data[eta+42][phi-1][depth-1].get_statistics()>10){
1184  double ave=0; double rms=0; double time=0; double time_rms=0;
1185  hf_data[eta+42][phi-1][depth-1].get_average_amp(&ave,&rms);
1186  hf_data[eta+42][phi-1][depth-1].get_average_time(&time,&time_rms);
1187  hfEnergy->Fill(ave);
1188  if(ave>0)hfEnergyRMS->Fill(rms/ave);
1189  hfTime->Fill(time);
1190  T+=time; nT++; E+=ave; nE++;
1191  hfTimeRMS->Fill(time_rms);
1192  }
1193  }
1194  if(nT>0 && abs(eta)>29 ){ Time2Dhbhehf->setBinContent(eta+44,phi+1,T/nT); Time2Dhbhehf->setBinContent(eta+44,phi+2,T/nT);}
1195  if(nT>0 && abs(eta)>29 ){ Energy2Dhbhehf->setBinContent(eta+44,phi+1,E/nE); Energy2Dhbhehf->setBinContent(eta+44,phi+2,E/nE);}
1196  }
1197  }
1198  if(sd==HcalOuter){
1199  // HO histograms
1200  for(int eta=-10;eta<=15;eta++) for(int phi=1;phi<=72;phi++){
1201  if(eta>10 && !isSiPM(eta,phi,4)) continue;
1202  double T=0,nT=0,E=0,nE=0;
1203  for(int depth=4;depth<=4;depth++){
1204  if(ho_data[eta+42][phi-1][depth-1].get_statistics()>10){
1205  double ave=0; double rms=0; double time=0; double time_rms=0;
1206  ho_data[eta+42][phi-1][depth-1].get_average_amp(&ave,&rms);
1207  ho_data[eta+42][phi-1][depth-1].get_average_time(&time,&time_rms);
1208  hoEnergy->Fill(ave);
1209  if(ave>0)hoEnergyRMS->Fill(rms/ave);
1210  hoTime->Fill(time);
1211  T+=time; nT++; E+=ave; nE++;
1212  hoTimeRMS->Fill(time_rms);
1213  }
1214  }
1215  if(nT>0){ Time2Dho->Fill(eta,phi,T/nT); Energy2Dho->Fill(eta,phi+1,E/nE) ;}
1216  }
1217  }
1218 
1219  // compare with reference...
1220  if(sd==HcalBarrel || sd==HcalEndcap){
1221  for(int eta=-16;eta<=16;eta++) for(int phi=1;phi<=72;phi++){
1222  double T=0,nT=0,E=0,nE=0;
1223  for(int depth=1;depth<=2;depth++){
1224  if(hb_data[eta+42][phi-1][depth-1].get_statistics()>10){
1225  double val=0,rms=0,time=0,time_rms=0;
1226  double VAL=0,RMS=0,TIME=0,TIME_RMS=0;
1227  if(!hb_data[eta+42][phi-1][depth-1].get_reference(&val,&rms,&time,&time_rms)) continue;
1228  if(!hb_data[eta+42][phi-1][depth-1].get_average_amp(&VAL,&RMS)) continue;
1229  if(!hb_data[eta+42][phi-1][depth-1].get_average_time(&TIME,&TIME_RMS)) continue;
1230  E+=VAL/val; nE++;
1231  T+=TIME-time; nT++;
1232  }
1233  }
1234  if(nE>0) refEnergy2Dhbhehf->setBinContent(eta+44,phi+1,E/nE);
1235  if(nT>0){ double TTT=T/nT+1; if(TTT<0.01) TTT=0.01; refTime2Dhbhehf->setBinContent(eta+44,phi+1,TTT); }
1236  }
1237  for(int eta=-29;eta<=29;eta++) for(int phi=1;phi<=72;phi++){
1238  double T=0,nT=0,E=0,nE=0;
1239  for(int depth=1;depth<=3;depth++){
1240  if(he_data[eta+42][phi-1][depth-1].get_statistics()>10){
1241  double val=0,rms=0,time=0,time_rms=0;
1242  double VAL=0,RMS=0,TIME=0,TIME_RMS=0;
1243  if(!he_data[eta+42][phi-1][depth-1].get_reference(&val,&rms,&time,&time_rms)) continue;
1244  if(!he_data[eta+42][phi-1][depth-1].get_average_amp(&VAL,&RMS)) continue;
1245  if(!he_data[eta+42][phi-1][depth-1].get_average_time(&TIME,&TIME_RMS)) continue;
1246  E+=VAL/val; nE++;
1247  T+=TIME-time; nT++;
1248  }
1249  }
1250  if(nE>0 && abs(eta)>16) refEnergy2Dhbhehf->setBinContent(eta+44,phi+1,E/nE);
1251  if(nT>0 && abs(eta)>16){ double TTT=T/nT+1; if(TTT<0.01) TTT=0.01; refTime2Dhbhehf->setBinContent(eta+44,phi+1,TTT); }
1252  if(nE>0 && abs(eta)>20) refEnergy2Dhbhehf->setBinContent(eta+44,phi+2,E/nE);
1253  if(nT>0 && abs(eta)>20){ double TTT=T/nT+1; if(TTT<0.01) TTT=0.01; refTime2Dhbhehf->setBinContent(eta+44,phi+2,TTT); }
1254  }
1255  }
1256  if(sd==HcalForward){
1257  for(int eta=-42;eta<=42;eta++) for(int phi=1;phi<=72;phi++){
1258  double T=0,nT=0,E=0,nE=0;
1259  for(int depth=1;depth<=2;depth++){
1260  if(hf_data[eta+42][phi-1][depth-1].get_statistics()>10){
1261  double val=0,rms=0,time=0,time_rms=0;
1262  double VAL=0,RMS=0,TIME=0,TIME_RMS=0;
1263  if(!hf_data[eta+42][phi-1][depth-1].get_reference(&val,&rms,&time,&time_rms)) continue;
1264  if(!hf_data[eta+42][phi-1][depth-1].get_average_amp(&VAL,&RMS)) continue;
1265  if(!hf_data[eta+42][phi-1][depth-1].get_average_time(&TIME,&TIME_RMS)) continue;
1266  E+=VAL/val; nE++;
1267  T+=TIME-time; nT++;
1268  }
1269  }
1270  if(nE>0 && abs(eta)>29) refEnergy2Dhbhehf->setBinContent(eta+44,phi+1,E/nE);
1271  if(nT>0 && abs(eta)>29){ double TTT=T/nT+1; if(TTT<0.01) TTT=0.01; refTime2Dhbhehf->setBinContent(eta+44,phi+1,TTT); }
1272  if(nE>0 && abs(eta)>29) refEnergy2Dhbhehf->setBinContent(eta+44,phi+2,E/nE);
1273  if(nT>0 && abs(eta)>29){ double TTT=T/nT+1; if(TTT<0.01) TTT=0.01; refTime2Dhbhehf->setBinContent(eta+44,phi+2,TTT); }
1274  }
1275  }
1276  if(sd==HcalOuter){
1277  for(int eta=-15;eta<=15;eta++) for(int phi=1;phi<=72;phi++){
1278  if(eta>10 && !isSiPM(eta,phi,4)) continue;
1279  double T=0,nT=0,E=0,nE=0;
1280  for(int depth=4;depth<=4;depth++){
1281  if(ho_data[eta+42][phi-1][depth-1].get_statistics()>10){
1282  double val=0,rms=0,time=0,time_rms=0;
1283  double VAL=0,RMS=0,TIME=0,TIME_RMS=0;
1284  if(!ho_data[eta+42][phi-1][depth-1].get_reference(&val,&rms,&time,&time_rms)) continue;
1285  if(!ho_data[eta+42][phi-1][depth-1].get_average_amp(&VAL,&RMS)) continue;
1286  if(!ho_data[eta+42][phi-1][depth-1].get_average_time(&TIME,&TIME_RMS)) continue;
1287  E+=VAL/val; nE++;
1288  T+=TIME-time; nT++;
1289  }
1290  }
1291  if(nE>0) refEnergy2Dho->Fill(eta,phi,E/nE);
1292  if(nT>0){ double TTT=T/nT+1; if(TTT<0.01) TTT=0.01; refTime2Dho->Fill(eta,phi,TTT);}
1293  }
1294  }
1296  float min,max;
1297  if(sd==HcalBarrel || sd==HcalEndcap){
1298  min=100;max=-100;
1299  for(int i=1;i<=18;i++){
1300  float ave=-10,rms=-10;
1301  if(get_ave_rbx(HcalBarrel,-1,i,&ave,&rms)){
1302  hb_time_rbx->setBinContent(i,ave);
1303  hb_time_rbx->setBinError(i,rms);
1304  if(ave<min) min=ave;
1305  if(ave>max) max=ave;
1306  }
1307  }
1308  for(int i=1;i<=18;i++){
1309  float ave=-10,rms=-10;
1310  if(get_ave_rbx(HcalBarrel,1,i,&ave,&rms)){
1311  hb_time_rbx->setBinContent(i+18,ave);
1312  hb_time_rbx->setBinError(i+18,rms);
1313  if(ave<min) min=ave;
1314  if(ave>max) max=ave;
1315  }
1316  }
1317  if(max>-100)hb_time_rbx->setAxisRange(min-1,max+1,2);
1318  min=100;max=-100;
1319  for(int i=1;i<=18;i++){
1320  float ave=-10,rms=-10;
1321  if(get_ave_rbx(HcalEndcap,-1,i,&ave,&rms)){
1322  he_time_rbx->setBinContent(i,ave);
1323  he_time_rbx->setBinError(i,rms);
1324  if(ave<min) min=ave;
1325  if(ave>max) max=ave;
1326  }
1327  }
1328  for(int i=1;i<=18;i++){
1329  float ave=-10,rms=-10;
1330  if(get_ave_rbx(HcalEndcap,1,i,&ave,&rms)){
1331  he_time_rbx->setBinContent(i+18,ave);
1332  he_time_rbx->setBinError(i+18,rms);
1333  if(ave<min) min=ave;
1334  if(ave>max) max=ave;
1335  }
1336  }
1337  if(max>-100)he_time_rbx->setAxisRange(min-1,max+1,2);
1338  }
1340  if(sd==HcalOuter){
1341  min=100;max=-100;
1342  for(int i=1;i<=6;i++){
1343  float ave=-10,rms=-10;
1344  if(get_ave_rbx(HcalOuter,-2,i,&ave,&rms)){
1345  ho_time_rbx->setBinContent(i,ave);
1346  ho_time_rbx->setBinError(i,rms);
1347  if(ave<min) min=ave;
1348  if(ave>max) max=ave;
1349  }
1350  }
1351  for(int i=1;i<=6;i++){
1352  float ave=-10,rms=-10;
1353  if(get_ave_rbx(HcalOuter,-1,i,&ave,&rms)){
1354  ho_time_rbx->setBinContent(i+6,ave);
1355  ho_time_rbx->setBinError(i+6,rms);
1356  if(ave<min) min=ave;
1357  if(ave>max) max=ave;
1358  }
1359  }
1360  for(int i=1;i<=12;i++){
1361  float ave=-10,rms=-10;
1362  if(get_ave_rbx(HcalOuter,0,i,&ave,&rms)){
1363  ho_time_rbx->setBinContent(i+12,ave);
1364  ho_time_rbx->setBinError(i+12,rms);
1365  if(ave<min) min=ave;
1366  if(ave>max) max=ave;
1367  }
1368  }
1369  for(int i=1;i<=6;i++){
1370  float ave=-10,rms=-10;
1371  if(get_ave_rbx(HcalOuter,1,i,&ave,&rms)){
1372  ho_time_rbx->setBinContent(i+24,ave);
1373  ho_time_rbx->setBinError(i+24,rms);
1374  if(ave<min) min=ave;
1375  if(ave>max) max=ave;
1376  }
1377  }
1378  for(int i=1;i<=6;i++){
1379  float ave=-10,rms=-10;
1380  if(get_ave_rbx(HcalOuter,2,i,&ave,&rms)){
1381  ho_time_rbx->setBinContent(i+30,ave);
1382  ho_time_rbx->setBinError(i+30,rms);
1383  if(ave<min) min=ave;
1384  if(ave>max) max=ave;
1385  }
1386  }
1387  if(max>-100)ho_time_rbx->setAxisRange(min-1,max+1,2);
1388  }
1390  if(sd==HcalForward){
1391  min=100;max=-100;
1392  for(int i=1;i<=12;i++){
1393  float ave=-10,rms=-10;
1394  if(get_ave_rbx(HcalForward,-1,i,&ave,&rms)){
1395  hf_time_rbx->setBinContent(i,ave);
1396  hf_time_rbx->setBinError(i,rms);
1397  if(ave<min) min=ave;
1398  if(ave>max) max=ave;
1399  }
1400  }
1401  for(int i=1;i<=12;i++){
1402  float ave=-10,rms=-10;
1403  if(get_ave_rbx(HcalForward,1,i,&ave,&rms)){
1404  hf_time_rbx->setBinContent(i+12,ave);
1405  hf_time_rbx->setBinError(i+12,rms);
1406  if(ave<min) min=ave;
1407  if(ave>max) max=ave;
1408  }
1409  }
1410  if(max>-100)hf_time_rbx->setAxisRange(min-1,max+1,2);
1411  }
1412 }
int i
Definition: DBlmapReader.cc:9
void setBinContent(int binx, double content)
set content of bin (1-D)
void setAxisRange(double xmin, double xmax, int axis=1)
set x-, y- or z-axis range (axis=1, 2, 3 respectively)
bool get_average_amp(double *ave, double *rms)
#define abs(x)
Definition: mlp_lapack.h:159
#define min(a, b)
Definition: mlp_lapack.h:161
T eta() const
bool get_ave_rbx(int sd, int side, int rbx, float *ave, float *rms)
bool get_average_time(double *ave, double *rms)
void Fill(long long x)
bool isSiPM(int ieta, int iphi, int depth)
const T & max(const T &a, const T &b)
void setBinError(int binx, double error)
set uncertainty on content of bin (1-D)
HcalDetDiagLaserData hb_data[85][72][4]
double sd
HcalDetDiagLaserData hf_data[85][72][4]
HcalDetDiagLaserData he_data[85][72][4]
long double T
HcalDetDiagLaserData ho_data[85][72][4]
void Reset(void)
reset ME (ie. contents, errors, etc)
Definition: DDAxes.h:10
void HcalDetDiagLaserMonitor::fillProblems ( int  sd)
private

Definition at line 801 of file HcalDetDiagLaserMonitor.cc.

References HcalElectronicsMap::allElectronicsIdPrecision(), CalcEtaBin(), HcalDetId::depth(), EtaPhiHists::depth, DetId::det(), cond::rpcobgas::detid, alignCSCRings::e, emap, eta(), get_ave_subdet(), hb_data, DetId::Hcal, HcalBarrel, HcalEndcap, HcalForward, HcalGenericDetId::HcalGenBarrel, HcalGenericDetId::HcalGenEndcap, HcalGenericDetId::HcalGenForward, HcalGenericDetId::HcalGenOuter, HcalOuter, he_data, hf_data, ho_data, i, HcalDetId::ieta(), HcalDetId::iphi(), KnownBadCells_, LaserEnergyThreshold, LaserTimingThreshold, HcalElectronicsMap::lookup(), HcalDetDiagLaserData::nBadEnergy, HcalDetDiagLaserData::nBadTime, HcalDetDiagLaserData::nChecks, phi, ProblemCellsByDepth_energy, ProblemCellsByDepth_energy_val, ProblemCellsByDepth_timing, ProblemCellsByDepth_timing_val, DetId::rawId(), plotscripts::rms(), DetId::subdetId(), and cond::rpcobgas::time.

Referenced by analyze(), and endRun().

801  {
802 float ave_t,ave_e,ave_t_r,ave_e_r;
803  if(!get_ave_subdet(sd,&ave_t,&ave_e,&ave_t_r,&ave_e_r)) return;
804 
805  for(int i=0;i<4;i++){
808  }
809 
810  std::vector <HcalElectronicsId> AllElIds = emap->allElectronicsIdPrecision();
811  for (std::vector <HcalElectronicsId>::iterator eid = AllElIds.begin(); eid != AllElIds.end(); eid++){
812  DetId detid=emap->lookup(*eid);
813  if (detid.det()!=DetId::Hcal) continue;
814  HcalGenericDetId gid(emap->lookup(*eid));
815  if(!(!(gid.null()) &&
816  (gid.genericSubdet()==HcalGenericDetId::HcalGenBarrel ||
817  gid.genericSubdet()==HcalGenericDetId::HcalGenEndcap ||
818  gid.genericSubdet()==HcalGenericDetId::HcalGenForward ||
819  gid.genericSubdet()==HcalGenericDetId::HcalGenOuter))) continue;
820  int eta=0,phi=0,depth=0;
821  HcalDetId hid(detid);
822  if(KnownBadCells_.find(hid.rawId())==KnownBadCells_.end()) continue;
823  eta=hid.ieta();
824  phi=hid.iphi();
825  depth=hid.depth();
826 
827  int e=CalcEtaBin(sd,eta,depth)+1;
828  if(detid.subdetId()==HcalBarrel && sd==HcalBarrel){
829  double val=0,rms=0,time=0,time_rms=0,VAL=0,RMS=0,TIME=0,TIME_RMS=0;
830  if(!hb_data[eta+42][phi-1][depth-1].get_reference(&val,&rms,&time,&time_rms)) continue;
831  if(!hb_data[eta+42][phi-1][depth-1].get_average_amp(&VAL,&RMS)) continue;
832  if(!hb_data[eta+42][phi-1][depth-1].get_average_time(&TIME,&TIME_RMS)) continue;
833  hb_data[eta+42][phi-1][depth-1].nChecks++;
834  float diff_t=(TIME-ave_t)-(time-ave_t_r); if(diff_t<0) diff_t=-diff_t;
835  if(diff_t>LaserTimingThreshold){
836  hb_data[eta+42][phi-1][depth-1].nBadTime++;
837  ProblemCellsByDepth_timing_val->depth[depth-1]->setBinContent(e,phi,(TIME-ave_t)-(time-ave_t_r));
838  }else ProblemCellsByDepth_timing_val->depth[depth-1]->setBinContent(e,phi,0);
839  if(VAL!=0 && val!=0 && ave_e!=0 && ave_e_r!=0){
840  float diff_e=((VAL/ave_e))/(val/ave_e_r);
841  if(diff_e>(1+LaserEnergyThreshold) ||diff_e<(1-LaserEnergyThreshold) ){
842  hb_data[eta+42][phi-1][depth-1].nBadEnergy++;
843  ProblemCellsByDepth_energy_val->depth[depth-1]->setBinContent(e,phi,((VAL/ave_e))/(val/ave_e_r));
844  }else ProblemCellsByDepth_energy_val->depth[depth-1]->setBinContent(e,phi,0);
845  }
846  }
847  if(detid.subdetId()==HcalEndcap && sd==HcalEndcap){
848  double val=0,rms=0,time=0,time_rms=0,VAL=0,RMS=0,TIME=0,TIME_RMS=0;
849  if(!he_data[eta+42][phi-1][depth-1].get_reference(&val,&rms,&time,&time_rms)) continue;
850  if(!he_data[eta+42][phi-1][depth-1].get_average_amp(&VAL,&RMS)) continue;
851  if(!he_data[eta+42][phi-1][depth-1].get_average_time(&TIME,&TIME_RMS)) continue;
852  he_data[eta+42][phi-1][depth-1].nChecks++;
853  float diff_t=(TIME-ave_t)-(time-ave_t_r); if(diff_t<0) diff_t=-diff_t;
854  if(diff_t>LaserTimingThreshold){
855  he_data[eta+42][phi-1][depth-1].nBadTime++;
856  ProblemCellsByDepth_timing_val->depth[depth-1]->setBinContent(e,phi,(TIME-ave_t)-(time-ave_t_r));
857  }else ProblemCellsByDepth_timing_val->depth[depth-1]->setBinContent(e,phi,0);
858  if(VAL!=0 && val!=0 && ave_e!=0 && ave_e_r!=0){
859  float diff_e=((VAL/ave_e))/(val/ave_e_r);
860  if(diff_e>(1+LaserEnergyThreshold) ||diff_e<(1-LaserEnergyThreshold) ){
861  he_data[eta+42][phi-1][depth-1].nBadEnergy++;
862  ProblemCellsByDepth_energy_val->depth[depth-1]->setBinContent(e,phi,((VAL/ave_e))/(val/ave_e_r));
863  }else ProblemCellsByDepth_energy_val->depth[depth-1]->setBinContent(e,phi,0);
864  }
865  }
866  if(detid.subdetId()==HcalOuter && sd==HcalOuter){
867  double val=0,rms=0,time=0,time_rms=0,VAL=0,RMS=0,TIME=0,TIME_RMS=0;
868  if(!ho_data[eta+42][phi-1][depth-1].get_reference(&val,&rms,&time,&time_rms)) continue;
869  if(!ho_data[eta+42][phi-1][depth-1].get_average_amp(&VAL,&RMS)) continue;
870  if(!ho_data[eta+42][phi-1][depth-1].get_average_time(&TIME,&TIME_RMS)) continue;
871  ho_data[eta+42][phi-1][depth-1].nChecks++;
872  float diff_t=(TIME-ave_t)-(time-ave_t_r); if(diff_t<0) diff_t=-diff_t;
873  if(diff_t>LaserTimingThreshold){
874  ho_data[eta+42][phi-1][depth-1].nBadTime++;
875  ProblemCellsByDepth_timing_val->depth[depth-1]->setBinContent(e,phi,(TIME-ave_t)-(time-ave_t_r));
876  }else ProblemCellsByDepth_timing_val->depth[depth-1]->setBinContent(e,phi,0);
877  if(VAL!=0 && val!=0 && ave_e!=0 && ave_e_r!=0){
878  float diff_e=((VAL/ave_e))/(val/ave_e_r);
879  if(diff_e>(1+LaserEnergyThreshold) ||diff_e<(1-LaserEnergyThreshold) ){
880  ho_data[eta+42][phi-1][depth-1].nBadEnergy++;
881  ProblemCellsByDepth_energy_val->depth[depth-1]->setBinContent(e,phi,((VAL/ave_e))/(val/ave_e_r));
882  }else ProblemCellsByDepth_energy_val->depth[depth-1]->setBinContent(e,phi,0);
883  }
884  }
885  if(detid.subdetId()==HcalForward && sd==HcalForward){
886  double val=0,rms=0,time=0,time_rms=0,VAL=0,RMS=0,TIME=0,TIME_RMS=0;
887  if(!hf_data[eta+42][phi-1][depth-1].get_reference(&val,&rms,&time,&time_rms)) continue;
888  if(!hf_data[eta+42][phi-1][depth-1].get_average_amp(&VAL,&RMS)) continue;
889  if(!hf_data[eta+42][phi-1][depth-1].get_average_time(&TIME,&TIME_RMS)) continue;
890  hf_data[eta+42][phi-1][depth-1].nChecks++;
891  float diff_t=(TIME-ave_t)-(time-ave_t_r); if(diff_t<0) diff_t=-diff_t;
892  if(diff_t>LaserTimingThreshold){
893  hf_data[eta+42][phi-1][depth-1].nBadTime++;
894  ProblemCellsByDepth_timing_val->depth[depth-1]->setBinContent(e,phi,(TIME-ave_t)-(time-ave_t_r));
895  }else ProblemCellsByDepth_timing_val->depth[depth-1]->setBinContent(e,phi,0);
896  if(VAL!=0 && val!=0 && ave_e!=0 && ave_e_r!=0){
897  float diff_e=((VAL/ave_e))/(val/ave_e_r);
898  if(diff_e>(1+LaserEnergyThreshold) ||diff_e<(1-LaserEnergyThreshold) ){
899  hf_data[eta+42][phi-1][depth-1].nBadEnergy++;
900  ProblemCellsByDepth_energy_val->depth[depth-1]->setBinContent(e,phi,((VAL/ave_e))/(val/ave_e_r));
901  }else ProblemCellsByDepth_energy_val->depth[depth-1]->setBinContent(e,phi,0);
902  }
903  }
904  }
905  for (std::vector <HcalElectronicsId>::iterator eid = AllElIds.begin(); eid != AllElIds.end(); eid++){
906  DetId detid=emap->lookup(*eid);
907  if (detid.det()!=DetId::Hcal) continue;
908  HcalGenericDetId gid(emap->lookup(*eid));
909  if(!(!(gid.null()) &&
910  (gid.genericSubdet()==HcalGenericDetId::HcalGenBarrel ||
911  gid.genericSubdet()==HcalGenericDetId::HcalGenEndcap ||
912  gid.genericSubdet()==HcalGenericDetId::HcalGenForward ||
913  gid.genericSubdet()==HcalGenericDetId::HcalGenOuter))) continue;
914  int eta=0,phi=0,depth=0;
915  HcalDetId hid(detid);
916  eta=hid.ieta();
917  phi=hid.iphi();
918  depth=hid.depth();
919 
920  if(detid.subdetId()==HcalBarrel){
921  if(hb_data[eta+42][phi-1][depth-1].nBadTime>0){
922  int e=CalcEtaBin(HcalBarrel,eta,depth)+1;
923  double val=hb_data[eta+42][phi-1][depth-1].nBadTime/hb_data[eta+42][phi-1][depth-1].nChecks;
924  ProblemCellsByDepth_timing->depth[depth-1]->setBinContent(e,phi,val);
925  }
926  if(hb_data[eta+42][phi-1][depth-1].nBadEnergy>0){
927  int e=CalcEtaBin(HcalBarrel,eta,depth)+1;
928  double val=hb_data[eta+42][phi-1][depth-1].nBadEnergy/hb_data[eta+42][phi-1][depth-1].nChecks;
929  ProblemCellsByDepth_energy->depth[depth-1]->setBinContent(e,phi,val);
930  }
931  }
932  if(detid.subdetId()==HcalEndcap){
933  if(he_data[eta+42][phi-1][depth-1].nBadTime>0){
934  int e=CalcEtaBin(HcalEndcap,eta,depth)+1;
935  double val=he_data[eta+42][phi-1][depth-1].nBadTime/he_data[eta+42][phi-1][depth-1].nChecks;
936  ProblemCellsByDepth_timing->depth[depth-1]->setBinContent(e,phi,val);
937  }
938  if(he_data[eta+42][phi-1][depth-1].nBadEnergy>0){
939  int e=CalcEtaBin(HcalEndcap,eta,depth)+1;
940  double val=he_data[eta+42][phi-1][depth-1].nBadEnergy/he_data[eta+42][phi-1][depth-1].nChecks;
941  ProblemCellsByDepth_energy->depth[depth-1]->setBinContent(e,phi,val);
942  }
943  }
944  if(detid.subdetId()==HcalOuter){
945  if(ho_data[eta+42][phi-1][depth-1].nBadTime>0){
946  int e=CalcEtaBin(HcalOuter,eta,depth)+1;
947  double val=ho_data[eta+42][phi-1][depth-1].nBadTime/ho_data[eta+42][phi-1][depth-1].nChecks;
948  ProblemCellsByDepth_timing->depth[depth-1]->setBinContent(e,phi,val);
949  }
950  if(ho_data[eta+42][phi-1][depth-1].nBadEnergy>0){
951  int e=CalcEtaBin(HcalOuter,eta,depth)+1;
952  double val=ho_data[eta+42][phi-1][depth-1].nBadEnergy/ho_data[eta+42][phi-1][depth-1].nChecks;
953  ProblemCellsByDepth_energy->depth[depth-1]->setBinContent(e,phi,val);
954  }
955  }
956  if(detid.subdetId()==HcalForward){
957  if(hf_data[eta+42][phi-1][depth-1].nBadTime>0){
958  int e=CalcEtaBin(HcalForward,eta,depth)+1;
959  double val=hf_data[eta+42][phi-1][depth-1].nBadTime/hf_data[eta+42][phi-1][depth-1].nChecks;
960  ProblemCellsByDepth_timing->depth[depth-1]->setBinContent(e,phi,val);
961  }
962  if(hf_data[eta+42][phi-1][depth-1].nBadEnergy>0){
963  int e=CalcEtaBin(HcalForward,eta,depth)+1;
964  double val=hf_data[eta+42][phi-1][depth-1].nBadEnergy/hf_data[eta+42][phi-1][depth-1].nChecks;
965  ProblemCellsByDepth_energy->depth[depth-1]->setBinContent(e,phi,val);
966  }
967  }
968  }
969 }
int i
Definition: DBlmapReader.cc:9
std::vector< HcalElectronicsId > allElectronicsIdPrecision() const
const HcalElectronicsMap * emap
bool get_ave_subdet(int sd, float *ave_t, float *ave_e, float *ave_t_r, float *ave_e_r)
T eta() const
std::map< unsigned int, int > KnownBadCells_
std::vector< MonitorElement * > depth
int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:39
Definition: DetId.h:20
HcalDetDiagLaserData hb_data[85][72][4]
double sd
int CalcEtaBin(int subdet, int ieta, int depth)
HcalDetDiagLaserData hf_data[85][72][4]
HcalDetDiagLaserData he_data[85][72][4]
Detector det() const
get the detector field from this detid
Definition: DetId.h:37
HcalDetDiagLaserData ho_data[85][72][4]
const DetId lookup(HcalElectronicsId fId) const
lookup the logical detid associated with the given electronics id
Definition: DDAxes.h:10
bool HcalDetDiagLaserMonitor::get_ave_rbx ( int  sd,
int  side,
int  rbx,
float *  ave,
float *  rms 
)
private

Definition at line 971 of file HcalDetDiagLaserMonitor.cc.

References hb_data, HcalBarrel, HcalEndcap, HcalForward, HcalOuter, he_data, hf_data, ho_data, i, j, gen::k, n, plotscripts::rms(), mathSSE::sqrt(), and cond::rpcobgas::time.

Referenced by fillHistos().

971  {
972  double xt=0,xxt=0;
973  int eta_min=0,eta_max=0,n=0;
974  if(sd==HcalBarrel){
975  if(side>0){eta_min=1; eta_max=29;}
976  if(side<0){eta_min=-29; eta_max=-1;}
977  if(rbx==1){
978  for(int i=eta_min;i<=eta_max;i++) for(int j=71;j<=72;j++)for(int k=1;k<=3;k++){
979  double val,rms,time,time_rms;
980  double TIME,TIME_RMS;
981  if(!hb_data[i+42][j-1][k-1].get_reference(&val,&rms,&time,&time_rms)) continue;
982  if(!hb_data[i+42][j-1][k-1].get_average_time(&TIME,&TIME_RMS)) continue;
983  xt+=TIME-time; xxt+=(TIME-time)*(TIME-time); n++;
984  }
985  for(int i=eta_min;i<=eta_max;i++) for(int j=1;j<=2;j++)for(int k=1;k<=3;k++){
986  double val,rms,time,time_rms;
987  double TIME,TIME_RMS;
988  if(!hb_data[i+42][j-1][k-1].get_reference(&val,&rms,&time,&time_rms)) continue;
989  if(!hb_data[i+42][j-1][k-1].get_average_time(&TIME,&TIME_RMS)) continue;
990  xt+=TIME-time; xxt+=(TIME-time)*(TIME-time); n++;
991  }
992 
993  }else{
994  for(int i=eta_min;i<=eta_max;i++) for(int j=((rbx-1)*4-1);j<=((rbx-1)*4+2);j++)for(int k=1;k<=3;k++){
995  double val,rms,time,time_rms;
996  double TIME,TIME_RMS;
997  if(!hb_data[i+42][j-1][k-1].get_reference(&val,&rms,&time,&time_rms)) continue;
998  if(!hb_data[i+42][j-1][k-1].get_average_time(&TIME,&TIME_RMS)) continue;
999  xt+=TIME-time; xxt+=(TIME-time)*(TIME-time); n++;
1000  }
1001  }
1002  }
1003  if(sd==HcalEndcap){
1004  if(side>0){eta_min=1; eta_max=29;}
1005  if(side<0){eta_min=-29; eta_max=-1;}
1006  if(rbx==1){
1007  for(int i=eta_min;i<=eta_max;i++) for(int j=71;j<=72;j++)for(int k=1;k<=3;k++){
1008  double val,rms,time,time_rms;
1009  double TIME,TIME_RMS;
1010  if(!he_data[i+42][j-1][k-1].get_reference(&val,&rms,&time,&time_rms)) continue;
1011  if(!he_data[i+42][j-1][k-1].get_average_time(&TIME,&TIME_RMS)) continue;
1012  xt+=TIME-time; xxt+=(TIME-time)*(TIME-time); n++;
1013  }
1014  for(int i=eta_min;i<=eta_max;i++) for(int j=1;j<=2;j++)for(int k=1;k<=3;k++){
1015  double val,rms,time,time_rms;
1016  double TIME,TIME_RMS;
1017  if(!he_data[i+42][j-1][k-1].get_reference(&val,&rms,&time,&time_rms)) continue;
1018  if(!he_data[i+42][j-1][k-1].get_average_time(&TIME,&TIME_RMS)) continue;
1019  xt+=TIME-time; xxt+=(TIME-time)*(TIME-time); n++;
1020  }
1021 
1022  }else{
1023  for(int i=eta_min;i<=eta_max;i++) for(int j=((rbx-1)*4-1);j<=((rbx-1)*4+2);j++)for(int k=1;k<=3;k++){
1024  double val,rms,time,time_rms;
1025  double TIME,TIME_RMS;
1026  if(!he_data[i+42][j-1][k-1].get_reference(&val,&rms,&time,&time_rms)) continue;
1027  if(!he_data[i+42][j-1][k-1].get_average_time(&TIME,&TIME_RMS)) continue;
1028  xt+=TIME-time; xxt+=(TIME-time)*(TIME-time); n++;
1029  }
1030  }
1031  }
1032  if(sd==HcalForward){
1033  if(side>0){eta_min=29; eta_max=40;}
1034  if(side<0){eta_min=-40; eta_max=-29;}
1035  for(int i=eta_min;i<=eta_max;i++) for(int j=((rbx-1)*6+1);j<=((rbx-1)*6+6);j++)for(int k=1;k<=2;k++){
1036  double val,rms,time,time_rms;
1037  double TIME,TIME_RMS;
1038  if(!hf_data[i+42][j-1][k-1].get_reference(&val,&rms,&time,&time_rms)) continue;
1039  if(!hf_data[i+42][j-1][k-1].get_average_time(&TIME,&TIME_RMS)) continue;
1040  xt+=TIME-time; xxt+=(TIME-time)*(TIME-time); n++;
1041  }
1042  }
1043  if(sd==HcalOuter){
1044  if(side==0){
1045  eta_min=-4,eta_max=4;
1046  if(rbx==1){
1047  for(int i=eta_min;i<=eta_max;i++) for(int j=71;j<=72;j++){
1048  double val,rms,time,time_rms;
1049  double TIME,TIME_RMS;
1050  if(!ho_data[i+42][j-1][4-1].get_reference(&val,&rms,&time,&time_rms)) continue;
1051  if(!ho_data[i+42][j-1][4-1].get_average_time(&TIME,&TIME_RMS)) continue;
1052  xt+=TIME-time; xxt+=(TIME-time)*(TIME-time); n++;
1053  }
1054  for(int i=eta_min;i<=eta_max;i++) for(int j=1;j<=4;j++){
1055  double val,rms,time,time_rms;
1056  double TIME,TIME_RMS;
1057  if(!ho_data[i+42][j-1][4-1].get_reference(&val,&rms,&time,&time_rms)) continue;
1058  if(!ho_data[i+42][j-1][4-1].get_average_time(&TIME,&TIME_RMS)) continue;
1059  xt+=TIME-time; xxt+=(TIME-time)*(TIME-time); n++;
1060  }
1061 
1062  }else{
1063  for(int i=eta_min;i<=eta_max;i++) for(int j=((rbx-1)*6-1);j<=((rbx-1)*6+4);j++){
1064  double val,rms,time,time_rms;
1065  double TIME,TIME_RMS;
1066  if(!ho_data[i+42][j-1][4-1].get_reference(&val,&rms,&time,&time_rms)) continue;
1067  if(!ho_data[i+42][j-1][4-1].get_average_time(&TIME,&TIME_RMS)) continue;
1068  xt+=TIME-time; xxt+=(TIME-time)*(TIME-time); n++;
1069  }
1070  }
1071  }
1072  if(side==-1){ eta_min=-10,eta_max=-5;}
1073  if(side==-2){ eta_min=-15,eta_max=-11;}
1074  if(side==1) { eta_min=5, eta_max=10;}
1075  if(side==2) { eta_min=11, eta_max=15;}
1076  if(side!=0){
1077  if(rbx==1){
1078  for(int i=eta_min;i<=eta_max;i++) for(int j=71;j<=72;j++){
1079  double val,rms,time,time_rms;
1080  double TIME,TIME_RMS;
1081  if(!ho_data[i+42][j-1][4-1].get_reference(&val,&rms,&time,&time_rms)) continue;
1082  if(!ho_data[i+42][j-1][4-1].get_average_time(&TIME,&TIME_RMS)) continue;
1083  xt+=TIME-time; xxt+=(TIME-time)*(TIME-time); n++;
1084  }
1085  for(int i=eta_min;i<=eta_max;i++) for(int j=1;j<=10;j++){
1086  double val,rms,time,time_rms;
1087  double TIME,TIME_RMS;
1088  if(!ho_data[i+42][j-1][4-1].get_reference(&val,&rms,&time,&time_rms)) continue;
1089  if(!ho_data[i+42][j-1][4-1].get_average_time(&TIME,&TIME_RMS)) continue;
1090  xt+=TIME-time; xxt+=(TIME-time)*(TIME-time); n++;
1091  }
1092 
1093  }else{
1094  for(int i=eta_min;i<=eta_max;i++) for(int j=((rbx-1)*12-1);j<=((rbx-1)*12+10);j++){
1095  double val,rms,time,time_rms;
1096  double TIME,TIME_RMS;
1097  if(!ho_data[i+42][j-1][4-1].get_reference(&val,&rms,&time,&time_rms)) continue;
1098  if(!ho_data[i+42][j-1][4-1].get_average_time(&TIME,&TIME_RMS)) continue;
1099  xt+=TIME-time; xxt+=(TIME-time)*(TIME-time); n++;
1100  }
1101  }
1102  }
1103  }
1104  if(n<10) return false;
1105  *ave=xt/n;
1106  *rms=sqrt(xxt/n-(xt*xt)/(n*n));
1107  return true;
1108 }
int i
Definition: DBlmapReader.cc:9
T sqrt(T t)
Definition: SSEVec.h:46
int j
Definition: DBlmapReader.cc:9
int k[5][pyjets_maxn]
HcalDetDiagLaserData hb_data[85][72][4]
double sd
HcalDetDiagLaserData hf_data[85][72][4]
HcalDetDiagLaserData he_data[85][72][4]
HcalDetDiagLaserData ho_data[85][72][4]
bool HcalDetDiagLaserMonitor::get_ave_subdet ( int  sd,
float *  ave_t,
float *  ave_e,
float *  ave_t_r,
float *  ave_e_r 
)
private

Definition at line 740 of file HcalDetDiagLaserMonitor.cc.

References eta(), HcalDetDiagLaserData::get_average_amp(), HcalDetDiagLaserData::get_average_time(), hb_data, HcalBarrel, HcalEndcap, HcalForward, HcalOuter, he_data, hf_data, ho_data, phi, plotscripts::rms(), and cond::rpcobgas::time.

Referenced by fillProblems().

740  {
741 double T=0,nT=0,E=0,nE=0,Tr=0,nTr=0,Er=0,nEr=0;
742  if(sd==HcalBarrel) for(int eta=-16;eta<=16;eta++) for(int phi=1;phi<=72;phi++){
743  for(int depth=1;depth<=2;depth++){
744  if(hb_data[eta+42][phi-1][depth-1].get_statistics()>10){
745  double ave=0,rms=0,time=0,time_rms=0;
746  hb_data[eta+42][phi-1][depth-1].get_average_amp(&ave,&rms);
747  hb_data[eta+42][phi-1][depth-1].get_average_time(&time,&time_rms);
748  T+=time; nT++; E+=ave; nE++;
749  if(hb_data[eta+42][phi-1][depth-1].get_reference(&ave,&rms,&time,&time_rms)){
750  Tr+=time; nTr++; Er+=ave; nEr++;}
751  }
752  }
753  }
754  // HE histograms
755  if(sd==HcalEndcap) for(int eta=-29;eta<=29;eta++) for(int phi=1;phi<=72;phi++){
756  for(int depth=1;depth<=3;depth++){
757  if(he_data[eta+42][phi-1][depth-1].get_statistics()>10){
758  double ave=0; double rms=0; double time=0; double time_rms=0;
759  he_data[eta+42][phi-1][depth-1].get_average_amp(&ave,&rms);
760  he_data[eta+42][phi-1][depth-1].get_average_time(&time,&time_rms);
761  T+=time; nT++; E+=ave; nE++;
762  if(he_data[eta+42][phi-1][depth-1].get_reference(&ave,&rms,&time,&time_rms)){
763  Tr+=time; nTr++; Er+=ave; nEr++;}
764  }
765  }
766  }
767  // HF histograms
768  if(sd==HcalForward) for(int eta=-42;eta<=42;eta++) for(int phi=1;phi<=72;phi++){
769  for(int depth=1;depth<=2;depth++){
770  if(hf_data[eta+42][phi-1][depth-1].get_statistics()>10){
771  double ave=0; double rms=0; double time=0; double time_rms=0;
772  hf_data[eta+42][phi-1][depth-1].get_average_amp(&ave,&rms);
773  hf_data[eta+42][phi-1][depth-1].get_average_time(&time,&time_rms);
774  T+=time; nT++; E+=ave; nE++;
775  if(hf_data[eta+42][phi-1][depth-1].get_reference(&ave,&rms,&time,&time_rms)){
776  Tr+=time; nTr++; Er+=ave; nEr++;}
777  }
778  }
779  }
780  // HO histograms
781  if(sd==HcalOuter) for(int eta=-15;eta<=15;eta++) for(int phi=1;phi<=72;phi++){
782  for(int depth=4;depth<=4;depth++){
783  if(ho_data[eta+42][phi-1][depth-1].get_statistics()>10){
784  double ave=0; double rms=0; double time=0; double time_rms=0;
785  ho_data[eta+42][phi-1][depth-1].get_average_amp(&ave,&rms);
786  ho_data[eta+42][phi-1][depth-1].get_average_time(&time,&time_rms);
787  T+=time; nT++; E+=ave; nE++;
788  if(ho_data[eta+42][phi-1][depth-1].get_reference(&ave,&rms,&time,&time_rms)){
789  Tr+=time; nTr++; Er+=ave; nEr++;}
790  }
791  }
792  }
793  if(nT<200 || nE<200 || nTr<200 || nEr<200) return false;
794  *ave_t=T/nT;
795  *ave_e=E/nE;
796  *ave_t_r=Tr/nTr;
797  *ave_e_r=Er/nEr;
798  return true;
799 }
bool get_average_amp(double *ave, double *rms)
T eta() const
bool get_average_time(double *ave, double *rms)
HcalDetDiagLaserData hb_data[85][72][4]
double sd
HcalDetDiagLaserData hf_data[85][72][4]
HcalDetDiagLaserData he_data[85][72][4]
long double T
HcalDetDiagLaserData ho_data[85][72][4]
Definition: DDAxes.h:10
HcalDetDiagLaserData* HcalDetDiagLaserMonitor::GetCalib ( std::string  sd,
int  eta,
int  phi 
)
inlineprivate

Definition at line 253 of file HcalDetDiagLaserMonitor.cc.

References abs, calib_data, ETA, and PHI.

253  {
254  int SD=0,ETA=0,PHI=0;
255  if(sd.compare("HB")==0) SD=1;
256  if(sd.compare("HE")==0) SD=2;
257  if(sd.compare("HO")==0) SD=3;
258  if(sd.compare("HF")==0) SD=4;
259  if(SD==1 || SD==2){
260  if(eta>0) ETA=1; else ETA=-1;
261  if(phi==71 ||phi==72 || phi==1 || phi==2) PHI=71; else PHI=((phi-3)/4)*4+3;
262  }else if(SD==3){
263  if(abs(eta)<=4){
264  ETA=0;
265  if(phi==71 ||phi==72 || phi==1 || phi==2 || phi==3 || phi==4) PHI=71; else PHI=((phi-5)/6)*6+5;
266  }else{
267  if(abs(eta)>4 && abs(eta)<=10) ETA=1;
268  if(abs(eta)>10 && abs(eta)<=15) ETA=2;
269  if(eta<0) ETA=-ETA;
270  if(phi==71 ||phi==72 || (phi>=1 && phi<=10)) PHI=71; else PHI=((phi-11)/12)*12+11;
271  }
272  }else if(SD==4){
273  if(eta>0) ETA=1; else ETA=-1;
274  if(phi>=1 && phi<=18) PHI=1;
275  if(phi>=19 && phi<=36) PHI=19;
276  if(phi>=37 && phi<=54) PHI=37;
277  if(phi>=55 && phi<=72) PHI=55;
278  }
279  return &calib_data[SD][ETA+2][PHI-1];
280  };
#define abs(x)
Definition: mlp_lapack.h:159
T eta() const
#define ETA
double sd
#define PHI
HcalDetDiagLaserData calib_data[5][5][72]
Definition: DDAxes.h:10
void HcalDetDiagLaserMonitor::LoadDataset ( )
private

Definition at line 1782 of file HcalDetDiagLaserMonitor.cc.

References calib_data, createHTMLonly, dataset_seq_number, DatasetName, reco::tau::disc::Eta(), patZpeak::events, f, MonitorElement::Fill(), hb_data, he_data, hf_data, ho_data, ievt_, meEVT_, meRUN_, nHB, nHE, nHF, nHO, colinearityKinematic::Phi, plotscripts::rms(), DTTTrigCorrFirst::run, run_number, HcalDetDiagLaserData::set_data(), HcalDetDiagLaserData::set_statistics(), HcalDetDiagLaserData::set_statistics1(), lumiQTWidget::t, and cond::rpcobgas::time.

Referenced by beginRun().

1782  {
1783 double amp,rms,time,time_rms;
1784 int Eta,Phi,Depth,Statistic;
1785 char subdet[10];
1786 TFile *f;
1787  if(DatasetName.size()==0) return;
1788  createHTMLonly=true;
1789  if(gSystem->AccessPathName(DatasetName.c_str())) return;
1790  f = new TFile(DatasetName.c_str(),"READ");
1791 
1792  if(!f->IsOpen()) return ;
1793 
1794  TTree* t=0;
1795  t=(TTree*)f->Get("HCAL Laser data");
1796  if(!t) return;
1797  t->SetBranchAddress("Subdet", subdet);
1798  t->SetBranchAddress("eta", &Eta);
1799  t->SetBranchAddress("phi", &Phi);
1800  t->SetBranchAddress("depth", &Depth);
1801  t->SetBranchAddress("amp", &amp);
1802  t->SetBranchAddress("rms", &rms);
1803  t->SetBranchAddress("time", &time);
1804  t->SetBranchAddress("time_rms", &time_rms);
1805  t->SetBranchAddress("statistic",&Statistic);
1806  for(int ievt=0;ievt<t->GetEntries();ievt++){
1807  t->GetEntry(ievt);
1808  if(strcmp(subdet,"HB")==0){ nHB++;
1809  hb_data[Eta+42][Phi-1][Depth-1].set_data(amp,rms,time,time_rms);
1810  hb_data[Eta+42][Phi-1][Depth-1].set_statistics(Statistic);
1811  hb_data[Eta+42][Phi-1][Depth-1].set_statistics1(Statistic);
1812  }
1813  if(strcmp(subdet,"HE")==0){ nHE++;
1814  he_data[Eta+42][Phi-1][Depth-1].set_data(amp,rms,time,time_rms);
1815  he_data[Eta+42][Phi-1][Depth-1].set_statistics(Statistic);
1816  he_data[Eta+42][Phi-1][Depth-1].set_statistics1(Statistic);
1817  }
1818  if(strcmp(subdet,"HO")==0){ nHO++;
1819  ho_data[Eta+42][Phi-1][Depth-1].set_data(amp,rms,time,time_rms);
1820  ho_data[Eta+42][Phi-1][Depth-1].set_statistics(Statistic);
1821  ho_data[Eta+42][Phi-1][Depth-1].set_statistics1(Statistic);
1822  }
1823  if(strcmp(subdet,"HF")==0){ nHF++;
1824  hf_data[Eta+42][Phi-1][Depth-1].set_data(amp,rms,time,time_rms);
1825  hf_data[Eta+42][Phi-1][Depth-1].set_statistics(Statistic);
1826  hf_data[Eta+42][Phi-1][Depth-1].set_statistics1(Statistic);
1827  }
1828  if(strcmp(subdet,"CALIB_HB")==0){
1829  calib_data[1][Eta+2][Phi-1].set_data(amp,rms,time,time_rms);
1830  calib_data[1][Eta+2][Phi-1].set_statistics(Statistic);
1831  calib_data[1][Eta+2][Phi-1].set_statistics1(Statistic);
1832  }
1833  if(strcmp(subdet,"CALIB_HE")==0){
1834  calib_data[2][Eta+2][Phi-1].set_data(amp,rms,time,time_rms);
1835  calib_data[2][Eta+2][Phi-1].set_statistics(Statistic);
1836  calib_data[2][Eta+2][Phi-1].set_statistics1(Statistic);
1837  }
1838  if(strcmp(subdet,"CALIB_HO")==0){
1839  calib_data[3][Eta+2][Phi-1].set_data(amp,rms,time,time_rms);
1840  calib_data[3][Eta+2][Phi-1].set_statistics(Statistic);
1841  calib_data[3][Eta+2][Phi-1].set_statistics1(Statistic);
1842  }
1843  if(strcmp(subdet,"CALIB_HF")==0){
1844  calib_data[4][Eta+2][Phi-1].set_data(amp,rms,time,time_rms);
1845  calib_data[4][Eta+2][Phi-1].set_statistics(Statistic);
1846  calib_data[4][Eta+2][Phi-1].set_statistics1(Statistic);
1847  }
1848  }
1849  TObjString *STR1=(TObjString *)f->Get("run number");
1850  if(STR1){ int run; sscanf(STR1->String(),"%i",&run); meRUN_->Fill(run); run_number=run;}
1851 
1852  TObjString *STR2=(TObjString *)f->Get("Total events processed");
1853  if(STR2){ int events; sscanf(STR2->String(),"%i",&events); meEVT_->Fill(events); ievt_=events;}
1854 
1855  TObjString *STR3=(TObjString *)f->Get("Dataset number");
1856  if(STR3){ int ds; sscanf(STR3->String(),"%i",&ds); dataset_seq_number=ds;}
1857  f->Close();
1858 }
void Fill(long long x)
double f[11][100]
HcalDetDiagLaserData hb_data[85][72][4]
HcalDetDiagLaserData hf_data[85][72][4]
tuple events
Definition: patZpeak.py:19
void set_data(float val, float rms, float time, float time_rms)
HcalDetDiagLaserData he_data[85][72][4]
HcalDetDiagLaserData ho_data[85][72][4]
HcalDetDiagLaserData calib_data[5][5][72]
void HcalDetDiagLaserMonitor::LoadReference ( )
private

Definition at line 1745 of file HcalDetDiagLaserMonitor.cc.

References calib_data, reco::tau::disc::Eta(), f, hb_data, he_data, hf_data, ho_data, IsReference, colinearityKinematic::Phi, ReferenceData, ReferenceRun, plotscripts::rms(), HcalDetDiagLaserData::set_reference(), lumiQTWidget::t, and cond::rpcobgas::time.

Referenced by beginRun().

1745  {
1746 double amp,rms,time,time_rms;
1747 int Eta,Phi,Depth;
1748 char subdet[10];
1749 TFile *f;
1750  if(gSystem->AccessPathName(ReferenceData.c_str())) return;
1751  f = new TFile(ReferenceData.c_str(),"READ");
1752 
1753  if(!f->IsOpen()) return ;
1754  TObjString *STR=(TObjString *)f->Get("run number");
1755 
1756  if(STR){ std::string Ref(STR->String()); ReferenceRun=Ref;}
1757 
1758  TTree* t=(TTree*)f->Get("HCAL Laser data");
1759  if(!t) return;
1760  t->SetBranchAddress("Subdet", subdet);
1761  t->SetBranchAddress("eta", &Eta);
1762  t->SetBranchAddress("phi", &Phi);
1763  t->SetBranchAddress("depth", &Depth);
1764  t->SetBranchAddress("amp", &amp);
1765  t->SetBranchAddress("rms", &rms);
1766  t->SetBranchAddress("time", &time);
1767  t->SetBranchAddress("time_rms", &time_rms);
1768  for(int ievt=0;ievt<t->GetEntries();ievt++){
1769  t->GetEntry(ievt);
1770  if(strcmp(subdet,"HB")==0) hb_data[Eta+42][Phi-1][Depth-1].set_reference(amp,rms,time,time_rms);
1771  if(strcmp(subdet,"HE")==0) he_data[Eta+42][Phi-1][Depth-1].set_reference(amp,rms,time,time_rms);
1772  if(strcmp(subdet,"HO")==0) ho_data[Eta+42][Phi-1][Depth-1].set_reference(amp,rms,time,time_rms);
1773  if(strcmp(subdet,"HF")==0) hf_data[Eta+42][Phi-1][Depth-1].set_reference(amp,rms,time,time_rms);
1774  if(strcmp(subdet,"CALIB_HB")==0) calib_data[1][Eta+2][Phi-1].set_reference(amp,rms,time,time_rms);
1775  if(strcmp(subdet,"CALIB_HE")==0) calib_data[2][Eta+2][Phi-1].set_reference(amp,rms,time,time_rms);
1776  if(strcmp(subdet,"CALIB_HO")==0) calib_data[3][Eta+2][Phi-1].set_reference(amp,rms,time,time_rms);
1777  if(strcmp(subdet,"CALIB_HF")==0) calib_data[4][Eta+2][Phi-1].set_reference(amp,rms,time,time_rms);
1778  }
1779  f->Close();
1780  IsReference=true;
1781 }
void set_reference(float val, float rms, float time, float time_rms)
double f[11][100]
HcalDetDiagLaserData hb_data[85][72][4]
HcalDetDiagLaserData hf_data[85][72][4]
HcalDetDiagLaserData he_data[85][72][4]
HcalDetDiagLaserData ho_data[85][72][4]
HcalDetDiagLaserData calib_data[5][5][72]
void HcalDetDiagLaserMonitor::SaveRaddamData ( )
private

Definition at line 1860 of file HcalDetDiagLaserMonitor.cc.

References adc2fC, HcalRaddamData::CUT1EVNT, HcalRaddamData::CUT2EVNT, dataset_seq_number, Raddam_ch::depth, Raddam_ch::eta, eta(), i, j, N, n, OutputFilePath, Overwrite, phi, Raddam_ch::phi, run_number, S1, HcalRaddamData::s1_adc, HcalRaddamData::S1BINWIDTH, HcalRaddamData::S1CHI2, HcalRaddamData::S1FITMEAN, HcalRaddamData::S1FITMEANER, HcalRaddamData::S1FITSIGMA, HcalRaddamData::S1MEAN, HcalRaddamData::S1NDF, HcalRaddamData::S1RMS, S2, HcalRaddamData::s2_adc, HcalRaddamData::S2BINWIDTH, HcalRaddamData::S2CHI2, HcalRaddamData::S2FITMEAN, HcalRaddamData::S2FITMEANER, HcalRaddamData::S2FITSIGMA, HcalRaddamData::S2MEAN, HcalRaddamData::S2NDF, HcalRaddamData::S2RMS, lumiQTWidget::t, interactiveExample::theFile, cond::rpcobgas::time, HcalRaddamData::TOTEVNT, xmlFile(), and XmlFilePath.

Referenced by endRun().

1860  {
1861 float adc_range[20]={14,28,40,52,67,132,202,262,322,397,722,1072,1372,1672,2047,3672,5422,6922,8422,10297};
1862 int adc_bins[20]={1,2,3,4,5,5,10,15,20,25,25,50,75,100,125,125,250,375,500,625};
1863 char str[100];
1864  TF1 *fitFunc = new TF1("fitFunc","gaus");
1865  if(fitFunc==0) return;
1866  for(int i=0;i<56;i++){
1867  float sum1=0,sum2=0,n=0;
1868  S1[i]=S2[i]=0;
1869  for(int j=0;j<128;j++){
1870  sum1+=(adc2fC[j]-2.5)*Raddam_data[i].s1_adc[j];
1871  sum2+=(adc2fC[j]-2.5)*Raddam_data[i].s2_adc[j];
1872  n+=Raddam_data[i].s1_adc[j];
1873  }
1874  if(n<100) continue;
1875  sum1=sum1/n;
1876  sum2=sum2/n;
1877  int N=0;
1878  int Ws1=1,Ws2=1;
1879  for(N=1;N<19;N++) if(sum1>adc_range[N-1] && sum1<adc_range[N]) break;
1880  Ws1=adc_bins[N+1];
1881  for(N=1;N<19;N++) if(sum2>adc_range[N-1] && sum2<adc_range[N]) break;
1882  Ws2=adc_bins[N+1];
1883  sprintf(str,"Raddam(%i,%i,%i) S1",RADDAM_CH[i].eta,RADDAM_CH[i].phi,RADDAM_CH[i].depth);
1884  S1[i]=new TH1F(str,str,10000/Ws1,0,10000);
1885  sprintf(str,"Raddam(%i,%i,%i) S2",RADDAM_CH[i].eta,RADDAM_CH[i].phi,RADDAM_CH[i].depth);
1886  S2[i]=new TH1F(str,str,10000/Ws1,0,10000);
1887  for(int j=0;j<128;j++){
1888  S1[i]->Fill(adc2fC[j]-2.5,Raddam_data[i].s1_adc[j]);
1889  S2[i]->Fill(adc2fC[j]-2.5,Raddam_data[i].s2_adc[j]);
1890  }
1891  double parm[3];
1892  S1[i]->Fit("fitFunc");
1893  S1[i]->GetFunction("fitFunc")->GetParameters(parm);
1894  Raddam_data[i].S1MEAN=S1[i]->GetMean();
1895  Raddam_data[i].S1RMS=S1[i]->GetRMS();
1896  Raddam_data[i].S1FITMEAN=parm[1];
1897  Raddam_data[i].S1FITMEANER=S1[i]->GetFunction("fitFunc")->GetParError(1);
1898  Raddam_data[i].S1FITSIGMA=parm[2];
1899  Raddam_data[i].S1CHI2=S1[i]->GetFunction("fitFunc")->GetChisquare();
1900  Raddam_data[i].S1NDF=S1[i]->GetFunction("fitFunc")->GetNDF();
1901  Raddam_data[i].S1BINWIDTH=Ws1;
1902  S2[i]->Fit("fitFunc");
1903  S2[i]->GetFunction("fitFunc")->GetParameters(parm);
1904  Raddam_data[i].S2MEAN=S2[i]->GetMean();
1905  Raddam_data[i].S2RMS=S2[i]->GetRMS();
1906  Raddam_data[i].S2FITMEAN=parm[1];
1907  Raddam_data[i].S2FITMEANER=S2[i]->GetFunction("fitFunc")->GetParError(1);
1908  Raddam_data[i].S2FITSIGMA=parm[2];
1909  Raddam_data[i].S2CHI2=S2[i]->GetFunction("fitFunc")->GetChisquare();
1910  Raddam_data[i].S2NDF=S2[i]->GetFunction("fitFunc")->GetNDF();
1911  Raddam_data[i].S2BINWIDTH=Ws2;
1912  }
1913  if(XmlFilePath.size()>0){
1914  char TIME[40];
1915  Long_t t; t=time(0); strftime(TIME,30,"%F %T",localtime(&t));
1916  //create XML file
1917  if(!Overwrite){
1918  sprintf(str,"HcalDetDiagRaddam_%i_%i.xml",run_number,dataset_seq_number);
1919  }else{
1920  sprintf(str,"HcalDetDiagRaddam.xml");
1921  }
1922  std::string xmlName=str;
1923  ofstream xmlFile;
1924  xmlFile.open(xmlName.c_str());
1925  xmlFile<<"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\" ?>\n";
1926  xmlFile<<"<ROOT>\n";
1927  xmlFile<<" <HEADER>\n";
1928  xmlFile<<" <TYPE>\n";
1929  xmlFile<<" <EXTENSION_TABLE_NAME>HCAL_RADDAM</EXTENSION_TABLE_NAME>\n";
1930  xmlFile<<" <NAME>HCAL Raddam</NAME>\n";
1931  xmlFile<<" </TYPE>\n";
1932  xmlFile<<" <!-- run details -->\n";
1933  xmlFile<<" <RUN>\n";
1934  xmlFile<<" <RUN_TYPE>TEST LOCAL-RUN</RUN_TYPE>\n";
1935  xmlFile<<" <RUN_NUMBER>"<<run_number<<"</RUN_NUMBER>\n";
1936  xmlFile<<" <RUN_BEGIN_TIMESTAMP>"<<TIME<<"</RUN_BEGIN_TIMESTAMP>\n";
1937  xmlFile<<" <COMMENT_DESCRIPTION>hcal raddam data</COMMENT_DESCRIPTION>\n";
1938  xmlFile<<" <LOCATION>P5</LOCATION>\n";
1939  xmlFile<<" <INITIATED_BY_USER>dma</INITIATED_BY_USER>\n";
1940  xmlFile<<" </RUN>\n";
1941  xmlFile<<" </HEADER>\n";
1942  xmlFile<<" <DATA_SET>\n";
1943  xmlFile<<" <COMMENT_DESCRIPTION>Test Raddam data</COMMENT_DESCRIPTION>\n";
1944  xmlFile<<" <CREATE_TIMESTAMP>"<<TIME<<"</CREATE_TIMESTAMP>\n";
1945  xmlFile<<" <CREATED_BY_USER>dma</CREATED_BY_USER>\n";
1946  xmlFile<<" <VERSION>Test_Version_1</VERSION>\n";
1947 
1948  for(int i=0;i<56;i++){
1949  xmlFile<<" <DATA>\n";
1950  xmlFile<<" <SUBDET>HF</SUBDET>\n";
1951  xmlFile<<" <IETA>"<<RADDAM_CH[i].eta<<"</IETA>\n";
1952  xmlFile<<" <IPHI>"<<RADDAM_CH[i].phi<<"</IPHI>\n";
1953  xmlFile<<" <DEPTH>"<<RADDAM_CH[i].depth<<"</DEPTH>\n";
1954 
1955  xmlFile<<" <TOTEVNT>"<<Raddam_data[i].TOTEVNT<<"</TOTEVNT>\n";
1956  xmlFile<<" <CUT1EVNT>"<<Raddam_data[i].CUT1EVNT<<"</CUT1EVNT>\n";
1957  xmlFile<<" <CUT2EVNT>"<<Raddam_data[i].CUT2EVNT<<"</CUT2EVNT>\n";
1958 
1959  xmlFile<<" <S1MEAN>"<<Raddam_data[i].S1MEAN <<"</S1MEAN>\n";
1960  xmlFile<<" <S1RMS>"<<Raddam_data[i].S1RMS <<"</S1RMS>\n";
1961  xmlFile<<" <S1FITMEAN>"<<Raddam_data[i].S1FITMEAN <<"</S1FITMEAN>\n";
1962  xmlFile<<" <S1FITMEANER>"<<Raddam_data[i].S1FITMEANER <<"</S1FITMEANER>\n";
1963  xmlFile<<" <S1FITSIGMA>"<<Raddam_data[i].S1FITSIGMA <<"</S1FITSIGMA>\n";
1964  xmlFile<<" <S1CHI2>"<<Raddam_data[i].S1CHI2 <<"</S1CHI2>\n";
1965  xmlFile<<" <S1NDF>"<<Raddam_data[i].S1NDF <<"</S1NDF>\n";
1966  xmlFile<<" <S1BINWIDTH>"<<Raddam_data[i].S1BINWIDTH <<"</S1BINWIDTH>\n";
1967 
1968  xmlFile<<" <S2MEAN>"<<Raddam_data[i].S2MEAN <<"</S2MEAN>\n";
1969  xmlFile<<" <S2RMS>"<<Raddam_data[i].S2RMS <<"</S2RMS>\n";
1970  xmlFile<<" <S2FITMEAN>"<<Raddam_data[i].S2FITMEAN <<"</S2FITMEAN>\n";
1971  xmlFile<<" <S2FITMEANER>"<<Raddam_data[i].S2FITMEANER <<"</S2FITMEANER>\n";
1972  xmlFile<<" <S2FITSIGMA>"<<Raddam_data[i].S2FITSIGMA <<"</S2FITSIGMA>\n";
1973  xmlFile<<" <S2CHI2>"<<Raddam_data[i].S2CHI2 <<"</S2CHI2>\n";
1974  xmlFile<<" <S2NDF>"<<Raddam_data[i].S2NDF <<"</S2NDF>\n";
1975  xmlFile<<" <S2BINWIDTH>"<<Raddam_data[i].S2BINWIDTH <<"</S2BINWIDTH>\n";
1976  xmlFile<<" </DATA>\n";
1977  }
1978  xmlFile<<" </DATA_SET>\n";
1979  xmlFile<<"</ROOT>\n";
1980 
1981  xmlFile.close();
1982  sprintf(str,"zip %s.zip %s",xmlName.c_str(),xmlName.c_str());
1983  system(str);
1984  sprintf(str,"rm -f %s",xmlName.c_str());
1985  system(str);
1986  sprintf(str,"mv -f %s.zip %s",xmlName.c_str(),XmlFilePath.c_str());
1987  system(str);
1988  }
1989  if(OutputFilePath.size()>0){
1990  if(!Overwrite){
1991  sprintf(str,"%sHcalDetDiagRaddamData_run%06i_%i.root",OutputFilePath.c_str(),run_number,dataset_seq_number);
1992  }else{
1993  sprintf(str,"%sHcalDetDiagRaddamData.root",OutputFilePath.c_str());
1994  }
1995  TFile *theFile = new TFile(str, "RECREATE");
1996  if(!theFile->IsOpen()) return;
1997  theFile->cd();
1998  for(int i=0;i<56;i++){
1999  if(S1[i]!=0)S1[i]->Write();
2000  if(S2[i]!=0)S2[i]->Write();
2001  }
2002  theFile->Write();
2003  theFile->Close();
2004  }
2005 }
int i
Definition: DBlmapReader.cc:9
static const float adc2fC[128]
HcalRaddamData Raddam_data[56]
T eta() const
Raddam_ch RADDAM_CH[56]
int j
Definition: DBlmapReader.cc:9
#define N
Definition: blowfish.cc:9
bool xmlFile(const std::string fParam)
Definition: DDAxes.h:10
void HcalDetDiagLaserMonitor::SaveReference ( )
private

Definition at line 1414 of file HcalDetDiagLaserMonitor.cc.

References HcalElectronicsMap::allElectronicsIdPrecision(), calib_data, dataset_seq_number, HcalDetId::depth(), DetId::det(), cond::rpcobgas::detid, alignCSCRings::e, emap, reco::tau::disc::Eta(), eta(), patZpeak::events, HcalDetDiagLaserData::get_average_amp1(), HcalDetDiagLaserData::get_average_time1(), HcalDetDiagLaserData::get_statistics1(), HcalDetDiagLaserData::get_status(), hb_data, DetId::Hcal, HcalBarrel, HcalEndcap, HcalForward, HcalGenericDetId::HcalGenBarrel, HcalGenericDetId::HcalGenEndcap, HcalGenericDetId::HcalGenForward, HcalGenericDetId::HcalGenOuter, HcalOuter, he_data, hf_data, ho_data, i, HcalDetId::ieta(), ievt_, HcalDetId::iphi(), j, gen::k, HcalElectronicsMap::lookup(), OutputFilePath, Overwrite, phi, colinearityKinematic::Phi, plotscripts::rms(), DTTTrigCorrFirst::run, run_number, sd, step1_ZMM_7Tev::Status, DetId::subdetId(), lumiQTWidget::t, interactiveExample::theFile, cond::rpcobgas::time, diffTreeTool::tree, xmlFile(), and XmlFilePath.

Referenced by analyze(), and endRun().

1414  {
1415 double amp,rms,Time,time_rms;
1416 int Eta,Phi,Depth,Statistic,Status=0;
1417 char Subdet[10],str[500];
1418  if(OutputFilePath.size()>0){
1419  if(!Overwrite){
1420  sprintf(str,"%sHcalDetDiagLaserData_run%06i_%i.root",OutputFilePath.c_str(),run_number,dataset_seq_number);
1421  }else{
1422  sprintf(str,"%sHcalDetDiagLaserData.root",OutputFilePath.c_str());
1423  }
1424  TFile *theFile = new TFile(str, "RECREATE");
1425  if(!theFile->IsOpen()) return;
1426  theFile->cd();
1427  sprintf(str,"%d",run_number); TObjString run(str); run.Write("run number");
1428  sprintf(str,"%d",ievt_); TObjString events(str); events.Write("Total events processed");
1429  sprintf(str,"%d",dataset_seq_number); TObjString dsnum(str); dsnum.Write("Dataset number");
1430  Long_t t; t=time(0); strftime(str,30,"%F %T",localtime(&t)); TObjString tm(str); tm.Write("Dataset creation time");
1431 
1432  TTree *tree =new TTree("HCAL Laser data","HCAL Laser data");
1433  if(tree==0) return;
1434  tree->Branch("Subdet", &Subdet, "Subdet/C");
1435  tree->Branch("eta", &Eta, "Eta/I");
1436  tree->Branch("phi", &Phi, "Phi/I");
1437  tree->Branch("depth", &Depth, "Depth/I");
1438  tree->Branch("statistic",&Statistic, "Statistic/I");
1439  tree->Branch("status", &Status, "Status/I");
1440  tree->Branch("amp", &amp, "amp/D");
1441  tree->Branch("rms", &rms, "rms/D");
1442  tree->Branch("time", &Time, "time/D");
1443  tree->Branch("time_rms", &time_rms, "time_rms/D");
1444  sprintf(Subdet,"HB");
1445  for(int eta=-16;eta<=16;eta++) for(int phi=1;phi<=72;phi++) for(int depth=1;depth<=2;depth++){
1446  if((Statistic=hb_data[eta+42][phi-1][depth-1].get_statistics1())>10){
1447  Eta=eta; Phi=phi; Depth=depth;
1448  Status=hb_data[eta+42][phi-1][depth-1].get_status();
1449  hb_data[eta+42][phi-1][depth-1].get_average_amp1(&amp,&rms);
1450  hb_data[eta+42][phi-1][depth-1].get_average_time1(&Time,&time_rms);
1451  tree->Fill();
1452  }
1453  }
1454  sprintf(Subdet,"HE");
1455  for(int eta=-29;eta<=29;eta++) for(int phi=1;phi<=72;phi++) for(int depth=1;depth<=3;depth++){
1456  if((Statistic=he_data[eta+42][phi-1][depth-1].get_statistics1())>10){
1457  Eta=eta; Phi=phi; Depth=depth;
1458  Status=he_data[eta+42][phi-1][depth-1].get_status();
1459  he_data[eta+42][phi-1][depth-1].get_average_amp1(&amp,&rms);
1460  he_data[eta+42][phi-1][depth-1].get_average_time1(&Time,&time_rms);
1461  tree->Fill();
1462  }
1463  }
1464  sprintf(Subdet,"HO");
1465  for(int eta=-15;eta<=15;eta++) for(int phi=1;phi<=72;phi++) for(int depth=4;depth<=4;depth++){
1466  if((Statistic=ho_data[eta+42][phi-1][depth-1].get_statistics1())>10){
1467  Eta=eta; Phi=phi; Depth=depth;
1468  Status=ho_data[eta+42][phi-1][depth-1].get_status();
1469  ho_data[eta+42][phi-1][depth-1].get_average_amp1(&amp,&rms);
1470  ho_data[eta+42][phi-1][depth-1].get_average_time1(&Time,&time_rms);
1471  tree->Fill();
1472  }
1473  }
1474  sprintf(Subdet,"HF");
1475  for(int eta=-42;eta<=42;eta++) for(int phi=1;phi<=72;phi++) for(int depth=1;depth<=2;depth++){
1476  if((Statistic=hf_data[eta+42][phi-1][depth-1].get_statistics1())>10){
1477  Eta=eta; Phi=phi; Depth=depth;
1478  Status=hf_data[eta+42][phi-1][depth-1].get_status();
1479  hf_data[eta+42][phi-1][depth-1].get_average_amp1(&amp,&rms);
1480  hf_data[eta+42][phi-1][depth-1].get_average_time1(&Time,&time_rms);
1481  tree->Fill();
1482  }
1483  }
1484  sprintf(Subdet,"CALIB_HB");
1485  for(int eta=-1;eta<=1;eta++) for(int phi=1;phi<=72;phi++){
1486  if((Statistic=calib_data[1][eta+2][phi-1].get_statistics1())>10){
1487  Eta=eta; Phi=phi; Depth=0;
1488  Status=calib_data[1][eta+2][phi-1].get_status();
1489  calib_data[1][eta+2][phi-1].get_average_amp1(&amp,&rms);
1490  calib_data[1][eta+2][phi-1].get_average_time1(&Time,&time_rms);
1491  tree->Fill();
1492  }
1493  }
1494  sprintf(Subdet,"CALIB_HE");
1495  for(int eta=-1;eta<=1;eta++) for(int phi=1;phi<=72;phi++){
1496  if((Statistic=calib_data[2][eta+2][phi-1].get_statistics1())>10){
1497  Eta=eta; Phi=phi; Depth=0;
1498  Status=calib_data[2][eta+2][phi-1].get_status();
1499  calib_data[2][eta+2][phi-1].get_average_amp1(&amp,&rms);
1500  calib_data[2][eta+2][phi-1].get_average_time1(&Time,&time_rms);
1501  tree->Fill();
1502  }
1503  }
1504  sprintf(Subdet,"CALIB_HO");
1505  for(int eta=-2;eta<=2;eta++) for(int phi=1;phi<=72;phi++){
1506  if((Statistic=calib_data[3][eta+2][phi-1].get_statistics1())>10){
1507  Eta=eta; Phi=phi; Depth=0;
1508  Status=calib_data[3][eta+2][phi-1].get_status();
1509  calib_data[3][eta+2][phi-1].get_average_amp1(&amp,&rms);
1510  calib_data[3][eta+2][phi-1].get_average_time1(&Time,&time_rms);
1511  tree->Fill();
1512  }
1513  }
1514  sprintf(Subdet,"CALIB_HF");
1515  for(int eta=-2;eta<=2;eta++) for(int phi=1;phi<=72;phi++){
1516  if((Statistic=calib_data[4][eta+2][phi-1].get_statistics1())>10){
1517  Eta=eta; Phi=phi; Depth=0;
1518  Status=calib_data[4][eta+2][phi-1].get_status();
1519  calib_data[4][eta+2][phi-1].get_average_amp1(&amp,&rms);
1520  calib_data[4][eta+2][phi-1].get_average_time1(&Time,&time_rms);
1521  tree->Fill();
1522  }
1523  }
1524  theFile->Write();
1525  theFile->Close();
1526  }
1527  if(XmlFilePath.size()>0){
1528  char TIME[40];
1529  Long_t t; t=time(0); strftime(TIME,30,"%F %T",localtime(&t));
1530  //create XML file
1531  if(!Overwrite){
1532  sprintf(str,"HcalDetDiagLaser_%i_%i.xml",run_number,dataset_seq_number);
1533  }else{
1534  sprintf(str,"HcalDetDiagLaser.xml");
1535  }
1536  std::string xmlName=str;
1537  ofstream xmlFile;
1538  xmlFile.open(xmlName.c_str());
1539 
1540  xmlFile<<"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?>\n";
1541  xmlFile<<"<ROOT>\n";
1542  xmlFile<<" <HEADER>\n";
1543  xmlFile<<" <HINTS mode='only-det-root'/>\n";
1544  xmlFile<<" <TYPE>\n";
1545  xmlFile<<" <EXTENSION_TABLE_NAME>HCAL_DETMON_LED_LASER_V1</EXTENSION_TABLE_NAME>\n";
1546  xmlFile<<" <NAME>HCAL Laser HBHE HPD [abort gap global]</NAME>\n";
1547  xmlFile<<" </TYPE>\n";
1548  xmlFile<<" <!-- run details -->\n";
1549  xmlFile<<" <RUN>\n";
1550  xmlFile<<" <RUN_TYPE>GLOBAL-RUN</RUN_TYPE>\n";
1551  xmlFile<<" <RUN_NUMBER>"<<run_number<<"</RUN_NUMBER>\n";
1552  xmlFile<<" <RUN_BEGIN_TIMESTAMP>2009-01-01 00:00:00</RUN_BEGIN_TIMESTAMP>\n";
1553  xmlFile<<" <COMMENT_DESCRIPTION>hcal laser data</COMMENT_DESCRIPTION>\n";
1554  xmlFile<<" <LOCATION>P5</LOCATION>\n";
1555  xmlFile<<" <INITIATED_BY_USER>dma</INITIATED_BY_USER>\n";
1556  xmlFile<<" </RUN>\n";
1557  xmlFile<<" </HEADER>\n";
1558  xmlFile<<" <DATA_SET>\n";
1559  xmlFile<<" <!-- optional dataset metadata -->\n\n";
1560  xmlFile<<" <SET_NUMBER>"<<dataset_seq_number<<"</SET_NUMBER>\n";
1561  xmlFile<<" <SET_BEGIN_TIMESTAMP>2009-01-01 00:00:00</SET_BEGIN_TIMESTAMP>\n";
1562  xmlFile<<" <SET_END_TIMESTAMP>2009-01-01 00:00:00</SET_END_TIMESTAMP>\n";
1563  xmlFile<<" <NUMBER_OF_EVENTS_IN_SET>"<<ievt_<<"</NUMBER_OF_EVENTS_IN_SET>\n";
1564  xmlFile<<" <COMMENT_DESCRIPTION>Automatic DQM output</COMMENT_DESCRIPTION>\n";
1565  xmlFile<<" <DATA_FILE_NAME>"<< xmlName <<"</DATA_FILE_NAME>\n";
1566  xmlFile<<" <IMAGE_FILE_NAME>data plot url or file path</IMAGE_FILE_NAME>\n";
1567  xmlFile<<" <!-- who and when created this dataset-->\n\n";
1568  xmlFile<<" <CREATE_TIMESTAMP>"<<TIME<<"</CREATE_TIMESTAMP>\n";
1569  xmlFile<<" <CREATED_BY_USER>dma</CREATED_BY_USER>\n";
1570  xmlFile<<" <!-- version (string) and subversion (number) -->\n";
1571  xmlFile<<" <!-- fields are used to read data back from the database -->\n\n";
1572  xmlFile<<" <VERSION>"<<run_number<<dataset_seq_number<<"</VERSION>\n";
1573  xmlFile<<" <SUBVERSION>1</SUBVERSION>\n";
1574  xmlFile<<" <!-- Assign predefined dataset attributes -->\n\n";
1575  xmlFile<<" <PREDEFINED_ATTRIBUTES>\n";
1576  xmlFile<<" <ATTRIBUTE>\n";
1577  xmlFile<<" <NAME>HCAL Dataset Status</NAME>\n";
1578  xmlFile<<" <VALUE>VALID</VALUE>\n";
1579  xmlFile<<" </ATTRIBUTE>\n";
1580  xmlFile<<" </PREDEFINED_ATTRIBUTES>\n";
1581  xmlFile<<" <!-- multiple data block records -->\n\n";
1582 
1583  std::vector <HcalElectronicsId> AllElIds = emap->allElectronicsIdPrecision();
1584  for(std::vector <HcalElectronicsId>::iterator eid = AllElIds.begin(); eid != AllElIds.end(); eid++){
1585  DetId detid=emap->lookup(*eid);
1586  if (detid.det()!=DetId::Hcal) continue;
1587  HcalGenericDetId gid(emap->lookup(*eid));
1588  if(!(!(gid.null()) &&
1589  (gid.genericSubdet()==HcalGenericDetId::HcalGenBarrel ||
1590  gid.genericSubdet()==HcalGenericDetId::HcalGenEndcap ||
1591  gid.genericSubdet()==HcalGenericDetId::HcalGenForward ||
1592  gid.genericSubdet()==HcalGenericDetId::HcalGenOuter))) continue;
1593  int eta,phi,depth;
1594  std::string subdet="";
1595  HcalDetId hid(detid);
1596  eta=hid.ieta();
1597  phi=hid.iphi();
1598  depth=hid.depth();
1599 
1600  double e=0,e_rms=0,t=0,t_rms=0;
1601  if(detid.subdetId()==HcalBarrel){
1602  subdet="HB";
1603  Statistic=hb_data[eta+42][phi-1][depth-1].get_statistics1();
1604  Status =hb_data[eta+42][phi-1][depth-1].get_status();
1605  hb_data[eta+42][phi-1][depth-1].get_average_amp1(&e,&e_rms);
1606  hb_data[eta+42][phi-1][depth-1].get_average_time1(&t,&t_rms);
1607  }else if(detid.subdetId()==HcalEndcap){
1608  subdet="HE";
1609  Statistic=he_data[eta+42][phi-1][depth-1].get_statistics1();
1610  Status =he_data[eta+42][phi-1][depth-1].get_status();
1611  he_data[eta+42][phi-1][depth-1].get_average_amp1(&e,&e_rms);
1612  he_data[eta+42][phi-1][depth-1].get_average_time1(&t,&t_rms);
1613  }else if(detid.subdetId()==HcalForward){
1614  subdet="HF";
1615  Statistic=hf_data[eta+42][phi-1][depth-1].get_statistics1();
1616  Status =hf_data[eta+42][phi-1][depth-1].get_status();
1617  hf_data[eta+42][phi-1][depth-1].get_average_amp1(&e,&e_rms);
1618  hf_data[eta+42][phi-1][depth-1].get_average_time1(&t,&t_rms);
1619  }else if(detid.subdetId()==HcalOuter){
1620  subdet="HO";
1621  Statistic=ho_data[eta+42][phi-1][depth-1].get_statistics1();
1622  Status =ho_data[eta+42][phi-1][depth-1].get_status();
1623  ho_data[eta+42][phi-1][depth-1].get_average_amp1(&e,&e_rms);
1624  ho_data[eta+42][phi-1][depth-1].get_average_time1(&t,&t_rms);
1625  }else continue;
1626  xmlFile<<" <DATA>\n";
1627  xmlFile<<" <NUMBER_OF_EVENTS_USED>"<<Statistic<<"</NUMBER_OF_EVENTS_USED>\n";
1628  xmlFile<<" <SIGNAL_MEAN>"<<e<<"</SIGNAL_MEAN>\n";
1629  xmlFile<<" <SIGNAL_RMS>"<<e_rms<<"</SIGNAL_RMS>\n";
1630  xmlFile<<" <TIME_MEAN>"<<t<<"</TIME_MEAN>\n";
1631  xmlFile<<" <TIME_RMS>"<<t_rms<<"</TIME_RMS>\n";
1632  xmlFile<<" <CHANNEL_STATUS_WORD>"<<Status<<"</CHANNEL_STATUS_WORD>\n";
1633  xmlFile<<" <CHANNEL_OBJECTNAME>HcalDetId</CHANNEL_OBJECTNAME>\n";
1634  xmlFile<<" <SUBDET>"<<subdet<<"</SUBDET>\n";
1635  xmlFile<<" <IETA>"<<eta<<"</IETA>\n";
1636  xmlFile<<" <IPHI>"<<phi<<"</IPHI>\n";
1637  xmlFile<<" <DEPTH>"<<depth<<"</DEPTH>\n";
1638  xmlFile<<" <TYPE>0</TYPE>\n";
1639  xmlFile<<" </DATA>\n";
1640  }
1642  xmlFile<<" </DATA_SET>\n";
1643  xmlFile<<"</ROOT>\n";
1644  xmlFile.close();
1645 
1646 
1647  //create CALIB XML file
1648  sprintf(str,"HcalDetDiagLaserCalib_%i_%i.xml",run_number,dataset_seq_number);
1649  std::string xmlNameCalib=str;
1650  ofstream xmlFileCalib;
1651  xmlFileCalib.open(xmlNameCalib.c_str());
1652 
1653  xmlFileCalib<<"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?>\n";
1654  xmlFileCalib<<"<ROOT>\n";
1655  xmlFileCalib<<" <HEADER>\n";
1656  xmlFileCalib<<" <HINTS mode='only-det-root'/>\n";
1657  xmlFileCalib<<" <TYPE>\n";
1658  xmlFileCalib<<" <EXTENSION_TABLE_NAME>HCAL_DETMON_LED_LASER_V1</EXTENSION_TABLE_NAME>\n";
1659  xmlFileCalib<<" <NAME>HCAL Laser CALIB [abort gap global]</NAME>\n";
1660  xmlFileCalib<<" </TYPE>\n";
1661  xmlFileCalib<<" <!-- run details -->\n";
1662  xmlFileCalib<<" <RUN>\n";
1663  xmlFileCalib<<" <RUN_TYPE>Global-RUN</RUN_TYPE>\n";
1664  xmlFileCalib<<" <RUN_NUMBER>"<<run_number<<"</RUN_NUMBER>\n";
1665  xmlFileCalib<<" <RUN_BEGIN_TIMESTAMP>2009-01-01 00:00:00</RUN_BEGIN_TIMESTAMP>\n";
1666  xmlFileCalib<<" <COMMENT_DESCRIPTION>hcal Laser CALIB data</COMMENT_DESCRIPTION>\n";
1667  xmlFileCalib<<" <LOCATION>P5</LOCATION>\n";
1668  xmlFileCalib<<" <INITIATED_BY_USER>dma</INITIATED_BY_USER>\n";
1669  xmlFileCalib<<" </RUN>\n";
1670  xmlFileCalib<<" </HEADER>\n";
1671  xmlFileCalib<<" <DATA_SET>\n";
1672  xmlFileCalib<<" <!-- optional dataset metadata -->\n\n";
1673  xmlFileCalib<<" <SET_NUMBER>"<<dataset_seq_number<<"</SET_NUMBER>\n";
1674  xmlFileCalib<<" <SET_BEGIN_TIMESTAMP>2009-01-01 00:00:00</SET_BEGIN_TIMESTAMP>\n";
1675  xmlFileCalib<<" <SET_END_TIMESTAMP>2009-01-01 00:00:00</SET_END_TIMESTAMP>\n";
1676  xmlFileCalib<<" <NUMBER_OF_EVENTS_IN_SET>"<<ievt_<<"</NUMBER_OF_EVENTS_IN_SET>\n";
1677  xmlFileCalib<<" <COMMENT_DESCRIPTION>Automatic DQM output</COMMENT_DESCRIPTION>\n";
1678  xmlFileCalib<<" <DATA_FILE_NAME>"<< xmlNameCalib <<"</DATA_FILE_NAME>\n";
1679  xmlFileCalib<<" <IMAGE_FILE_NAME>data plot url or file path</IMAGE_FILE_NAME>\n";
1680  xmlFileCalib<<" <!-- who and when created this dataset-->\n\n";
1681  xmlFileCalib<<" <CREATE_TIMESTAMP>"<<TIME<<"</CREATE_TIMESTAMP>\n";
1682  xmlFileCalib<<" <CREATED_BY_USER>dma</CREATED_BY_USER>\n";
1683  xmlFileCalib<<" <!-- version (string) and subversion (number) -->\n";
1684  xmlFileCalib<<" <!-- fields are used to read data back from the database -->\n\n";
1685  xmlFileCalib<<" <VERSION>"<<run_number<<dataset_seq_number<<"</VERSION>\n";
1686  xmlFileCalib<<" <SUBVERSION>1</SUBVERSION>\n";
1687  xmlFileCalib<<" <!-- Assign predefined dataset attributes -->\n\n";
1688  xmlFileCalib<<" <PREDEFINED_ATTRIBUTES>\n";
1689  xmlFileCalib<<" <ATTRIBUTE>\n";
1690  xmlFileCalib<<" <NAME>HCAL Dataset Status</NAME>\n";
1691  xmlFileCalib<<" <VALUE>VALID</VALUE>\n";
1692  xmlFileCalib<<" </ATTRIBUTE>\n";
1693  xmlFileCalib<<" </PREDEFINED_ATTRIBUTES>\n";
1694  xmlFileCalib<<" <!-- multiple data block records -->\n\n";
1695 
1696  for(int sd=1;sd<=4;sd++) for(int eta=-2;eta<=2;eta++) for(int phi=1;phi<=72;phi++){
1697  std::string subdet="";
1698  if(sd==1) subdet="HB";
1699  if(sd==2) subdet="HE";
1700  if(sd==3) subdet="HO";
1701  if(sd==4) subdet="HF";
1702  if((calib_data[sd][eta+2][phi-1].get_statistics())>100){
1703  double e=0,e_rms=0,t=0,t_rms=0;
1704  Status=calib_data[sd][eta+2][phi-1].get_status();
1705  Statistic=calib_data[sd][eta+2][phi-1].get_statistics1();
1706  calib_data[sd][eta+2][phi-1].get_average_amp1(&e,&e_rms);
1707  calib_data[sd][eta+2][phi-1].get_average_time1(&t,&t_rms);
1708  xmlFileCalib<<" <DATA>\n";
1709  xmlFileCalib<<" <NUMBER_OF_EVENTS_USED>"<<Statistic<<"</NUMBER_OF_EVENTS_USED>\n";
1710  xmlFileCalib<<" <SIGNAL_MEAN>"<<e<<"</SIGNAL_MEAN>\n";
1711  xmlFileCalib<<" <SIGNAL_RMS>"<<e_rms<<"</SIGNAL_RMS>\n";
1712  xmlFileCalib<<" <TIME_MEAN>"<<t<<"</TIME_MEAN>\n";
1713  xmlFileCalib<<" <TIME_RMS>"<<t_rms<<"</TIME_RMS>\n";
1714  xmlFileCalib<<" <CHANNEL_STATUS_WORD>"<<Status<<"</CHANNEL_STATUS_WORD>\n";
1715  xmlFileCalib<<" <CHANNEL_OBJECTNAME>HcalDetId</CHANNEL_OBJECTNAME>\n";
1716  xmlFileCalib<<" <SUBDET>"<<subdet<<"</SUBDET>\n";
1717  xmlFileCalib<<" <IETA>"<<eta<<"</IETA>\n";
1718  xmlFileCalib<<" <IPHI>"<<phi<<"</IPHI>\n";
1719  xmlFileCalib<<" <DEPTH>"<<0<<"</DEPTH>\n";
1720  xmlFileCalib<<" <TYPE>0</TYPE>\n";
1721  xmlFileCalib<<" </DATA>\n";
1722  }
1723  }
1725  xmlFileCalib<<" </DATA_SET>\n";
1726  xmlFileCalib<<"</ROOT>\n";
1727  xmlFileCalib.close();
1728 
1729  sprintf(str,"zip %s.zip %s %s",xmlName.c_str(),xmlName.c_str(),xmlNameCalib.c_str());
1730  system(str);
1731  sprintf(str,"rm -f %s %s",xmlName.c_str(),xmlNameCalib.c_str());
1732  system(str);
1733  sprintf(str,"mv -f %s.zip %s",xmlName.c_str(),XmlFilePath.c_str());
1734  system(str);
1735 
1736  }
1737  for(int i=0;i<85;i++)for(int j=0;j<72;j++)for(int k=0;k<4;k++) hb_data[i][j][k].reset1();
1738  for(int i=0;i<85;i++)for(int j=0;j<72;j++)for(int k=0;k<4;k++) he_data[i][j][k].reset1();
1739  for(int i=0;i<85;i++)for(int j=0;j<72;j++)for(int k=0;k<4;k++) ho_data[i][j][k].reset1();
1740  for(int i=0;i<85;i++)for(int j=0;j<72;j++)for(int k=0;k<4;k++) hf_data[i][j][k].reset1();
1741  for(int i=1;i<=4;i++)for(int j=-2;j<=2;j++)for(int k=1;k<=72;k++)calib_data[i][j][k].reset1();
1742  ievt_=0;
1743  dataset_seq_number++;
1744 }
int i
Definition: DBlmapReader.cc:9
std::vector< HcalElectronicsId > allElectronicsIdPrecision() const
bool get_average_amp1(double *ave, double *rms)
const HcalElectronicsMap * emap
T eta() const
int j
Definition: DBlmapReader.cc:9
int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:39
int k[5][pyjets_maxn]
Definition: DetId.h:20
HcalDetDiagLaserData hb_data[85][72][4]
bool get_average_time1(double *ave, double *rms)
double sd
bool xmlFile(const std::string fParam)
HcalDetDiagLaserData hf_data[85][72][4]
tuple events
Definition: patZpeak.py:19
HcalDetDiagLaserData he_data[85][72][4]
Detector det() const
get the detector field from this detid
Definition: DetId.h:37
HcalDetDiagLaserData ho_data[85][72][4]
HcalDetDiagLaserData calib_data[5][5][72]
const DetId lookup(HcalElectronicsId fId) const
lookup the logical detid associated with the given electronics id
Definition: DDAxes.h:10

Member Data Documentation

std::string HcalDetDiagLaserMonitor::baseFolder_
private

Definition at line 314 of file HcalDetDiagLaserMonitor.cc.

HcalDetDiagLaserData HcalDetDiagLaserMonitor::calib_data[5][5][72]
private
edm::InputTag HcalDetDiagLaserMonitor::calibDigiLabel_
private

Definition at line 289 of file HcalDetDiagLaserMonitor.cc.

Referenced by analyze(), and HcalDetDiagLaserMonitor().

bool HcalDetDiagLaserMonitor::createHTMLonly
private
int HcalDetDiagLaserMonitor::dataset_seq_number
private
std::string HcalDetDiagLaserMonitor::DatasetName
private

Definition at line 320 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), HcalDetDiagLaserMonitor(), and LoadDataset().

const HcalElectronicsMap* HcalDetDiagLaserMonitor::emap
private
MonitorElement* HcalDetDiagLaserMonitor::Energy2Dhbhehf
private

Definition at line 341 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement* HcalDetDiagLaserMonitor::Energy2Dho
private

Definition at line 342 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

HcalDetDiagLaserData HcalDetDiagLaserMonitor::hb_data[85][72][4]
private
MonitorElement* HcalDetDiagLaserMonitor::hb_time_rbx
private

Definition at line 348 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement* HcalDetDiagLaserMonitor::hbheEnergy
private

Definition at line 326 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement* HcalDetDiagLaserMonitor::hbheEnergyRMS
private

Definition at line 328 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement* HcalDetDiagLaserMonitor::hbheTime
private

Definition at line 327 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement* HcalDetDiagLaserMonitor::hbheTimeRMS
private

Definition at line 329 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

HcalDetDiagLaserData HcalDetDiagLaserMonitor::he_data[85][72][4]
private
MonitorElement* HcalDetDiagLaserMonitor::he_time_rbx
private

Definition at line 349 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

HcalDetDiagLaserData HcalDetDiagLaserMonitor::hf_data[85][72][4]
private
MonitorElement* HcalDetDiagLaserMonitor::hf_time_rbx
private

Definition at line 351 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement* HcalDetDiagLaserMonitor::hfEnergy
private

Definition at line 334 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement* HcalDetDiagLaserMonitor::hfEnergyRMS
private

Definition at line 336 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement* HcalDetDiagLaserMonitor::hfTime
private

Definition at line 335 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement* HcalDetDiagLaserMonitor::hfTimeRMS
private

Definition at line 337 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

HcalDetDiagLaserData HcalDetDiagLaserMonitor::ho_data[85][72][4]
private
MonitorElement* HcalDetDiagLaserMonitor::ho_time_rbx
private

Definition at line 350 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement* HcalDetDiagLaserMonitor::hoEnergy
private

Definition at line 330 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement* HcalDetDiagLaserMonitor::hoEnergyRMS
private

Definition at line 332 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement* HcalDetDiagLaserMonitor::hoTime
private

Definition at line 331 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement* HcalDetDiagLaserMonitor::hoTimeRMS
private

Definition at line 333 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement * HcalDetDiagLaserMonitor::htmlFolder
private

Definition at line 324 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun().

std::string HcalDetDiagLaserMonitor::htmlOutputPath
private

Definition at line 321 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and HcalDetDiagLaserMonitor().

int HcalDetDiagLaserMonitor::ievt_
private
edm::InputTag HcalDetDiagLaserMonitor::inputLabelDigi_
private

Definition at line 288 of file HcalDetDiagLaserMonitor.cc.

Referenced by analyze(), and HcalDetDiagLaserMonitor().

bool HcalDetDiagLaserMonitor::IsReference
private

Definition at line 307 of file HcalDetDiagLaserMonitor.cc.

Referenced by HcalDetDiagLaserMonitor(), and LoadReference().

std::map<unsigned int, int> HcalDetDiagLaserMonitor::KnownBadCells_
private

Definition at line 369 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillProblems().

double HcalDetDiagLaserMonitor::LaserEnergyThreshold
private

Definition at line 302 of file HcalDetDiagLaserMonitor.cc.

Referenced by fillProblems(), and HcalDetDiagLaserMonitor().

double HcalDetDiagLaserMonitor::LaserTimingThreshold
private

Definition at line 302 of file HcalDetDiagLaserMonitor.cc.

Referenced by fillProblems(), and HcalDetDiagLaserMonitor().

bool HcalDetDiagLaserMonitor::LocalRun
private

Definition at line 308 of file HcalDetDiagLaserMonitor.cc.

Referenced by analyze(), endRun(), and HcalDetDiagLaserMonitor().

MonitorElement* HcalDetDiagLaserMonitor::meEVT_
private

Definition at line 324 of file HcalDetDiagLaserMonitor.cc.

Referenced by analyze(), beginRun(), and LoadDataset().

MonitorElement * HcalDetDiagLaserMonitor::meRUN_
private

Definition at line 324 of file HcalDetDiagLaserMonitor.cc.

Referenced by analyze(), beginRun(), and LoadDataset().

int HcalDetDiagLaserMonitor::nHB
private

Definition at line 309 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), HcalDetDiagLaserMonitor(), and LoadDataset().

int HcalDetDiagLaserMonitor::nHBHEchecks
private

Definition at line 301 of file HcalDetDiagLaserMonitor.cc.

Referenced by HcalDetDiagLaserMonitor().

int HcalDetDiagLaserMonitor::nHE
private

Definition at line 309 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), HcalDetDiagLaserMonitor(), and LoadDataset().

int HcalDetDiagLaserMonitor::nHF
private

Definition at line 309 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), HcalDetDiagLaserMonitor(), and LoadDataset().

int HcalDetDiagLaserMonitor::nHFchecks
private

Definition at line 301 of file HcalDetDiagLaserMonitor.cc.

Referenced by HcalDetDiagLaserMonitor().

int HcalDetDiagLaserMonitor::nHO
private

Definition at line 309 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), HcalDetDiagLaserMonitor(), and LoadDataset().

int HcalDetDiagLaserMonitor::nHOchecks
private

Definition at line 301 of file HcalDetDiagLaserMonitor.cc.

Referenced by HcalDetDiagLaserMonitor().

bool HcalDetDiagLaserMonitor::Online_
private

Definition at line 316 of file HcalDetDiagLaserMonitor.cc.

Referenced by analyze(), endRun(), and HcalDetDiagLaserMonitor().

std::string HcalDetDiagLaserMonitor::OutputFilePath
private
bool HcalDetDiagLaserMonitor::Overwrite
private
std::string HcalDetDiagLaserMonitor::prefixME_
private

Definition at line 315 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and HcalDetDiagLaserMonitor().

EtaPhiHists* HcalDetDiagLaserMonitor::ProblemCellsByDepth_energy
private

Definition at line 357 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillProblems().

EtaPhiHists* HcalDetDiagLaserMonitor::ProblemCellsByDepth_energy_val
private

Definition at line 361 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillProblems().

EtaPhiHists* HcalDetDiagLaserMonitor::ProblemCellsByDepth_timing
private

Definition at line 356 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillProblems().

EtaPhiHists* HcalDetDiagLaserMonitor::ProblemCellsByDepth_timing_val
private

Definition at line 360 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillProblems().

std::vector<std::string> HcalDetDiagLaserMonitor::problemnames_
private

Definition at line 358 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun().

MonitorElement* HcalDetDiagLaserMonitor::Raddam[56]
private

Definition at line 353 of file HcalDetDiagLaserMonitor.cc.

Referenced by analyze(), and beginRun().

bool HcalDetDiagLaserMonitor::RaddamRun
private

Definition at line 308 of file HcalDetDiagLaserMonitor.cc.

Referenced by analyze(), endRun(), and HcalDetDiagLaserMonitor().

double HcalDetDiagLaserMonitor::RaddamThreshold1
private

Definition at line 302 of file HcalDetDiagLaserMonitor.cc.

Referenced by analyze(), and HcalDetDiagLaserMonitor().

double HcalDetDiagLaserMonitor::RaddamThreshold2
private

Definition at line 302 of file HcalDetDiagLaserMonitor.cc.

Referenced by analyze(), and HcalDetDiagLaserMonitor().

edm::InputTag HcalDetDiagLaserMonitor::rawDataLabel_
private

Definition at line 290 of file HcalDetDiagLaserMonitor.cc.

Referenced by analyze(), and HcalDetDiagLaserMonitor().

MonitorElement* HcalDetDiagLaserMonitor::refEnergy2Dhbhehf
private

Definition at line 345 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement* HcalDetDiagLaserMonitor::refEnergy2Dho
private

Definition at line 346 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

std::string HcalDetDiagLaserMonitor::ReferenceData
private

Definition at line 310 of file HcalDetDiagLaserMonitor.cc.

Referenced by HcalDetDiagLaserMonitor(), and LoadReference().

std::string HcalDetDiagLaserMonitor::ReferenceRun
private

Definition at line 311 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and LoadReference().

MonitorElement* HcalDetDiagLaserMonitor::RefRun_
private

Definition at line 325 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun().

MonitorElement* HcalDetDiagLaserMonitor::refTime2Dhbhehf
private

Definition at line 343 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement* HcalDetDiagLaserMonitor::refTime2Dho
private

Definition at line 344 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

int HcalDetDiagLaserMonitor::run_number
private
TH1F* HcalDetDiagLaserMonitor::S1[56]
private

Definition at line 354 of file HcalDetDiagLaserMonitor.cc.

Referenced by SaveRaddamData().

TH1F * HcalDetDiagLaserMonitor::S2[56]
private

Definition at line 354 of file HcalDetDiagLaserMonitor.cc.

Referenced by analyze(), and SaveRaddamData().

MonitorElement* HcalDetDiagLaserMonitor::Time2Dhbhehf
private

Definition at line 339 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

MonitorElement* HcalDetDiagLaserMonitor::Time2Dho
private

Definition at line 340 of file HcalDetDiagLaserMonitor.cc.

Referenced by beginRun(), and fillHistos().

std::string HcalDetDiagLaserMonitor::XmlFilePath
private