CMS 3D CMS Logo

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

#include <Analyzer_minbias.h>

Inheritance diagram for cms::Analyzer_minbias:
edm::one::EDAnalyzer< edm::one::WatchRuns, edm::one::SharedResources > edm::one::EDAnalyzerBase edm::EDConsumerBase

Public Member Functions

void analyze (edm::Event const &, edm::EventSetup const &) override
 
 Analyzer_minbias (const edm::ParameterSet &)
 
void beginJob () override
 
void beginRun (edm::Run const &, edm::EventSetup const &) override
 
void endJob () override
 
void endRun (edm::Run const &, edm::EventSetup const &) override
 
 ~Analyzer_minbias () override
 
- Public Member Functions inherited from edm::one::EDAnalyzer< edm::one::WatchRuns, edm::one::SharedResources >
 EDAnalyzer ()=default
 
 EDAnalyzer (const EDAnalyzer &)=delete
 
SerialTaskQueueglobalLuminosityBlocksQueue () final
 
SerialTaskQueueglobalRunsQueue () final
 
const EDAnalyzeroperator= (const EDAnalyzer &)=delete
 
bool wantsGlobalLuminosityBlocks () const final
 
bool wantsGlobalRuns () const final
 
bool wantsInputProcessBlocks () const final
 
bool wantsProcessBlocks () const final
 
- Public Member Functions inherited from edm::one::EDAnalyzerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzerBase ()
 
ModuleDescription const & moduleDescription () const
 
bool wantsStreamLuminosityBlocks () const
 
bool wantsStreamRuns () const
 
 ~EDAnalyzerBase () override
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
void convertCurrentProcessAlias (std::string const &processName)
 Convert "@currentProcess" in InputTag process names to the actual current process name. More...
 
 EDConsumerBase ()
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
 EDConsumerBase (EDConsumerBase &&)=default
 
ESProxyIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
std::vector< ESProxyIndex > const & esGetTokenIndicesVector (edm::Transition iTrans) const
 
std::vector< ESRecordIndex >
const & 
esGetTokenRecordIndicesVector (edm::Transition iTrans) const
 
ProductResolverIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
std::vector
< ProductResolverIndexAndSkipBit >
const & 
itemsToGetFrom (BranchType iType) const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesWhoseProductsAreConsumed (std::array< std::vector< ModuleDescription const * > *, NumBranchTypes > &modulesAll, std::vector< ModuleProcessName > &modulesInPreviousProcesses, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
bool registeredToConsume (ProductResolverIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
void selectInputProcessBlocks (ProductRegistry const &productRegistry, ProcessBlockHelperBase const &processBlockHelperBase)
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProxyIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Private Attributes

int depth
 
float eta
 
std::string fOutputFileName
 
edm::Service< TFileServicefs
 
TH1F * hbheNoiseE
 
TH1F * hbheSignalE
 
std::string hcalfile_
 
TH1F * hCalo1 [73][43]
 
TH1F * hCalo1mom2 [73][43]
 
TH1F * hCalo2 [73][43]
 
TH1F * hCalo2mom2 [73][43]
 
TH1F * hfNoiseE
 
TH1F * hfSignalE
 
TH2F * hHBHEsize_vs_run
 
TH2F * hHFsize_vs_run
 
TFile * hOutputFile
 
int ieta
 
int iphi
 
double meannoise_min [73][43]
 
double meannoise_pl [73][43]
 
float mom0_Diff
 
float mom0_MB
 
float mom0_Noise
 
float mom1_Diff
 
float mom1_MB
 
float mom1_Noise
 
float mom2_Diff
 
float mom2_MB
 
float mom2_Noise
 
float mom3_Diff
 
float mom3_MB
 
float mom3_Noise
 
float mom4_Diff
 
float mom4_MB
 
float mom4_Noise
 
int mydet
 
std::ofstream * myout_hcal
 
int mysubd
 
TTree * myTree
 
double nevent
 
int nevent_run
 
double noise_min [73][43]
 
double noise_pl [73][43]
 
float occup
 
float phi
 
double theDFFillDetMapMin0 [5][5][73][43]
 
double theDFFillDetMapMin1 [5][5][73][43]
 
double theDFFillDetMapMin2 [5][5][73][43]
 
double theDFFillDetMapPl0 [5][5][73][43]
 
double theDFFillDetMapPl1 [5][5][73][43]
 
double theDFFillDetMapPl2 [5][5][73][43]
 
double theMBFillDetMapMin0 [5][5][73][43]
 
double theMBFillDetMapMin1 [5][5][73][43]
 
double theMBFillDetMapMin2 [5][5][73][43]
 
double theMBFillDetMapMin4 [5][5][73][43]
 
double theMBFillDetMapPl0 [5][5][73][43]
 
double theMBFillDetMapPl1 [5][5][73][43]
 
double theMBFillDetMapPl2 [5][5][73][43]
 
double theMBFillDetMapPl4 [5][5][73][43]
 
double theNSFillDetMapMin0 [5][5][73][43]
 
double theNSFillDetMapMin1 [5][5][73][43]
 
double theNSFillDetMapMin2 [5][5][73][43]
 
double theNSFillDetMapMin4 [5][5][73][43]
 
double theNSFillDetMapPl0 [5][5][73][43]
 
double theNSFillDetMapPl1 [5][5][73][43]
 
double theNSFillDetMapPl2 [5][5][73][43]
 
double theNSFillDetMapPl4 [5][5][73][43]
 
bool theRecalib
 
edm::EDGetTokenT
< FEDRawDataCollection
tok_data_
 
edm::EDGetTokenT
< L1GlobalTriggerReadoutRecord
tok_gtRec_
 
edm::EDGetTokenT
< HBHERecHitCollection
tok_hbhe_
 
edm::EDGetTokenT
< HBHERecHitCollection
tok_hbheNoise_
 
edm::EDGetTokenT
< HBHERecHitCollection
tok_hbheNorm_
 
edm::EDGetTokenT
< HFRecHitCollection
tok_hf_
 
edm::EDGetTokenT
< HFRecHitCollection
tok_hfNoise_
 
edm::EDGetTokenT
< HORecHitCollection
tok_ho_
 
edm::EDGetTokenT
< HORecHitCollection
tok_hoNoise_
 
edm::ESGetToken
< L1GtTriggerMenu,
L1GtTriggerMenuRcd
tok_l1gt_
 
edm::ESGetToken< HcalRespCorrs,
HcalRespCorrsRcd
tok_respCorr_
 

Additional Inherited Members

- Public Types inherited from edm::one::EDAnalyzerBase
typedef EDAnalyzerBase ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::one::EDAnalyzerBase
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
template<BranchType B = InEvent>
EDConsumerBaseAdaptor< B > consumes (edm::InputTag tag) noexcept
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes ()
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
template<Transition Tr = Transition::Event>
constexpr auto esConsumes () noexcept
 
template<Transition Tr = Transition::Event>
auto esConsumes (ESInputTag tag) noexcept
 
template<Transition Tr = Transition::Event>
ESGetTokenGeneric esConsumes (eventsetup::EventSetupRecordKey const &iRecord, eventsetup::DataKey const &iKey)
 Used with EventSetupRecord::doGet. More...
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
void resetItemsToGetFrom (BranchType iType)
 

Detailed Description

Definition at line 62 of file Analyzer_minbias.h.

Constructor & Destructor Documentation

cms::Analyzer_minbias::Analyzer_minbias ( const edm::ParameterSet iConfig)
explicit

Definition at line 41 of file Analyzer_minbias.cc.

References fOutputFileName, edm::ParameterSet::getParameter(), edm::ParameterSet::getUntrackedParameter(), mps_fire::i, HLT_FULL_cff::InputTag, dqmiolumiharvest::j, TFileService::kSharedResource, noise_min, noise_pl, AlCaHLTBitMon_QueryRunRegistry::string, theRecalib, tok_data_, tok_gtRec_, tok_hbhe_, tok_hbheNoise_, tok_hbheNorm_, tok_hf_, tok_hfNoise_, tok_ho_, tok_hoNoise_, tok_l1gt_, and tok_respCorr_.

41  {
42  usesResource(TFileService::kSharedResource);
43  // get name of output file with histogramms
44  fOutputFileName = iConfig.getUntrackedParameter<std::string>("HistOutFile");
45  // get names of modules, producing object collections
46 
47  tok_hbhe_ = consumes<HBHERecHitCollection>(iConfig.getParameter<edm::InputTag>("hbheInputMB"));
48  tok_ho_ = consumes<HORecHitCollection>(iConfig.getParameter<edm::InputTag>("hoInputMB"));
49  tok_hf_ = consumes<HFRecHitCollection>(iConfig.getParameter<edm::InputTag>("hfInputMB"));
50  tok_data_ = consumes<FEDRawDataCollection>(edm::InputTag(iConfig.getParameter<std::string>("InputLabel")));
51 
52  tok_hbheNoise_ = consumes<HBHERecHitCollection>(iConfig.getParameter<edm::InputTag>("hbheInputNoise"));
53  tok_hoNoise_ = consumes<HORecHitCollection>(iConfig.getParameter<edm::InputTag>("hoInputNoise"));
54  tok_hfNoise_ = consumes<HFRecHitCollection>(iConfig.getParameter<edm::InputTag>("hfInputNoise"));
55 
56  // this was hardcodded..
57  tok_gtRec_ = consumes<L1GlobalTriggerReadoutRecord>(edm::InputTag("gtDigisAlCaMB"));
58  tok_hbheNorm_ = consumes<HBHERecHitCollection>(edm::InputTag("hbhereco"));
59 
60  tok_respCorr_ = esConsumes<HcalRespCorrs, HcalRespCorrsRcd>();
61  tok_l1gt_ = esConsumes<L1GtTriggerMenu, L1GtTriggerMenuRcd>();
62 
63  theRecalib = iConfig.getParameter<bool>("Recalib");
64 
65  //
66  for (int i = 0; i < 73; i++) {
67  for (int j = 0; j < 43; j++) {
68  noise_min[i][j] = 0.;
69  noise_pl[i][j] = 0.;
70  }
71  }
72  }
static const std::string kSharedResource
Definition: TFileService.h:76
T getUntrackedParameter(std::string const &, T const &) const
edm::EDGetTokenT< HORecHitCollection > tok_hoNoise_
edm::EDGetTokenT< HFRecHitCollection > tok_hf_
edm::EDGetTokenT< L1GlobalTriggerReadoutRecord > tok_gtRec_
edm::EDGetTokenT< HBHERecHitCollection > tok_hbheNoise_
double noise_min[73][43]
edm::EDGetTokenT< HFRecHitCollection > tok_hfNoise_
edm::ESGetToken< HcalRespCorrs, HcalRespCorrsRcd > tok_respCorr_
edm::EDGetTokenT< HBHERecHitCollection > tok_hbhe_
edm::EDGetTokenT< HBHERecHitCollection > tok_hbheNorm_
edm::EDGetTokenT< FEDRawDataCollection > tok_data_
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
edm::EDGetTokenT< HORecHitCollection > tok_ho_
edm::ESGetToken< L1GtTriggerMenu, L1GtTriggerMenuRcd > tok_l1gt_
cms::Analyzer_minbias::~Analyzer_minbias ( )
override

Definition at line 74 of file Analyzer_minbias.cc.

74  {
75  // do anything here that needs to be done at desctruction time
76  // (e.g. close files, deallocate resources etc.)
77  }

Member Function Documentation

void cms::Analyzer_minbias::analyze ( edm::Event const &  iEvent,
edm::EventSetup const &  iSetup 
)
overridevirtual

Implements edm::one::EDAnalyzerBase.

Definition at line 300 of file Analyzer_minbias.cc.

References funct::abs(), edm::SortedCollection< T, SORT >::begin(), HcalDetId::depth(), edm::SortedCollection< T, SORT >::end(), CaloRecHit::energy(), HcalObjRepresent::Fill(), edm::Event::getAllStableProvenance(), edm::Event::getByToken(), edm::EventSetup::getData(), HcalRespCorr::getValue(), HcalCondObjectContainer< Item >::getValues(), hbheNoiseE, hbheSignalE, hCalo1, hCalo1mom2, hCalo2, hCalo2mom2, hfNoiseE, hfSignalE, hHBHEsize_vs_run, hHFsize_vs_run, mps_fire::i, HcalDetId::ieta(), HcalDetId::iphi(), edm::HandleBase::isValid(), dqmiolumiharvest::j, isotrackApplyRegressor::k, cmsLHEtoEOSManager::l, nevent, nevent_run, funct::pow(), edm::Handle< T >::product(), DetId::rawId(), edm::Event::run(), edm::SortedCollection< T, SORT >::size(), DetId::subdetId(), theDFFillDetMapMin1, theDFFillDetMapMin2, theDFFillDetMapPl1, theDFFillDetMapPl2, theMBFillDetMapMin0, theMBFillDetMapMin1, theMBFillDetMapMin2, theMBFillDetMapMin4, theMBFillDetMapPl0, theMBFillDetMapPl1, theMBFillDetMapPl2, theMBFillDetMapPl4, theNSFillDetMapMin0, theNSFillDetMapMin1, theNSFillDetMapMin2, theNSFillDetMapMin4, theNSFillDetMapPl0, theNSFillDetMapPl1, theNSFillDetMapPl2, theNSFillDetMapPl4, theRecalib, tok_hbhe_, tok_hbheNoise_, tok_hbheNorm_, tok_hf_, tok_hfNoise_, and tok_respCorr_.

300  {
301  edm::LogVerbatim("AnalyzerMB") << " Start Analyzer_minbias::analyze " << nevent;
302  nevent++;
303  nevent_run++;
304 
305  float rnnum = (float)iEvent.run();
306 
307  std::vector<edm::StableProvenance const*> theProvenance;
308  iEvent.getAllStableProvenance(theProvenance);
309 
310  for (auto const& provenance : theProvenance) {
311  edm::LogVerbatim("AnalyzerMB") << " Print all process/modulelabel/product names " << provenance->processName()
312  << " , " << provenance->moduleLabel() << " , "
313  << provenance->productInstanceName();
314  }
315  const HcalRespCorrs* myRecalib = nullptr;
316  if (theRecalib) {
317  myRecalib = &iSetup.getData(tok_respCorr_);
318  } // theRecalib
319 
320  // Noise part for HB HE
321 
322  double tmpNSFillDetMapPl1[5][5][73][43];
323  double tmpNSFillDetMapMin1[5][5][73][43];
324 
325  for (int i = 0; i < 5; i++) {
326  for (int j = 0; j < 5; j++) {
327  for (int k = 0; k < 73; k++) {
328  for (int l = 0; l < 43; l++) {
329  tmpNSFillDetMapPl1[i][j][k][l] = 0.;
330  tmpNSFillDetMapMin1[i][j][k][l] = 0.;
331  }
332  }
333  }
334  }
335 
337  iEvent.getByToken(tok_hbheNorm_, hbheNormal);
338  if (!hbheNormal.isValid()) {
339  edm::LogWarning("AnalyzerMB") << " hbheNormal failed ";
340  } else {
341  edm::LogVerbatim("AnalyzerMB") << " The size of the normal collection " << hbheNormal->size();
342  }
343 
345  iEvent.getByToken(tok_hbheNoise_, hbheNS);
346 
347  if (!hbheNS.isValid()) {
348  edm::LogWarning("AnalyzerMB") << "HcalCalibAlgos: Error! can't get hbhe"
349  << " product! No HBHE MS ";
350  return;
351  }
352 
353  const HBHERecHitCollection HithbheNS = *(hbheNS.product());
354  edm::LogVerbatim("AnalyzerMB") << " HBHE NS size of collection " << HithbheNS.size();
355  hHBHEsize_vs_run->Fill(rnnum, (float)HithbheNS.size());
356 
357  if (HithbheNS.size() != 5184) {
358  edm::LogWarning("AnalyzerMB") << " HBHE problem " << rnnum << " " << HithbheNS.size();
359  }
361  iEvent.getByToken(tok_hbhe_, hbheMB);
362 
363  if (!hbheMB.isValid()) {
364  edm::LogWarning("AnalyzerMB") << "HcalCalibAlgos: Error! can't get hbhe"
365  << " product! No HBHE MB";
366  }
367 
368  const HBHERecHitCollection HithbheMB = *(hbheMB.product());
369  edm::LogVerbatim("AnalyzerMB") << " HBHE MB size of collection " << HithbheMB.size();
370  if (HithbheMB.size() != 5184) {
371  edm::LogWarning("AnalyzerMB") << " HBHE problem " << rnnum << " " << HithbheMB.size();
372  }
373 
375  iEvent.getByToken(tok_hfNoise_, hfNS);
376 
377  if (!hfNS.isValid()) {
378  edm::LogWarning("AnalyzerMB") << "HcalCalibAlgos: Error! can't get hf"
379  << " product! No HF NS ";
380  }
381 
382  const HFRecHitCollection HithfNS = *(hfNS.product());
383  edm::LogVerbatim("AnalyzerMB") << " HFE NS size of collection " << HithfNS.size();
384  hHFsize_vs_run->Fill(rnnum, (float)HithfNS.size());
385  if (HithfNS.size() != 1728) {
386  edm::LogWarning("AnalyzerMB") << " HF problem " << rnnum << " " << HithfNS.size();
387  }
388 
390  iEvent.getByToken(tok_hf_, hfMB);
391 
392  if (!hfMB.isValid()) {
393  edm::LogWarning("AnalyzerMB") << "HcalCalibAlgos: Error! can't get hf"
394  << " product! No HF MB";
395  }
396 
397  const HFRecHitCollection HithfMB = *(hfMB.product());
398  edm::LogVerbatim("AnalyzerMB") << " HF MB size of collection " << HithfMB.size();
399  if (HithfMB.size() != 1728) {
400  edm::LogWarning("AnalyzerMB") << " HF problem " << rnnum << " " << HithfMB.size();
401  }
402 
403  for (HBHERecHitCollection::const_iterator hbheItr = HithbheNS.begin(); hbheItr != HithbheNS.end(); hbheItr++) {
404  // Recalibration of energy
405  float icalconst = 1.;
406  DetId mydetid = hbheItr->id().rawId();
407  if (theRecalib)
408  icalconst = myRecalib->getValues(mydetid)->getValue();
409 
410  HBHERecHit aHit(hbheItr->id(), hbheItr->energy() * icalconst, hbheItr->time());
411 
412  double energyhit = aHit.energy();
413 
414  DetId id = (*hbheItr).detid();
415  HcalDetId hid = HcalDetId(id);
416 
417  int mysu = ((hid).rawId() >> 25) & 0x7;
418  if (hid.ieta() > 0) {
419  theNSFillDetMapPl0[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
420  theNSFillDetMapPl0[mysu][hid.depth()][hid.iphi()][hid.ieta()] + 1.;
421  theNSFillDetMapPl1[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
422  theNSFillDetMapPl1[mysu][hid.depth()][hid.iphi()][hid.ieta()] + energyhit;
423  theNSFillDetMapPl2[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
424  theNSFillDetMapPl2[mysu][hid.depth()][hid.iphi()][hid.ieta()] + pow(energyhit, 2);
425  theNSFillDetMapPl4[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
426  theNSFillDetMapPl4[mysu][hid.depth()][hid.iphi()][hid.ieta()] + pow(energyhit, 4);
427 
428  tmpNSFillDetMapPl1[mysu][hid.depth()][hid.iphi()][hid.ieta()] = energyhit;
429 
430  } else {
431  theNSFillDetMapMin0[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] =
432  theNSFillDetMapMin0[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] + 1.;
433  theNSFillDetMapMin1[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] =
434  theNSFillDetMapMin1[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] + energyhit;
435  theNSFillDetMapMin2[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] =
436  theNSFillDetMapMin2[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] + pow(energyhit, 2);
437  theNSFillDetMapMin4[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] =
438  theNSFillDetMapMin4[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] + pow(energyhit, 4);
439 
440  tmpNSFillDetMapMin1[mysu][hid.depth()][hid.iphi()][hid.ieta()] = energyhit;
441  }
442 
443  if (hid.depth() == 1) {
444  hbheNoiseE->Fill(energyhit);
445 
446  if (energyhit < -2.)
447  edm::LogVerbatim("AnalyzerMB") << " Run " << rnnum << " ieta,iphi " << hid.ieta() << " " << hid.iphi()
448  << energyhit;
449 
450  } // depth=1
451 
452  } // HBHE_NS
453 
454  // Signal part for HB HE
455 
456  for (HBHERecHitCollection::const_iterator hbheItr = HithbheMB.begin(); hbheItr != HithbheMB.end(); hbheItr++) {
457  // Recalibration of energy
458  float icalconst = 1.;
459  DetId mydetid = hbheItr->id().rawId();
460  if (theRecalib)
461  icalconst = myRecalib->getValues(mydetid)->getValue();
462 
463  HBHERecHit aHit(hbheItr->id(), hbheItr->energy() * icalconst, hbheItr->time());
464 
465  double energyhit = aHit.energy();
466 
467  DetId id = (*hbheItr).detid();
468  HcalDetId hid = HcalDetId(id);
469 
470  int mysu = ((hid).rawId() >> 25) & 0x7;
471  if (hid.ieta() > 0) {
472  theMBFillDetMapPl0[mysu][hid.depth()][hid.iphi()][hid.ieta()] += 1.;
473  theMBFillDetMapPl1[mysu][hid.depth()][hid.iphi()][hid.ieta()] += energyhit;
474  theMBFillDetMapPl2[mysu][hid.depth()][hid.iphi()][hid.ieta()] += pow(energyhit, 2);
475  theMBFillDetMapPl4[mysu][hid.depth()][hid.iphi()][hid.ieta()] += pow(energyhit, 4);
476  float mydiff = energyhit - tmpNSFillDetMapPl1[mysu][hid.depth()][hid.iphi()][hid.ieta()];
477 
478  theDFFillDetMapPl1[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
479  theDFFillDetMapPl1[mysu][hid.depth()][hid.iphi()][hid.ieta()] + mydiff;
480  theDFFillDetMapPl2[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
481  theDFFillDetMapPl2[mysu][hid.depth()][hid.iphi()][hid.ieta()] + pow(mydiff, 2);
482  } else {
483  theMBFillDetMapMin0[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] =
484  theMBFillDetMapMin0[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] + 1.;
485  theMBFillDetMapMin1[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] =
486  theMBFillDetMapMin1[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] + energyhit;
487  theMBFillDetMapMin2[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] =
488  theMBFillDetMapMin2[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] + pow(energyhit, 2);
489  theMBFillDetMapMin4[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] =
490  theMBFillDetMapMin4[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] + pow(energyhit, 4);
491 
492  float mydiff = energyhit - tmpNSFillDetMapMin1[mysu][hid.depth()][hid.iphi()][hid.ieta()];
493  theDFFillDetMapMin1[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
494  theDFFillDetMapMin1[mysu][hid.depth()][hid.iphi()][hid.ieta()] + mydiff;
495  theDFFillDetMapMin2[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
496  theDFFillDetMapMin2[mysu][hid.depth()][hid.iphi()][hid.ieta()] + pow(mydiff, 2);
497  }
498 
499  if (hid.depth() == 1) {
500  hbheSignalE->Fill(energyhit);
501 
502  if (hid.ieta() > 0) {
503  hCalo1[hid.iphi()][hid.ieta()]->Fill(energyhit);
504  hCalo1mom2[hid.iphi()][hid.ieta()]->Fill(pow(energyhit, 2));
505  } else {
506  hCalo2[hid.iphi()][abs(hid.ieta())]->Fill(energyhit);
507  hCalo2mom2[hid.iphi()][abs(hid.ieta())]->Fill(pow(energyhit, 2));
508  } // eta><0
509 
510  } // depth=1
511 
512  } // HBHE_MB
513 
514  // HF
515 
516  for (HFRecHitCollection::const_iterator hbheItr = HithfNS.begin(); hbheItr != HithfNS.end(); hbheItr++) {
517  // Recalibration of energy
518  float icalconst = 1.;
519  DetId mydetid = hbheItr->id().rawId();
520  if (theRecalib)
521  icalconst = myRecalib->getValues(mydetid)->getValue();
522 
523  HFRecHit aHit(hbheItr->id(), hbheItr->energy() * icalconst, hbheItr->time());
524 
525  double energyhit = aHit.energy();
526  //
527  // Remove PMT hits
528  //
529  DetId id = (*hbheItr).detid();
530  HcalDetId hid = HcalDetId(id);
531 
532  if (fabs(energyhit) > 40.)
533  continue;
534 
535  int mysu = hid.subdetId();
536  if (hid.ieta() > 0) {
537  theNSFillDetMapPl0[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
538  theNSFillDetMapPl0[mysu][hid.depth()][hid.iphi()][hid.ieta()] + 1.;
539  theNSFillDetMapPl1[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
540  theNSFillDetMapPl1[mysu][hid.depth()][hid.iphi()][hid.ieta()] + energyhit;
541  theNSFillDetMapPl2[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
542  theNSFillDetMapPl2[mysu][hid.depth()][hid.iphi()][hid.ieta()] + pow(energyhit, 2);
543  theNSFillDetMapPl4[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
544  theNSFillDetMapPl4[mysu][hid.depth()][hid.iphi()][hid.ieta()] + pow(energyhit, 4);
545 
546  tmpNSFillDetMapPl1[mysu][hid.depth()][hid.iphi()][hid.ieta()] = energyhit;
547 
548  } else {
549  theNSFillDetMapMin0[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] =
550  theNSFillDetMapMin0[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] + 1.;
551  theNSFillDetMapMin1[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] =
552  theNSFillDetMapMin1[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] + energyhit;
553  theNSFillDetMapMin2[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] =
554  theNSFillDetMapMin2[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] + pow(energyhit, 2);
555  theNSFillDetMapMin4[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] =
556  theNSFillDetMapMin4[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] + pow(energyhit, 4);
557 
558  tmpNSFillDetMapMin1[mysu][hid.depth()][hid.iphi()][hid.ieta()] = energyhit;
559  }
560 
561  if (hid.depth() == 1) {
562  hfNoiseE->Fill(energyhit);
563 
564  } // depth=1
565 
566  } // HBHE_NS
567 
568  // Signal part for HB HE
569 
570  for (HFRecHitCollection::const_iterator hbheItr = HithfMB.begin(); hbheItr != HithfMB.end(); hbheItr++) {
571  // Recalibration of energy
572  float icalconst = 1.;
573  DetId mydetid = hbheItr->id().rawId();
574  if (theRecalib)
575  icalconst = myRecalib->getValues(mydetid)->getValue();
576 
577  HFRecHit aHit(hbheItr->id(), hbheItr->energy() * icalconst, hbheItr->time());
578 
579  double energyhit = aHit.energy();
580  //
581  // Remove PMT hits
582  //
583  if (fabs(energyhit) > 40.)
584  continue;
585 
586  DetId id = (*hbheItr).detid();
587  HcalDetId hid = HcalDetId(id);
588 
589  int mysu = ((hid).rawId() >> 25) & 0x7;
590  if (hid.ieta() > 0) {
591  theMBFillDetMapPl0[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
592  theMBFillDetMapPl0[mysu][hid.depth()][hid.iphi()][hid.ieta()] + 1.;
593  theMBFillDetMapPl1[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
594  theMBFillDetMapPl1[mysu][hid.depth()][hid.iphi()][hid.ieta()] + energyhit;
595  theMBFillDetMapPl2[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
596  theMBFillDetMapPl2[mysu][hid.depth()][hid.iphi()][hid.ieta()] + pow(energyhit, 2);
597  theMBFillDetMapPl4[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
598  theMBFillDetMapPl4[mysu][hid.depth()][hid.iphi()][hid.ieta()] + pow(energyhit, 4);
599 
600  theDFFillDetMapPl1[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
601  theDFFillDetMapPl1[mysu][hid.depth()][hid.iphi()][hid.ieta()] + energyhit -
602  tmpNSFillDetMapPl1[mysu][hid.depth()][hid.iphi()][hid.ieta()];
603  theDFFillDetMapPl2[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
604  theDFFillDetMapPl2[mysu][hid.depth()][hid.iphi()][hid.ieta()] +
605  pow((energyhit - tmpNSFillDetMapPl1[mysu][hid.depth()][hid.iphi()][hid.ieta()]), 2);
606  } else {
607  theMBFillDetMapMin0[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] =
608  theMBFillDetMapMin0[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] + 1.;
609  theMBFillDetMapMin1[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] =
610  theMBFillDetMapMin1[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] + energyhit;
611  theMBFillDetMapMin2[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] =
612  theMBFillDetMapMin2[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] + pow(energyhit, 2);
613  theMBFillDetMapMin4[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] =
614  theMBFillDetMapMin4[mysu][hid.depth()][hid.iphi()][abs(hid.ieta())] + pow(energyhit, 4);
615 
616  theDFFillDetMapMin1[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
617  theDFFillDetMapMin1[mysu][hid.depth()][hid.iphi()][hid.ieta()] + energyhit -
618  tmpNSFillDetMapMin1[mysu][hid.depth()][hid.iphi()][hid.ieta()];
619  theDFFillDetMapMin2[mysu][hid.depth()][hid.iphi()][hid.ieta()] =
620  theDFFillDetMapMin2[mysu][hid.depth()][hid.iphi()][hid.ieta()] +
621  pow((energyhit - tmpNSFillDetMapMin1[mysu][hid.depth()][hid.iphi()][hid.ieta()]), 2);
622  }
623 
624  if (hid.depth() == 1) {
625  hfSignalE->Fill(energyhit);
626 
627  if (hid.ieta() > 0) {
628  hCalo1[hid.iphi()][hid.ieta()]->Fill(energyhit);
629  hCalo1mom2[hid.iphi()][hid.ieta()]->Fill(pow(energyhit, 2));
630  } else {
631  hCalo2[hid.iphi()][abs(hid.ieta())]->Fill(energyhit);
632  hCalo2mom2[hid.iphi()][abs(hid.ieta())]->Fill(pow(energyhit, 2));
633  } // eta><0
634 
635  } // depth=1
636 
637  } // HF_MB
638 
639  edm::LogVerbatim("AnalyzerMB") << " Event is finished ";
640  }
constexpr float energy() const
Definition: CaloRecHit.h:29
double theMBFillDetMapMin0[5][5][73][43]
double theMBFillDetMapMin2[5][5][73][43]
Log< level::Info, true > LogVerbatim
double theDFFillDetMapPl2[5][5][73][43]
double theMBFillDetMapMin1[5][5][73][43]
double theNSFillDetMapPl4[5][5][73][43]
double theNSFillDetMapPl0[5][5][73][43]
double theNSFillDetMapMin0[5][5][73][43]
double theMBFillDetMapPl0[5][5][73][43]
TH1F * hCalo2mom2[73][43]
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:57
std::vector< T >::const_iterator const_iterator
double theDFFillDetMapPl1[5][5][73][43]
edm::EDGetTokenT< HFRecHitCollection > tok_hf_
const Item * getValues(DetId fId, bool throwOnFail=true) const
edm::EDGetTokenT< HBHERecHitCollection > tok_hbheNoise_
double theNSFillDetMapPl2[5][5][73][43]
double theDFFillDetMapMin2[5][5][73][43]
TH1F * hCalo1mom2[73][43]
edm::EDGetTokenT< HFRecHitCollection > tok_hfNoise_
double theNSFillDetMapPl1[5][5][73][43]
double theMBFillDetMapPl1[5][5][73][43]
int iEvent
Definition: GenABIO.cc:224
constexpr int iphi() const
get the cell iphi
Definition: HcalDetId.h:157
edm::ESGetToken< HcalRespCorrs, HcalRespCorrsRcd > tok_respCorr_
void Fill(HcalDetId &id, double val, std::vector< TH2F > &depth)
edm::EDGetTokenT< HBHERecHitCollection > tok_hbhe_
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:48
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
constexpr int ieta() const
get the cell ieta
Definition: HcalDetId.h:155
double theMBFillDetMapPl4[5][5][73][43]
double theNSFillDetMapMin1[5][5][73][43]
double theNSFillDetMapMin4[5][5][73][43]
bool isValid() const
Definition: HandleBase.h:70
double theMBFillDetMapPl2[5][5][73][43]
edm::EDGetTokenT< HBHERecHitCollection > tok_hbheNorm_
const_iterator end() const
Definition: DetId.h:17
T const * product() const
Definition: Handle.h:70
double theMBFillDetMapMin4[5][5][73][43]
float getValue() const
Definition: HcalRespCorr.h:19
size_type size() const
constexpr int depth() const
get the tower depth
Definition: HcalDetId.h:164
Log< level::Warning, false > LogWarning
double theNSFillDetMapMin2[5][5][73][43]
double theDFFillDetMapMin1[5][5][73][43]
Power< A, B >::type pow(const A &a, const B &b)
Definition: Power.h:29
const_iterator begin() const
void cms::Analyzer_minbias::beginJob ( void  )
overridevirtual

Reimplemented from edm::one::EDAnalyzerBase.

Definition at line 84 of file Analyzer_minbias.cc.

References depth, eta, fs, hbheNoiseE, hbheSignalE, hCalo1, hCalo1mom2, hCalo2, hCalo2mom2, hfNoiseE, hfSignalE, hHBHEsize_vs_run, hHFsize_vs_run, mps_fire::i, ieta, iphi, dqmiolumiharvest::j, isotrackApplyRegressor::k, cmsLHEtoEOSManager::l, TFileService::make(), meannoise_min, meannoise_pl, mom0_Diff, mom0_MB, mom0_Noise, mom1_Diff, mom1_MB, mom1_Noise, mom2_Diff, mom2_MB, mom2_Noise, mom4_MB, mom4_Noise, mydet, myout_hcal, mysubd, myTree, nevent, occup, phi, AlCaHLTBitMon_QueryRunRegistry::string, theDFFillDetMapMin0, theDFFillDetMapMin1, theDFFillDetMapMin2, theDFFillDetMapPl0, theDFFillDetMapPl1, theDFFillDetMapPl2, theMBFillDetMapMin0, theMBFillDetMapMin1, theMBFillDetMapMin2, theMBFillDetMapMin4, theMBFillDetMapPl0, theMBFillDetMapPl1, theMBFillDetMapPl2, theMBFillDetMapPl4, theNSFillDetMapMin0, theNSFillDetMapMin1, theNSFillDetMapMin2, theNSFillDetMapMin4, theNSFillDetMapPl0, theNSFillDetMapPl1, theNSFillDetMapPl2, and theNSFillDetMapPl4.

84  {
85  myTree = fs->make<TTree>("RecJet", "RecJet Tree");
86  myTree->Branch("mydet", &mydet, "mydet/I");
87  myTree->Branch("mysubd", &mysubd, "mysubd/I");
88  myTree->Branch("depth", &depth, "depth/I");
89  myTree->Branch("ieta", &ieta, "ieta/I");
90  myTree->Branch("iphi", &iphi, "iphi/I");
91  myTree->Branch("eta", &eta, "eta/F");
92  myTree->Branch("phi", &phi, "phi/F");
93 
94  myTree->Branch("mom0_MB", &mom0_MB, "mom0_MB/F");
95  myTree->Branch("mom1_MB", &mom1_MB, "mom1_MB/F");
96  myTree->Branch("mom2_MB", &mom2_MB, "mom2_MB/F");
97  myTree->Branch("mom4_MB", &mom4_MB, "mom4_MB/F");
98 
99  myTree->Branch("mom0_Noise", &mom0_Noise, "mom0_Noise/F");
100  myTree->Branch("mom1_Noise", &mom1_Noise, "mom1_Noise/F");
101  myTree->Branch("mom2_Noise", &mom2_Noise, "mom2_Noise/F");
102  myTree->Branch("mom4_Noise", &mom4_Noise, "mom4_Noise/F");
103 
104  myTree->Branch("mom0_Diff", &mom0_Diff, "mom0_Diff/F");
105  myTree->Branch("mom1_Diff", &mom1_Diff, "mom1_Diff/F");
106  myTree->Branch("mom2_Diff", &mom2_Diff, "mom2_Diff/F");
107 
108  myTree->Branch("occup", &occup, "occup/F");
109 
110  edm::LogVerbatim("AnalyzerMB") << " Before ordering Histos ";
111 
112  char str0[32];
113  char str1[32];
114 
115  char str10[32];
116  char str11[32];
117 
118  int k = 0;
119  nevent = 0;
120  // Size of collections
121 
123  fs->make<TH2F>("hHBHEsize_vs_run", "hHBHEsize_vs_run", 500, 111500., 112000., 6101, -100.5, 6000.5);
124  hHFsize_vs_run = fs->make<TH2F>("hHFsize_vs_run", "hHFsize_vs_run", 500, 111500., 112000., 6101, -100.5, 6000.5);
125 
126  for (int i = 1; i < 73; i++) {
127  for (int j = 1; j < 43; j++) {
128  meannoise_pl[i][j] = 0.;
129  meannoise_min[i][j] = 0.;
130 
131  k = i * 1000 + j;
132  sprintf(str0, "mpl%d", k);
133  sprintf(str1, "mmin%d", k);
134 
135  sprintf(str10, "vpl%d", k);
136  sprintf(str11, "vmin%d", k);
137  if (j < 30) {
138  // first order moment
139  hCalo1[i][j] = fs->make<TH1F>(str0, "h0", 320, -10., 10.);
140  hCalo2[i][j] = fs->make<TH1F>(str1, "h1", 320, -10., 10.);
141 
142  // second order moment
143  hCalo1mom2[i][j] = fs->make<TH1F>(str10, "h10", 320, 0., 20.);
144  hCalo2mom2[i][j] = fs->make<TH1F>(str11, "h11", 320, 0., 20.);
145  } else {
146  // HF
147  // first order moment
148  if (j < 40) {
149  hCalo1[i][j] = fs->make<TH1F>(str0, "h0", 320, -10., 10.);
150  hCalo2[i][j] = fs->make<TH1F>(str1, "h1", 320, -10., 10.);
151  //
152  // second order moment
153  hCalo1mom2[i][j] = fs->make<TH1F>(str10, "h10", 320, 0., 40.);
154  hCalo2mom2[i][j] = fs->make<TH1F>(str11, "h11", 320, 0., 40.);
155  } else {
156  hCalo1[i][j] = fs->make<TH1F>(str0, "h0", 320, -10., 10.);
157  hCalo2[i][j] = fs->make<TH1F>(str1, "h1", 320, -10., 10.);
158 
159  // second order moment
160  hCalo1mom2[i][j] = fs->make<TH1F>(str10, "h10", 320, 0., 120.);
161  hCalo2mom2[i][j] = fs->make<TH1F>(str11, "h11", 320, 0., 120.);
162  }
163  } // HE/HF boundary
164  } // j
165  } // i
166 
167  hbheNoiseE = fs->make<TH1F>("hbheNoiseE", "hbheNoiseE", 320, -10., 10.);
168  hfNoiseE = fs->make<TH1F>("hfNoiseE", "hfNoiseE", 320, -10., 10.);
169  hbheSignalE = fs->make<TH1F>("hbheSignalE", "hbheSignalE", 320, -10., 10.);
170  hfSignalE = fs->make<TH1F>("hfSignalE", "hfSignalE", 320, -10., 10.);
171 
172  edm::LogVerbatim("AnalyzerMB") << " After ordering Histos ";
173 
174  std::string ccc = "noise_0.dat";
175 
176  myout_hcal = new std::ofstream(ccc.c_str());
177  if (!myout_hcal)
178  edm::LogVerbatim("AnalyzerMB") << " Output file not open!!! ";
179 
180  //
181  for (int i = 0; i < 5; i++) {
182  for (int j = 0; j < 5; j++) {
183  for (int k = 0; k < 73; k++) {
184  for (int l = 0; l < 43; l++) {
185  theMBFillDetMapPl0[i][j][k][l] = 0.;
186  theMBFillDetMapPl1[i][j][k][l] = 0.;
187  theMBFillDetMapPl2[i][j][k][l] = 0.;
188  theMBFillDetMapPl4[i][j][k][l] = 0.;
189 
190  theMBFillDetMapMin0[i][j][k][l] = 0.;
191  theMBFillDetMapMin1[i][j][k][l] = 0.;
192  theMBFillDetMapMin2[i][j][k][l] = 0.;
193  theMBFillDetMapMin4[i][j][k][l] = 0.;
194 
195  theNSFillDetMapPl0[i][j][k][l] = 0.;
196  theNSFillDetMapPl1[i][j][k][l] = 0.;
197  theNSFillDetMapPl2[i][j][k][l] = 0.;
198  theNSFillDetMapPl4[i][j][k][l] = 0.;
199 
200  theNSFillDetMapMin0[i][j][k][l] = 0.;
201  theNSFillDetMapMin1[i][j][k][l] = 0.;
202  theNSFillDetMapMin2[i][j][k][l] = 0.;
203  theNSFillDetMapMin4[i][j][k][l] = 0.;
204 
205  theDFFillDetMapPl0[i][j][k][l] = 0.;
206  theDFFillDetMapPl1[i][j][k][l] = 0.;
207  theDFFillDetMapPl2[i][j][k][l] = 0.;
208  theDFFillDetMapMin0[i][j][k][l] = 0.;
209  theDFFillDetMapMin1[i][j][k][l] = 0.;
210  theDFFillDetMapMin2[i][j][k][l] = 0.;
211  }
212  }
213  }
214  }
215 
216  return;
217  }
double theMBFillDetMapMin0[5][5][73][43]
double theMBFillDetMapMin2[5][5][73][43]
Log< level::Info, true > LogVerbatim
double theDFFillDetMapPl2[5][5][73][43]
double theMBFillDetMapMin1[5][5][73][43]
edm::Service< TFileService > fs
double theNSFillDetMapPl4[5][5][73][43]
double theNSFillDetMapPl0[5][5][73][43]
double theNSFillDetMapMin0[5][5][73][43]
double theMBFillDetMapPl0[5][5][73][43]
TH1F * hCalo2mom2[73][43]
double theDFFillDetMapPl1[5][5][73][43]
std::ofstream * myout_hcal
T * make(const Args &...args) const
make new ROOT object
Definition: TFileService.h:64
double meannoise_pl[73][43]
double theNSFillDetMapPl2[5][5][73][43]
double theDFFillDetMapMin2[5][5][73][43]
TH1F * hCalo1mom2[73][43]
double theNSFillDetMapPl1[5][5][73][43]
double theMBFillDetMapPl1[5][5][73][43]
double theDFFillDetMapPl0[5][5][73][43]
double theMBFillDetMapPl4[5][5][73][43]
double theNSFillDetMapMin1[5][5][73][43]
double theNSFillDetMapMin4[5][5][73][43]
double theDFFillDetMapMin0[5][5][73][43]
double theMBFillDetMapPl2[5][5][73][43]
double theMBFillDetMapMin4[5][5][73][43]
double meannoise_min[73][43]
double theNSFillDetMapMin2[5][5][73][43]
double theDFFillDetMapMin1[5][5][73][43]
void cms::Analyzer_minbias::beginRun ( edm::Run const &  ,
edm::EventSetup const &   
)
override

Definition at line 79 of file Analyzer_minbias.cc.

References nevent_run.

void cms::Analyzer_minbias::endJob ( void  )
overridevirtual

Reimplemented from edm::one::EDAnalyzerBase.

Definition at line 221 of file Analyzer_minbias.cc.

References depth, hCalo1, hCalo1mom2, hCalo2, hCalo2mom2, mps_fire::i, ieta, cuy::ii, iphi, dqmiolumiharvest::j, isotrackApplyRegressor::k, cmsLHEtoEOSManager::l, mom0_Diff, mom0_MB, mom0_Noise, mom1_Diff, mom1_MB, mom1_Noise, mom2_Diff, mom2_MB, mom2_Noise, mom4_MB, mom4_Noise, mysubd, myTree, theDFFillDetMapMin0, theDFFillDetMapMin1, theDFFillDetMapMin2, theDFFillDetMapPl0, theDFFillDetMapPl1, theDFFillDetMapPl2, theMBFillDetMapMin0, theMBFillDetMapMin1, theMBFillDetMapMin2, theMBFillDetMapMin4, theMBFillDetMapPl0, theMBFillDetMapPl1, theMBFillDetMapPl2, theMBFillDetMapPl4, theNSFillDetMapMin0, theNSFillDetMapMin1, theNSFillDetMapMin2, theNSFillDetMapMin4, theNSFillDetMapPl0, theNSFillDetMapPl1, theNSFillDetMapPl2, and theNSFillDetMapPl4.

Referenced by o2olib.O2ORunMgr::executeJob().

221  {
222  int ii = 0;
223 
224  for (int i = 1; i < 5; i++) {
225  for (int j = 1; j < 5; j++) {
226  for (int k = 1; k < 73; k++) {
227  for (int l = 1; l < 43; l++) {
228  if (theMBFillDetMapPl0[i][j][k][l] > 0) {
240 
241  mysubd = i;
242  depth = j;
243  ieta = l;
244  iphi = k;
245  edm::LogVerbatim("AnalyzerMB") << " Result Plus= " << mysubd << " " << ieta << " " << iphi << " mom0 "
246  << mom0_MB << " mom1 " << mom1_MB << " mom2 " << mom2_MB;
247  myTree->Fill();
248  ii++;
249  } // Pl > 0
250 
251  if (theMBFillDetMapMin0[i][j][k][l] > 0) {
254  mom2_MB = theMBFillDetMapMin2[i][j][k][l];
263 
264  mysubd = i;
265  depth = j;
266  ieta = -1 * l;
267  iphi = k;
268  edm::LogVerbatim("AnalyzerMB") << " Result Minus= " << mysubd << " " << ieta << " " << iphi << " mom0 "
269  << mom0_MB << " mom1 " << mom1_MB << " mom2 " << mom2_MB;
270  myTree->Fill();
271  ii++;
272 
273  } // Min>0
274  } // ieta
275  } // iphi
276  } // depth
277  } //subd
278 
279  edm::LogVerbatim("AnalyzerMB") << " Number of cells " << ii;
280 
281  for (int i = 1; i < 73; i++) {
282  for (int j = 1; j < 43; j++) {
283  hCalo1[i][j]->Write();
284  hCalo2[i][j]->Write();
285  hCalo1mom2[i][j]->Write();
286  hCalo2mom2[i][j]->Write();
287  }
288  }
289 
290  edm::LogVerbatim("AnalyzerMB") << " File is closed ";
291 
292  return;
293  }
double theMBFillDetMapMin0[5][5][73][43]
double theMBFillDetMapMin2[5][5][73][43]
Log< level::Info, true > LogVerbatim
double theDFFillDetMapPl2[5][5][73][43]
double theMBFillDetMapMin1[5][5][73][43]
double theNSFillDetMapPl4[5][5][73][43]
double theNSFillDetMapPl0[5][5][73][43]
double theNSFillDetMapMin0[5][5][73][43]
double theMBFillDetMapPl0[5][5][73][43]
TH1F * hCalo2mom2[73][43]
double theDFFillDetMapPl1[5][5][73][43]
int ii
Definition: cuy.py:589
double theNSFillDetMapPl2[5][5][73][43]
double theDFFillDetMapMin2[5][5][73][43]
TH1F * hCalo1mom2[73][43]
double theNSFillDetMapPl1[5][5][73][43]
double theMBFillDetMapPl1[5][5][73][43]
double theDFFillDetMapPl0[5][5][73][43]
double theMBFillDetMapPl4[5][5][73][43]
double theNSFillDetMapMin1[5][5][73][43]
double theNSFillDetMapMin4[5][5][73][43]
double theDFFillDetMapMin0[5][5][73][43]
double theMBFillDetMapPl2[5][5][73][43]
double theMBFillDetMapMin4[5][5][73][43]
double theNSFillDetMapMin2[5][5][73][43]
double theDFFillDetMapMin1[5][5][73][43]
void cms::Analyzer_minbias::endRun ( edm::Run const &  r,
edm::EventSetup const &   
)
override

Definition at line 80 of file Analyzer_minbias.cc.

References nevent_run, and edm::RunBase::run().

80  {
81  edm::LogVerbatim("AnalyzerMB") << " Runnumber " << r.run() << " Nevents " << nevent_run;
82  }
Log< level::Info, true > LogVerbatim

Member Data Documentation

int cms::Analyzer_minbias::depth
private
float cms::Analyzer_minbias::eta
private
std::string cms::Analyzer_minbias::fOutputFileName
private

Definition at line 75 of file Analyzer_minbias.h.

Referenced by Analyzer_minbias().

edm::Service<TFileService> cms::Analyzer_minbias::fs
private

Definition at line 82 of file Analyzer_minbias.h.

Referenced by beginJob().

TH1F* cms::Analyzer_minbias::hbheNoiseE
private

Definition at line 90 of file Analyzer_minbias.h.

Referenced by analyze(), and beginJob().

TH1F* cms::Analyzer_minbias::hbheSignalE
private

Definition at line 91 of file Analyzer_minbias.h.

Referenced by analyze(), and beginJob().

std::string cms::Analyzer_minbias::hcalfile_
private

Definition at line 76 of file Analyzer_minbias.h.

TH1F* cms::Analyzer_minbias::hCalo1[73][43]
private

Definition at line 86 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

TH1F* cms::Analyzer_minbias::hCalo1mom2[73][43]
private

Definition at line 88 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

TH1F* cms::Analyzer_minbias::hCalo2[73][43]
private

Definition at line 87 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

TH1F* cms::Analyzer_minbias::hCalo2mom2[73][43]
private

Definition at line 89 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

TH1F* cms::Analyzer_minbias::hfNoiseE
private

Definition at line 92 of file Analyzer_minbias.h.

Referenced by analyze(), and beginJob().

TH1F* cms::Analyzer_minbias::hfSignalE
private

Definition at line 93 of file Analyzer_minbias.h.

Referenced by analyze(), and beginJob().

TH2F* cms::Analyzer_minbias::hHBHEsize_vs_run
private

Definition at line 95 of file Analyzer_minbias.h.

Referenced by analyze(), and beginJob().

TH2F* cms::Analyzer_minbias::hHFsize_vs_run
private

Definition at line 96 of file Analyzer_minbias.h.

Referenced by analyze(), and beginJob().

TFile* cms::Analyzer_minbias::hOutputFile
private

Definition at line 84 of file Analyzer_minbias.h.

int cms::Analyzer_minbias::ieta
private

Definition at line 99 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

int cms::Analyzer_minbias::iphi
private

Definition at line 99 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

double cms::Analyzer_minbias::meannoise_min[73][43]
private

Definition at line 107 of file Analyzer_minbias.h.

Referenced by beginJob().

double cms::Analyzer_minbias::meannoise_pl[73][43]
private

Definition at line 107 of file Analyzer_minbias.h.

Referenced by beginJob().

float cms::Analyzer_minbias::mom0_Diff
private

Definition at line 103 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

float cms::Analyzer_minbias::mom0_MB
private

Definition at line 101 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

float cms::Analyzer_minbias::mom0_Noise
private

Definition at line 102 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

float cms::Analyzer_minbias::mom1_Diff
private

Definition at line 103 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

float cms::Analyzer_minbias::mom1_MB
private

Definition at line 101 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

float cms::Analyzer_minbias::mom1_Noise
private

Definition at line 102 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

float cms::Analyzer_minbias::mom2_Diff
private

Definition at line 103 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

float cms::Analyzer_minbias::mom2_MB
private

Definition at line 101 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

float cms::Analyzer_minbias::mom2_Noise
private

Definition at line 102 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

float cms::Analyzer_minbias::mom3_Diff
private

Definition at line 103 of file Analyzer_minbias.h.

float cms::Analyzer_minbias::mom3_MB
private

Definition at line 101 of file Analyzer_minbias.h.

float cms::Analyzer_minbias::mom3_Noise
private

Definition at line 102 of file Analyzer_minbias.h.

float cms::Analyzer_minbias::mom4_Diff
private

Definition at line 103 of file Analyzer_minbias.h.

float cms::Analyzer_minbias::mom4_MB
private

Definition at line 101 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

float cms::Analyzer_minbias::mom4_Noise
private

Definition at line 102 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

int cms::Analyzer_minbias::mydet
private

Definition at line 99 of file Analyzer_minbias.h.

Referenced by beginJob().

std::ofstream* cms::Analyzer_minbias::myout_hcal
private

Definition at line 77 of file Analyzer_minbias.h.

Referenced by beginJob().

int cms::Analyzer_minbias::mysubd
private

Definition at line 99 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

TTree* cms::Analyzer_minbias::myTree
private

Definition at line 85 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

double cms::Analyzer_minbias::nevent
private

Definition at line 112 of file Analyzer_minbias.h.

Referenced by analyze(), and beginJob().

int cms::Analyzer_minbias::nevent_run
private

Definition at line 98 of file Analyzer_minbias.h.

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

double cms::Analyzer_minbias::noise_min[73][43]
private

Definition at line 108 of file Analyzer_minbias.h.

Referenced by Analyzer_minbias().

double cms::Analyzer_minbias::noise_pl[73][43]
private

Definition at line 108 of file Analyzer_minbias.h.

Referenced by Analyzer_minbias().

float cms::Analyzer_minbias::occup
private

Definition at line 101 of file Analyzer_minbias.h.

Referenced by beginJob().

float cms::Analyzer_minbias::phi
private
double cms::Analyzer_minbias::theDFFillDetMapMin0[5][5][73][43]
private

Definition at line 136 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

double cms::Analyzer_minbias::theDFFillDetMapMin1[5][5][73][43]
private

Definition at line 137 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theDFFillDetMapMin2[5][5][73][43]
private

Definition at line 138 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theDFFillDetMapPl0[5][5][73][43]
private

Definition at line 133 of file Analyzer_minbias.h.

Referenced by beginJob(), and endJob().

double cms::Analyzer_minbias::theDFFillDetMapPl1[5][5][73][43]
private

Definition at line 134 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theDFFillDetMapPl2[5][5][73][43]
private

Definition at line 135 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theMBFillDetMapMin0[5][5][73][43]
private

Definition at line 118 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theMBFillDetMapMin1[5][5][73][43]
private

Definition at line 119 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theMBFillDetMapMin2[5][5][73][43]
private

Definition at line 120 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theMBFillDetMapMin4[5][5][73][43]
private

Definition at line 121 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theMBFillDetMapPl0[5][5][73][43]
private

Definition at line 113 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theMBFillDetMapPl1[5][5][73][43]
private

Definition at line 114 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theMBFillDetMapPl2[5][5][73][43]
private

Definition at line 115 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theMBFillDetMapPl4[5][5][73][43]
private

Definition at line 116 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theNSFillDetMapMin0[5][5][73][43]
private

Definition at line 128 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theNSFillDetMapMin1[5][5][73][43]
private

Definition at line 129 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theNSFillDetMapMin2[5][5][73][43]
private

Definition at line 130 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theNSFillDetMapMin4[5][5][73][43]
private

Definition at line 131 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theNSFillDetMapPl0[5][5][73][43]
private

Definition at line 123 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theNSFillDetMapPl1[5][5][73][43]
private

Definition at line 124 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theNSFillDetMapPl2[5][5][73][43]
private

Definition at line 125 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

double cms::Analyzer_minbias::theNSFillDetMapPl4[5][5][73][43]
private

Definition at line 126 of file Analyzer_minbias.h.

Referenced by analyze(), beginJob(), and endJob().

bool cms::Analyzer_minbias::theRecalib
private

Definition at line 155 of file Analyzer_minbias.h.

Referenced by analyze(), and Analyzer_minbias().

edm::EDGetTokenT<FEDRawDataCollection> cms::Analyzer_minbias::tok_data_
private

Definition at line 79 of file Analyzer_minbias.h.

Referenced by Analyzer_minbias().

edm::EDGetTokenT<L1GlobalTriggerReadoutRecord> cms::Analyzer_minbias::tok_gtRec_
private

Definition at line 149 of file Analyzer_minbias.h.

Referenced by Analyzer_minbias().

edm::EDGetTokenT<HBHERecHitCollection> cms::Analyzer_minbias::tok_hbhe_
private

Definition at line 140 of file Analyzer_minbias.h.

Referenced by analyze(), and Analyzer_minbias().

edm::EDGetTokenT<HBHERecHitCollection> cms::Analyzer_minbias::tok_hbheNoise_
private

Definition at line 144 of file Analyzer_minbias.h.

Referenced by analyze(), and Analyzer_minbias().

edm::EDGetTokenT<HBHERecHitCollection> cms::Analyzer_minbias::tok_hbheNorm_
private

Definition at line 150 of file Analyzer_minbias.h.

Referenced by analyze(), and Analyzer_minbias().

edm::EDGetTokenT<HFRecHitCollection> cms::Analyzer_minbias::tok_hf_
private

Definition at line 142 of file Analyzer_minbias.h.

Referenced by analyze(), and Analyzer_minbias().

edm::EDGetTokenT<HFRecHitCollection> cms::Analyzer_minbias::tok_hfNoise_
private

Definition at line 146 of file Analyzer_minbias.h.

Referenced by analyze(), and Analyzer_minbias().

edm::EDGetTokenT<HORecHitCollection> cms::Analyzer_minbias::tok_ho_
private

Definition at line 141 of file Analyzer_minbias.h.

Referenced by Analyzer_minbias().

edm::EDGetTokenT<HORecHitCollection> cms::Analyzer_minbias::tok_hoNoise_
private

Definition at line 145 of file Analyzer_minbias.h.

Referenced by Analyzer_minbias().

edm::ESGetToken<L1GtTriggerMenu, L1GtTriggerMenuRcd> cms::Analyzer_minbias::tok_l1gt_
private

Definition at line 153 of file Analyzer_minbias.h.

Referenced by Analyzer_minbias().

edm::ESGetToken<HcalRespCorrs, HcalRespCorrsRcd> cms::Analyzer_minbias::tok_respCorr_
private

Definition at line 152 of file Analyzer_minbias.h.

Referenced by analyze(), and Analyzer_minbias().