CMS 3D CMS Logo

HcalHitReconstructor.cc
Go to the documentation of this file.
1 #include "HcalHitReconstructor.h"
21 #include <iostream>
22 #include <fstream>
23 
24 /* Hcal Hit reconstructor allows for CaloRecHits with status words */
25 
27  : reco_(conf.getParameter<bool>("correctForTimeslew"),
28  conf.getParameter<bool>("correctForPhaseContainment"),
29  conf.getParameter<double>("correctionPhaseNS"),
30  consumesCollector()),
31  det_(DetId::Hcal),
32  inputLabel_(conf.getParameter<edm::InputTag>("digiLabel")),
33  correctTiming_(conf.getParameter<bool>("correctTiming")),
34  setNoiseFlags_(conf.getParameter<bool>("setNoiseFlags")),
35  setHSCPFlags_(conf.getParameter<bool>("setHSCPFlags")),
36  setSaturationFlags_(conf.getParameter<bool>("setSaturationFlags")),
37  setTimingTrustFlags_(conf.getParameter<bool>("setTimingTrustFlags")),
38  setPulseShapeFlags_(conf.getParameter<bool>("setPulseShapeFlags")),
39  setNegativeFlags_(false),
40  dropZSmarkedPassed_(conf.getParameter<bool>("dropZSmarkedPassed")),
41  firstAuxTS_(conf.getParameter<int>("firstAuxTS")),
42  firstSample_(conf.getParameter<int>("firstSample")),
43  samplesToAdd_(conf.getParameter<int>("samplesToAdd")),
44  tsFromDB_(conf.getParameter<bool>("tsFromDB")),
45  useLeakCorrection_(conf.getParameter<bool>("useLeakCorrection")),
46  dataOOTCorrectionName_(""),
47  dataOOTCorrectionCategory_("Data"),
48  mcOOTCorrectionName_(""),
49  mcOOTCorrectionCategory_("MC"),
50  setPileupCorrection_(nullptr) {
51  // register for data access
52  tok_ho_ = consumes<HODigiCollection>(inputLabel_);
53  tok_hf_ = consumes<HFDigiCollection>(inputLabel_);
54  tok_calib_ = consumes<HcalCalibDigiCollection>(inputLabel_);
55 
56  std::string subd = conf.getParameter<std::string>("Subdetector");
57  //Set all FlagSetters to 0
58  /* Important to do this! Otherwise, if the setters are turned off,
59  the "if (XSetter_) delete XSetter_;" commands can crash
60  */
61 
62  recoParamsFromDB_ = conf.getParameter<bool>("recoParamsFromDB");
63  // recoParamsFromDB_ = false ; // trun off for now.
64 
65  // std::cout<<" HcalHitReconstructor recoParamsFromDB_ "<<recoParamsFromDB_<<std::endl;
66 
67  if (conf.existsAs<bool>("setNegativeFlags"))
68  setNegativeFlags_ = conf.getParameter<bool>("setNegativeFlags");
69 
70  hfdigibit_ = nullptr;
71 
72  hfS9S1_ = nullptr;
73  hfS8S1_ = nullptr;
74  hfPET_ = nullptr;
75  saturationFlagSetter_ = nullptr;
76  HFTimingTrustFlagSetter_ = nullptr;
77  digiTimeFromDB_ = false; // only need for HF
78 
79  if (setSaturationFlags_) {
80  const edm::ParameterSet& pssat = conf.getParameter<edm::ParameterSet>("saturationParameters");
81  saturationFlagSetter_ = new HcalADCSaturationFlag(pssat.getParameter<int>("maxADCvalue"));
82  }
83 
84  if (!strcasecmp(subd.c_str(), "HO")) {
86  // setPileupCorrection_ = &HcalSimpleRecAlgo::setHOPileupCorrection;
87  setPileupCorrection_ = nullptr;
88  produces<HORecHitCollection>();
89  } else if (!strcasecmp(subd.c_str(), "HF")) {
91  // setPileupCorrection_ = &HcalSimpleRecAlgo::setHFPileupCorrection;
92  setPileupCorrection_ = nullptr;
93  digiTimeFromDB_ = conf.getParameter<bool>("digiTimeFromDB");
94 
96  const edm::ParameterSet& pstrust = conf.getParameter<edm::ParameterSet>("hfTimingTrustParameters");
97  HFTimingTrustFlagSetter_ = new HFTimingTrustFlag(pstrust.getParameter<int>("hfTimingTrustLevel1"),
98  pstrust.getParameter<int>("hfTimingTrustLevel2"));
99  }
100 
101  if (setNoiseFlags_) {
102  const edm::ParameterSet& psdigi = conf.getParameter<edm::ParameterSet>("digistat");
103  const edm::ParameterSet& psTimeWin = conf.getParameter<edm::ParameterSet>("HFInWindowStat");
104  hfdigibit_ = new HcalHFStatusBitFromDigis(psdigi, psTimeWin);
105 
106  const edm::ParameterSet& psS9S1 = conf.getParameter<edm::ParameterSet>("S9S1stat");
107  hfS9S1_ = new HcalHF_S9S1algorithm(psS9S1.getParameter<std::vector<double> >("short_optimumSlope"),
108  psS9S1.getParameter<std::vector<double> >("shortEnergyParams"),
109  psS9S1.getParameter<std::vector<double> >("shortETParams"),
110  psS9S1.getParameter<std::vector<double> >("long_optimumSlope"),
111  psS9S1.getParameter<std::vector<double> >("longEnergyParams"),
112  psS9S1.getParameter<std::vector<double> >("longETParams"),
113  psS9S1.getParameter<int>("HcalAcceptSeverityLevel"),
114  psS9S1.getParameter<bool>("isS8S1"));
115 
116  const edm::ParameterSet& psS8S1 = conf.getParameter<edm::ParameterSet>("S8S1stat");
117  hfS8S1_ = new HcalHF_S9S1algorithm(psS8S1.getParameter<std::vector<double> >("short_optimumSlope"),
118  psS8S1.getParameter<std::vector<double> >("shortEnergyParams"),
119  psS8S1.getParameter<std::vector<double> >("shortETParams"),
120  psS8S1.getParameter<std::vector<double> >("long_optimumSlope"),
121  psS8S1.getParameter<std::vector<double> >("longEnergyParams"),
122  psS8S1.getParameter<std::vector<double> >("longETParams"),
123  psS8S1.getParameter<int>("HcalAcceptSeverityLevel"),
124  psS8S1.getParameter<bool>("isS8S1"));
125 
126  const edm::ParameterSet& psPET = conf.getParameter<edm::ParameterSet>("PETstat");
127  hfPET_ = new HcalHF_PETalgorithm(psPET.getParameter<std::vector<double> >("short_R"),
128  psPET.getParameter<std::vector<double> >("shortEnergyParams"),
129  psPET.getParameter<std::vector<double> >("shortETParams"),
130  psPET.getParameter<std::vector<double> >("long_R"),
131  psPET.getParameter<std::vector<double> >("longEnergyParams"),
132  psPET.getParameter<std::vector<double> >("longETParams"),
133  psPET.getParameter<int>("HcalAcceptSeverityLevel"),
134  psPET.getParameter<std::vector<double> >("short_R_29"),
135  psPET.getParameter<std::vector<double> >("long_R_29"));
136  }
137  produces<HFRecHitCollection>();
138  } else if (!strcasecmp(subd.c_str(), "ZDC")) {
139  det_ = DetId::Calo;
141  produces<ZDCRecHitCollection>();
142  } else if (!strcasecmp(subd.c_str(), "CALIB")) {
143  subdet_ = HcalOther;
145  produces<HcalCalibRecHitCollection>();
146  } else {
147  edm::LogWarning("Configuration") << "HcalHitReconstructor is not associated with a specific subdetector!"
148  << std::endl;
149  }
150 
151  // If no valid OOT pileup correction name specified,
152  // disable the correction
153  if (conf.existsAs<std::string>("dataOOTCorrectionName"))
154  dataOOTCorrectionName_ = conf.getParameter<std::string>("dataOOTCorrectionName");
155  if (conf.existsAs<std::string>("dataOOTCorrectionCategory"))
156  dataOOTCorrectionCategory_ = conf.getParameter<std::string>("dataOOTCorrectionCategory");
157  if (conf.existsAs<std::string>("mcOOTCorrectionName"))
158  mcOOTCorrectionName_ = conf.getParameter<std::string>("mcOOTCorrectionName");
159  if (conf.existsAs<std::string>("mcOOTCorrectionCategory"))
160  mcOOTCorrectionCategory_ = conf.getParameter<std::string>("mcOOTCorrectionCategory");
161  if (dataOOTCorrectionName_.empty() && mcOOTCorrectionName_.empty())
162  setPileupCorrection_ = nullptr;
163 
164  // ES tokens
165  htopoToken_ = esConsumes<HcalTopology, HcalRecNumberingRecord, edm::Transition::BeginRun>();
167  paramsToken_ = esConsumes<HcalRecoParams, HcalRecoParamsRcd, edm::Transition::BeginRun>();
168  if (digiTimeFromDB_)
169  digiTimeToken_ = esConsumes<HcalFlagHFDigiTimeParams, HcalFlagHFDigiTimeParamsRcd, edm::Transition::BeginRun>();
170  conditionsToken_ = esConsumes<HcalDbService, HcalDbRecord>();
171  qualToken_ = esConsumes<HcalChannelQuality, HcalChannelQualityRcd>(edm::ESInputTag("", "withTopo"));
172  sevToken_ = esConsumes<HcalSeverityLevelComputer, HcalSeverityLevelComputerRcd>();
173 }
174 
176  delete hfdigibit_;
177 
178  delete hfS9S1_;
179  delete hfS8S1_;
180  delete hfPET_;
181  delete saturationFlagSetter_;
183 }
184 
186  const HcalTopology& htopo = es.getData(htopoToken_);
187 
188  if (tsFromDB_ || recoParamsFromDB_) {
189  const HcalRecoParams& p = es.getData(paramsToken_);
190  paramTS_ = std::make_unique<HcalRecoParams>(p);
191  paramTS_->setTopo(&htopo);
192 
193  // std::cout<<" skdump in HcalHitReconstructor::beginRun dupm RecoParams "<<std::endl;
194  // std::ofstream skfile("skdumpRecoParamsNewFormat.txt");
195  // HcalDbASCIIIO::dumpObject(skfile, (*paramTS_) );
196  }
197 
198  if (digiTimeFromDB_) {
200  hFDigiTimeParams_ = std::make_unique<HcalFlagHFDigiTimeParams>(p);
201  hFDigiTimeParams_->setTopo(&htopo);
202  }
203 
204  reco_.beginRun(es);
205 }
206 
208 
210  // get conditions
211  const HcalDbService* conditions = &eventSetup.getData(conditionsToken_);
212  const HcalChannelQuality* myqual = &eventSetup.getData(qualToken_);
213  const HcalSeverityLevelComputer* mySeverity = &eventSetup.getData(sevToken_);
214 
215  if (useLeakCorrection_)
217 
218  // GET THE BEAM CROSSING INFO HERE, WHEN WE UNDERSTAND HOW THINGS WORK.
219  // Then, call "setBXInfo" method of the reco_ object.
220  // Also remember to call SetBXInfo in the negative energy flag setter.
221 
222  if (det_ == DetId::Hcal) {
223  // HO ------------------------------------------------------------------
224  if (subdet_ == HcalOuter) {
226  e.getByToken(tok_ho_, digi);
227 
228  // create empty output
229  auto rec = std::make_unique<HORecHitCollection>();
230  rec->reserve(digi->size());
231  // run the algorithm
233 
234  // Vote on majority TS0 CapId
235  int favorite_capid = 0;
236  if (correctTiming_) {
237  long capid_votes[4] = {0, 0, 0, 0};
238  for (i = digi->begin(); i != digi->end(); i++) {
239  capid_votes[(*i)[0].capid()]++;
240  }
241  for (int k = 0; k < 4; k++)
242  if (capid_votes[k] > capid_votes[favorite_capid])
243  favorite_capid = k;
244  }
245 
246  for (i = digi->begin(); i != digi->end(); i++) {
247  HcalDetId cell = i->id();
248  DetId detcell = (DetId)cell;
249  // firstSample & samplesToAdd
250  if (tsFromDB_ || recoParamsFromDB_) {
251  const HcalRecoParam* param_ts = paramTS_->getValues(detcell.rawId());
252  if (tsFromDB_) {
253  firstSample_ = param_ts->firstSample();
254  samplesToAdd_ = param_ts->samplesToAdd();
255  }
256  if (recoParamsFromDB_) {
257  bool correctForTimeslew = param_ts->correctForTimeslew();
259  float phaseNS = param_ts->correctionPhaseNS();
261  correctTiming_ = param_ts->correctTiming();
262  firstAuxTS_ = param_ts->firstAuxTS();
263  int pileupCleaningID = param_ts->pileupCleaningID();
266  }
267  }
268 
269  int first = firstSample_;
270  int toadd = samplesToAdd_;
271 
272  if (first >= i->size() || first < 0)
273  edm::LogWarning("Configuration")
274  << "HcalHitReconstructor: illegal firstSample" << first << " in subdet " << subdet_ << std::endl;
275 
276  // check on cells to be ignored and dropped: (rof,20.Feb.09)
277  const HcalChannelStatus* mydigistatus = myqual->getValues(detcell.rawId());
278  if (mySeverity->dropChannel(mydigistatus->getValue()))
279  continue;
281  if (i->zsMarkAndPass())
282  continue;
283 
284  const HcalCalibrations& calibrations = conditions->getHcalCalibrations(cell);
285  const HcalQIECoder* channelCoder = conditions->getHcalCoder(cell);
286  const HcalQIEShape* shape = conditions->getHcalShape(channelCoder);
287  HcalCoderDb coder(*channelCoder, *shape);
288 
289  rec->push_back(reco_.reconstruct(*i, first, toadd, coder, calibrations));
290 
291  // Set auxiliary flag
292  int auxflag = 0;
293  int fTS = firstAuxTS_;
294  if (fTS < 0)
295  fTS = 0; //silly protection against negative time slice values
296  for (int xx = fTS; xx < fTS + 4 && xx < i->size(); ++xx)
297  auxflag += (i->sample(xx).adc())
298  << (7 *
299  (xx - fTS)); // store the time slices in the first 28 bits of aux, a set of 4 7-bit adc values
300  // bits 28 and 29 are reserved for capid of the first time slice saved in aux
301  auxflag += ((i->sample(fTS).capid()) << 28);
302  (rec->back()).setAux(auxflag);
303  // (rec->back()).setFlags(0); Don't want to do this because the algorithm
304  // can already set some flags
305  // Fill Presample ADC flag
306  if (fTS > 0)
307  (rec->back()).setFlagField((i->sample(fTS - 1).adc()), HcalCaloFlagLabels::PresampleADC, 7);
308 
310  saturationFlagSetter_->setSaturationFlag(rec->back(), *i);
311  if (correctTiming_)
312  HcalTimingCorrector::Correct(rec->back(), *i, favorite_capid);
313  }
314  // return result
315  e.put(std::move(rec));
316 
317  // HF -------------------------------------------------------------------
318  } else if (subdet_ == HcalForward) {
320  e.getByToken(tok_hf_, digi);
321 
323  // create empty output
324  auto rec = std::make_unique<HFRecHitCollection>();
325  rec->reserve(digi->size());
326  // run the algorithm
328 
329  // Vote on majority TS0 CapId
330  int favorite_capid = 0;
331  if (correctTiming_) {
332  long capid_votes[4] = {0, 0, 0, 0};
333  for (i = digi->begin(); i != digi->end(); i++) {
334  capid_votes[(*i)[0].capid()]++;
335  }
336  for (int k = 0; k < 4; k++)
337  if (capid_votes[k] > capid_votes[favorite_capid])
338  favorite_capid = k;
339  }
340 
341  for (i = digi->begin(); i != digi->end(); i++) {
342  HcalDetId cell = i->id();
343  DetId detcell = (DetId)cell;
344 
345  if (tsFromDB_ || recoParamsFromDB_) {
346  const HcalRecoParam* param_ts = paramTS_->getValues(detcell.rawId());
347  if (tsFromDB_) {
348  firstSample_ = param_ts->firstSample();
349  samplesToAdd_ = param_ts->samplesToAdd();
350  }
351  if (recoParamsFromDB_) {
352  bool correctForTimeslew = param_ts->correctForTimeslew();
354  float phaseNS = param_ts->correctionPhaseNS();
356  correctTiming_ = param_ts->correctTiming();
357  firstAuxTS_ = param_ts->firstAuxTS();
358  int pileupCleaningID = param_ts->pileupCleaningID();
361  }
362  }
363 
364  int first = firstSample_;
365  int toadd = samplesToAdd_;
366 
367  if (first >= i->size() || first < 0)
368  edm::LogWarning("Configuration")
369  << "HcalHitReconstructor: illegal firstSample" << first << " in subdet " << subdet_ << std::endl;
370 
371  // check on cells to be ignored and dropped: (rof,20.Feb.09)
372  const HcalChannelStatus* mydigistatus = myqual->getValues(detcell.rawId());
373  if (mySeverity->dropChannel(mydigistatus->getValue()))
374  continue;
376  if (i->zsMarkAndPass())
377  continue;
378 
379  const HcalCalibrations& calibrations = conditions->getHcalCalibrations(cell);
380  const HcalQIECoder* channelCoder = conditions->getHcalCoder(cell);
381  const HcalQIEShape* shape = conditions->getHcalShape(channelCoder);
382  HcalCoderDb coder(*channelCoder, *shape);
383 
384  // Set HFDigiTime flag values from digiTimeFromDB_
385  if (digiTimeFromDB_ && hfdigibit_) {
386  const HcalFlagHFDigiTimeParam* hfDTparam = hFDigiTimeParams_->getValues(detcell.rawId());
388  hfDTparam->HFdigiflagSamplesToAdd(),
389  hfDTparam->HFdigiflagExpectedPeak(),
390  hfDTparam->HFdigiflagMinEThreshold(),
391  hfDTparam->HFdigiflagCoefficients());
392  }
393 
394  //std::cout << "TOADDHF " << toadd << " " << first << " " << std::endl;
395  rec->push_back(reco_.reconstruct(*i, first, toadd, coder, calibrations));
396 
397  // Set auxiliary flag
398  int auxflag = 0;
399  int fTS = firstAuxTS_;
400  if (fTS < 0)
401  fTS = 0; // silly protection against negative time slice values
402  for (int xx = fTS; xx < fTS + 4 && xx < i->size(); ++xx)
403  auxflag += (i->sample(xx).adc())
404  << (7 *
405  (xx - fTS)); // store the time slices in the first 28 bits of aux, a set of 4 7-bit adc values
406  // bits 28 and 29 are reserved for capid of the first time slice saved in aux
407  auxflag += ((i->sample(fTS).capid()) << 28);
408  (rec->back()).setAux(auxflag);
409 
410  // (rec->back()).setFlags(0); Don't want to do this because the algorithm
411  // can already set some flags
412 
413  // Fill Presample ADC flag
414  if (fTS > 0)
415  (rec->back()).setFlagField((i->sample(fTS - 1).adc()), HcalCaloFlagLabels::PresampleADC, 7);
416 
417  // This calls the code for setting the HF noise bit determined from digi shape
418  if (setNoiseFlags_)
419  hfdigibit_->hfSetFlagFromDigi(rec->back(), *i, coder, calibrations);
421  saturationFlagSetter_->setSaturationFlag(rec->back(), *i);
424  if (correctTiming_)
425  HcalTimingCorrector::Correct(rec->back(), *i, favorite_capid);
426  } // for (i=digi->begin(); i!=digi->end(); i++) -- loop on all HF digis
427 
428  // The following flags require the full set of rechits
429  // These need to be set consecutively, so an energy check should be the first
430  // test performed on these hits (to minimize the loop time)
431  if (setNoiseFlags_) {
432  // Step 1: Set PET flag (short fibers of |ieta|==29)
433  // Neighbor/partner channels that are flagged by Pulse Shape algorithm (HFDigiTime)
434  // won't be considered in these calculations
435  for (HFRecHitCollection::iterator i = rec->begin(); i != rec->end(); ++i) {
436  int depth = i->id().depth();
437  int ieta = i->id().ieta();
438  // Short fibers and all channels at |ieta|=29 use PET settings in Algo 3
439  if (depth == 2 || abs(ieta) == 29)
440  hfPET_->HFSetFlagFromPET(*i, *rec, myqual, mySeverity);
441  }
442 
443  // Step 2: Set S8S1 flag (short fibers or |ieta|==29)
444  for (HFRecHitCollection::iterator i = rec->begin(); i != rec->end(); ++i) {
445  int depth = i->id().depth();
446  int ieta = i->id().ieta();
447  // Short fibers and all channels at |ieta|=29 use PET settings in Algo 3
448  if (depth == 2 || abs(ieta) == 29)
449  hfS8S1_->HFSetFlagFromS9S1(*i, *rec, myqual, mySeverity);
450  }
451 
452  // Set 3: Set S9S1 flag (long fibers)
453  for (HFRecHitCollection::iterator i = rec->begin(); i != rec->end(); ++i) {
454  int depth = i->id().depth();
455  int ieta = i->id().ieta();
456  // Short fibers and all channels at |ieta|=29 use PET settings in Algo 3
457  if (depth == 1 && abs(ieta) != 29)
458  hfS9S1_->HFSetFlagFromS9S1(*i, *rec, myqual, mySeverity);
459  }
460  }
461 
462  // return result
463  e.put(std::move(rec));
464  } else if (subdet_ == HcalOther && subdetOther_ == HcalCalibration) {
466  e.getByToken(tok_calib_, digi);
467 
468  // create empty output
469  auto rec = std::make_unique<HcalCalibRecHitCollection>();
470  rec->reserve(digi->size());
471  // run the algorithm
472  int first = firstSample_;
473  int toadd = samplesToAdd_;
474 
476  for (i = digi->begin(); i != digi->end(); i++) {
477  HcalCalibDetId cell = i->id();
478  // HcalDetId cellh = i->id();
479  DetId detcell = (DetId)cell;
480  // check on cells to be ignored and dropped: (rof,20.Feb.09)
481  const HcalChannelStatus* mydigistatus = myqual->getValues(detcell.rawId());
482  if (mySeverity->dropChannel(mydigistatus->getValue()))
483  continue;
485  if (i->zsMarkAndPass())
486  continue;
487 
488  const HcalCalibrations& calibrations = conditions->getHcalCalibrations(cell);
489  const HcalQIECoder* channelCoder = conditions->getHcalCoder(cell);
490  const HcalQIEShape* shape = conditions->getHcalShape(channelCoder);
491  HcalCoderDb coder(*channelCoder, *shape);
492 
493  // firstSample & samplesToAdd
494  if (tsFromDB_) {
495  const HcalRecoParam* param_ts = paramTS_->getValues(detcell.rawId());
496  first = param_ts->firstSample();
497  toadd = param_ts->samplesToAdd();
498  }
499  rec->push_back(reco_.reconstruct(*i, first, toadd, coder, calibrations));
500 
501  /*
502  // Flag setting not available for calibration rechits
503  // Set auxiliary flag
504  int auxflag=0;
505  int fTS = firstAuxTS_;
506  for (int xx=fTS; xx<fTS+4 && xx<i->size();++xx)
507  auxflag+=(i->sample(xx).adc())<<(7*(xx-fTS)); // store the time slices in the first 28 bits of aux, a set of 4 7-bit adc values
508  // bits 28 and 29 are reserved for capid of the first time slice saved in aux
509  auxflag+=((i->sample(fTS).capid())<<28);
510  (rec->back()).setAux(auxflag);
511 
512  (rec->back()).setFlags(0); // Not yet implemented for HcalCalibRecHit
513  */
514  }
515  // return result
516  e.put(std::move(rec));
517  }
518  }
519  //DL delete myqual;
520 } // void HcalHitReconstructor::produce(...)
HcalOther
Definition: HcalAssistant.h:38
Handle.h
HcalRecoParam::correctionPhaseNS
constexpr float correctionPhaseNS() const
Definition: HcalRecoParam.h:30
HcalHitReconstructor::endRun
void endRun(edm::Run const &r, edm::EventSetup const &es) final
Definition: HcalHitReconstructor.cc:207
electrons_cff.bool
bool
Definition: electrons_cff.py:393
mps_fire.i
i
Definition: mps_fire.py:428
edm::ESInputTag
Definition: ESInputTag.h:87
HcalFlagHFDigiTimeParam::HFdigiflagCoefficients
std::vector< double > HFdigiflagCoefficients() const
Definition: HcalFlagHFDigiTimeParam.h:62
edm::SortedCollection::const_iterator
std::vector< T >::const_iterator const_iterator
Definition: SortedCollection.h:80
funct::false
false
Definition: Factorize.h:29
HcalHitReconstructor::paramTS_
std::unique_ptr< HcalRecoParams > paramTS_
Definition: HcalHitReconstructor.h:106
HcalHitReconstructor::digiTimeToken_
edm::ESGetToken< HcalFlagHFDigiTimeParams, HcalFlagHFDigiTimeParamsRcd > digiTimeToken_
Definition: HcalHitReconstructor.h:114
HcalHitReconstructor::paramsToken_
edm::ESGetToken< HcalRecoParams, HcalRecoParamsRcd > paramsToken_
Definition: HcalHitReconstructor.h:113
edm::Run
Definition: Run.h:45
HcalFlagHFDigiTimeParam::HFdigiflagSamplesToAdd
uint32_t HFdigiflagSamplesToAdd() const
Definition: HcalFlagHFDigiTimeParam.h:59
HcalCalibDetId
Definition: HcalCalibDetId.h:45
edm
HLT enums.
Definition: AlignableModifier.h:19
HcalHitReconstructor::HFTimingTrustFlagSetter_
HFTimingTrustFlag * HFTimingTrustFlagSetter_
Definition: HcalHitReconstructor.h:64
HcalTimingCorrector::Correct
static void Correct(HBHERecHit &rechit, const HBHEDataFrame &digi, int favorite_capid)
Definition: HcalTimingCorrector.cc:57
AlCaHLTBitMon_ParallelJobs.p
p
Definition: AlCaHLTBitMon_ParallelJobs.py:153
HcalHF_S9S1algorithm
Definition: HcalHF_S9S1algorithm.h:21
HcalHitReconstructor::~HcalHitReconstructor
~HcalHitReconstructor() override
Definition: HcalHitReconstructor.cc:175
HcalHF_S9S1algorithm::HFSetFlagFromS9S1
void HFSetFlagFromS9S1(HFRecHit &hf, HFRecHitCollection &rec, const HcalChannelQuality *myqual, const HcalSeverityLevelComputer *mySeverity)
Definition: HcalHF_S9S1algorithm.cc:81
HcalTopology
Definition: HcalTopology.h:26
DetId::Hcal
Definition: DetId.h:28
HLT_FULL_cff.InputTag
InputTag
Definition: HLT_FULL_cff.py:89287
HcalHitReconstructor::saturationFlagSetter_
HcalADCSaturationFlag * saturationFlagSetter_
Definition: HcalHitReconstructor.h:63
edm::SortedCollection::size
size_type size() const
Definition: SortedCollection.h:215
HcalRecNumberingRecord.h
AlignmentProducer_cff.calibrations
calibrations
Definition: AlignmentProducer_cff.py:59
HcalSimpleRecAlgo::beginRun
void beginRun(edm::EventSetup const &es)
Definition: HcalSimpleRecAlgo.cc:35
HcalHitReconstructor::subdet_
int subdet_
Definition: HcalHitReconstructor.h:71
HcalChannelQuality
Definition: HcalChannelQuality.h:17
HcalHitReconstructor::useLeakCorrection_
bool useLeakCorrection_
Definition: HcalHitReconstructor.h:97
edm::ParameterSet::existsAs
bool existsAs(std::string const &parameterName, bool trackiness=true) const
checks if a parameter exists as a given type
Definition: ParameterSet.h:171
edm::Handle
Definition: AssociativeIterator.h:50
HcalHitReconstructor::tsFromDB_
bool tsFromDB_
Definition: HcalHitReconstructor.h:92
DetId::Calo
Definition: DetId.h:29
HcalHFStatusBitFromDigis::hfSetFlagFromDigi
void hfSetFlagFromDigi(HFRecHit &hf, const HFDataFrame &digi, const HcalCoder &coder, const HcalCalibrations &calib)
Definition: HcalHFStatusBitFromDigis.cc:73
dqmdumpme.first
first
Definition: dqmdumpme.py:55
edm::LogWarning
Log< level::Warning, false > LogWarning
Definition: MessageLogger.h:122
HcalCondObjectContainer::getValues
const Item * getValues(DetId fId, bool throwOnFail=true) const
Definition: HcalCondObjectContainer.h:159
HcalCoderDb.h
HcalHF_PETalgorithm::HFSetFlagFromPET
void HFSetFlagFromPET(HFRecHit &hf, HFRecHitCollection &rec, const HcalChannelQuality *myqual, const HcalSeverityLevelComputer *mySeverity)
Definition: HcalHF_PETalgorithm.cc:67
HcalHitReconstructor::hFDigiTimeParams_
std::unique_ptr< HcalFlagHFDigiTimeParams > hFDigiTimeParams_
Definition: HcalHitReconstructor.h:107
OOTPileupCorrData.h
HcalHitReconstructor::setNoiseFlags_
bool setNoiseFlags_
Definition: HcalHitReconstructor.h:79
HcalHitReconstructor::conditionsToken_
edm::ESGetToken< HcalDbService, HcalDbRecord > conditionsToken_
Definition: HcalHitReconstructor.h:115
HcalHitReconstructor.h
HcalFlagHFDigiTimeParam::HFdigiflagExpectedPeak
uint32_t HFdigiflagExpectedPeak() const
Definition: HcalFlagHFDigiTimeParam.h:60
HcalHitReconstructor::recoParamsFromDB_
bool recoParamsFromDB_
Definition: HcalHitReconstructor.h:93
DetId
Definition: DetId.h:17
HcalRecoParam
Definition: HcalRecoParam.h:16
HcalHitReconstructor::firstAuxTS_
int firstAuxTS_
Definition: HcalHitReconstructor.h:87
edm::SortedCollection::begin
const_iterator begin() const
Definition: SortedCollection.h:262
HcalRecoParam::correctForPhaseContainment
constexpr bool correctForPhaseContainment() const
Definition: HcalRecoParam.h:28
HcalChannelStatus
Definition: HcalChannelStatus.h:13
HcalHitReconstructor::mcOOTCorrectionName_
std::string mcOOTCorrectionName_
Definition: HcalHitReconstructor.h:102
HcalRecoParam::useLeakCorrection
constexpr bool useLeakCorrection() const
Definition: HcalRecoParam.h:35
HcalHitReconstructor::samplesToAdd_
int samplesToAdd_
Definition: HcalHitReconstructor.h:91
HcalSeverityLevelComputer
Definition: HcalSeverityLevelComputer.h:24
HcalHitReconstructor::dropZSmarkedPassed_
bool dropZSmarkedPassed_
Definition: HcalHitReconstructor.h:85
HcalHitReconstructor::firstSample_
int firstSample_
Definition: HcalHitReconstructor.h:90
HcalADCSaturationFlag::setSaturationFlag
void setSaturationFlag(HBHERecHit &rechit, const HBHEDataFrame &digi)
Definition: HcalADCSaturationFlag.cc:33
HcalOuter
Definition: HcalAssistant.h:35
HcalHitReconstructor::sevToken_
edm::ESGetToken< HcalSeverityLevelComputer, HcalSeverityLevelComputerRcd > sevToken_
Definition: HcalHitReconstructor.h:117
HcalHitReconstructor::setSaturationFlags_
bool setSaturationFlags_
Definition: HcalHitReconstructor.h:81
HcalCalibration
Definition: HcalAssistant.h:40
HcalHitReconstructor::qualToken_
edm::ESGetToken< HcalChannelQuality, HcalChannelQualityRcd > qualToken_
Definition: HcalHitReconstructor.h:116
HcalHitReconstructor::digiTimeFromDB_
bool digiTimeFromDB_
Definition: HcalHitReconstructor.h:94
HcalOOTPileupCorrectionRcd.h
HcalZDCDetId::SubdetectorId
static const int SubdetectorId
Definition: HcalZDCDetId.h:25
dqmdumpme.k
k
Definition: dqmdumpme.py:60
HcalDbRecord.h
HcalCalibrations
Definition: HcalCalibrations.h:9
HcalHitReconstructor::HcalHitReconstructor
HcalHitReconstructor(const edm::ParameterSet &ps)
Definition: HcalHitReconstructor.cc:26
HcalRecoParam::samplesToAdd
constexpr unsigned int samplesToAdd() const
Definition: HcalRecoParam.h:32
LEDCalibrationChannels.depth
depth
Definition: LEDCalibrationChannels.py:65
HcalSeverityLevelComputer::dropChannel
bool dropChannel(const uint32_t &mystatus) const
Definition: HcalSeverityLevelComputer.cc:395
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
HcalSeverityLevelComputerRcd.h
HcalHitReconstructor::produce
void produce(edm::Event &e, const edm::EventSetup &c) override
Definition: HcalHitReconstructor.cc:209
HcalChannelStatus::getValue
uint32_t getValue() const
Definition: HcalChannelStatus.h:60
HcalFrontEndMap.h
LEDCalibrationChannels.ieta
ieta
Definition: LEDCalibrationChannels.py:63
HcalOOTPileupCompatibilityRcd.h
edm::ParameterSet
Definition: ParameterSet.h:47
HcalHitReconstructor::hfS9S1_
HcalHF_S9S1algorithm * hfS9S1_
Definition: HcalHitReconstructor.h:66
HcalRecoParam::correctTiming
constexpr bool correctTiming() const
Definition: HcalRecoParam.h:39
HcalHitReconstructor::setNegativeFlags_
bool setNegativeFlags_
Definition: HcalHitReconstructor.h:84
HcalHitReconstructor::tok_ho_
edm::EDGetTokenT< HODigiCollection > tok_ho_
Definition: HcalHitReconstructor.h:74
HcalFlagHFDigiTimeParam
Definition: HcalFlagHFDigiTimeParam.h:25
HcalHFStatusBitFromDigis::resetParamsFromDB
void resetParamsFromDB(int firstSample, int samplesToAdd, int expectedPeak, double minthreshold, const std::vector< double > &coef)
Definition: HcalHFStatusBitFromDigis.cc:55
edm::SortedCollection::iterator
std::vector< T >::iterator iterator
Definition: SortedCollection.h:81
HcalADCSaturationFlag
Definition: HcalADCSaturationFlag.h:23
castor_dqm_sourceclient-live_cfg.correctForPhaseContainment
correctForPhaseContainment
Definition: castor_dqm_sourceclient-live_cfg.py:65
HcalHitReconstructor::hfdigibit_
HcalHFStatusBitFromDigis * hfdigibit_
Definition: HcalHitReconstructor.h:65
edm::SortedCollection::end
const_iterator end() const
Definition: SortedCollection.h:267
HcalHitReconstructor::tok_calib_
edm::EDGetTokenT< HcalCalibDigiCollection > tok_calib_
Definition: HcalHitReconstructor.h:76
HcalHitReconstructor::dataOOTCorrectionCategory_
std::string dataOOTCorrectionCategory_
Definition: HcalHitReconstructor.h:101
HcalDetId
Definition: HcalDetId.h:12
createfilelist.int
int
Definition: createfilelist.py:10
HcalSimpleRecAlgo::setRecoParams
void setRecoParams(bool correctForTimeslew, bool correctForPulse, bool setLeakCorrection, int pileupCleaningID, float phaseNS)
Definition: HcalSimpleRecAlgo.cc:45
HcalHFStatusBitFromDigis
Definition: HcalHFStatusBitFromDigis.h:18
HcalHitReconstructor::det_
DetId::Detector det_
Definition: HcalHitReconstructor.h:70
edm::EventSetup
Definition: EventSetup.h:57
HcalSimpleRecAlgo::setLeakCorrection
void setLeakCorrection()
Definition: HcalSimpleRecAlgo.cc:54
HcalHitReconstructor::inputLabel_
edm::InputTag inputLabel_
Definition: HcalHitReconstructor.h:73
HcalHitReconstructor::setPileupCorrection_
SetCorrectionFcn setPileupCorrection_
Definition: HcalHitReconstructor.h:104
HcalQIECoder
Definition: HcalQIECoder.h:20
HcalHitReconstructor::hfPET_
HcalHF_PETalgorithm * hfPET_
Definition: HcalHitReconstructor.h:68
edm::EventSetup::getData
bool getData(T &iHolder) const
Definition: EventSetup.h:120
alignCSCRings.r
r
Definition: alignCSCRings.py:93
OOTPileupCorrectionColl.h
HcalForward
Definition: HcalAssistant.h:36
HcalHitReconstructor::reco_
HcalSimpleRecAlgo reco_
Definition: HcalHitReconstructor.h:62
HcalHitReconstructor::setTimingTrustFlags_
bool setTimingTrustFlags_
Definition: HcalHitReconstructor.h:82
HcalRecoParam::firstSample
constexpr unsigned int firstSample() const
Definition: HcalRecoParam.h:31
HcalTopology.h
HcalDbService
Definition: HcalDbService.h:26
HcalFlagHFDigiTimeParams
Definition: HcalFlagHFDigiTimeParams.h:9
submitPVValidationJobs.conditions
list conditions
Definition: submitPVValidationJobs.py:674
eostools.move
def move(src, dest)
Definition: eostools.py:511
DetId::rawId
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:57
HcalHitReconstructor::hfS8S1_
HcalHF_S9S1algorithm * hfS8S1_
Definition: HcalHitReconstructor.h:67
HcalDbASCIIIO.h
HcalCaloFlagLabels::HFTimingTrustFlag
HFTimingTrustFlag
Definition: HcalCaloFlagLabels.h:32
castor_dqm_sourceclient-live_cfg.correctForTimeslew
correctForTimeslew
Definition: castor_dqm_sourceclient-live_cfg.py:66
HcalHitReconstructor::htopoToken_
edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > htopoToken_
Definition: HcalHitReconstructor.h:112
HBHENegativeEFilterRcd.h
HcalHitReconstructor::subdetOther_
HcalOtherSubdetector subdetOther_
Definition: HcalHitReconstructor.h:72
HcalHitReconstructor::beginRun
void beginRun(edm::Run const &r, edm::EventSetup const &es) final
Definition: HcalHitReconstructor.cc:185
HcalRecoParams
Definition: HcalRecoParams.h:9
HcalRecoParam::firstAuxTS
constexpr unsigned int firstAuxTS() const
Definition: HcalRecoParam.h:40
EventSetup.h
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
HcalRecHitCollections.h
HcalSeverityLevelComputer.h
HcalQIEShape
Definition: HcalQIEShape.h:17
HcalFlagHFDigiTimeParam::HFdigiflagFirstSample
uint32_t HFdigiflagFirstSample() const
Definition: HcalFlagHFDigiTimeParam.h:58
HcalCoderDb
Definition: HcalCoderDb.h:15
HcalHitReconstructor::correctTiming_
bool correctTiming_
Definition: HcalHitReconstructor.h:78
HcalCaloFlagLabels::PresampleADC
Definition: HcalCaloFlagLabels.h:55
HcalHitReconstructor::dataOOTCorrectionName_
std::string dataOOTCorrectionName_
Definition: HcalHitReconstructor.h:100
HcalHF_PETalgorithm
Definition: HcalHF_PETalgorithm.h:21
HcalFlagHFDigiTimeParam::HFdigiflagMinEThreshold
double HFdigiflagMinEThreshold() const
Definition: HcalFlagHFDigiTimeParam.h:61
HcalSimpleRecAlgo::endRun
void endRun()
Definition: HcalSimpleRecAlgo.cc:41
ConsumesCollector.h
funct::abs
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
HcalRecoParam::pileupCleaningID
constexpr unsigned int pileupCleaningID() const
Definition: HcalRecoParam.h:43
edm::Event
Definition: Event.h:73
HcalSimpleRecAlgo::reconstruct
HFRecHit reconstruct(const HFDataFrame &digi, int first, int toadd, const HcalCoder &coder, const HcalCalibrations &calibs) const
Definition: HcalSimpleRecAlgo.cc:380
edm::Log
Definition: MessageLogger.h:70
EDCollection.h
HcalFrontEndMapRcd.h
HcalRecoParam::correctForTimeslew
constexpr bool correctForTimeslew() const
Definition: HcalRecoParam.h:37
HFTimingTrustFlag::setHFTimingTrustFlag
void setHFTimingTrustFlag(HFRecHit &rechit, const HFDataFrame &digi)
Definition: HFTimingTrustFlag.cc:129
geometryCSVtoXML.xx
xx
Definition: geometryCSVtoXML.py:19
HcalHitReconstructor::tok_hf_
edm::EDGetTokenT< HFDigiCollection > tok_hf_
Definition: HcalHitReconstructor.h:75
MillePedeFileConverter_cfg.e
e
Definition: MillePedeFileConverter_cfg.py:37
HcalHitReconstructor::mcOOTCorrectionCategory_
std::string mcOOTCorrectionCategory_
Definition: HcalHitReconstructor.h:103