ATLAS Offline Software
CaloCluster.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 /********************************************************************
6 
7 NAME: CaloCluster.cxx
8 PACKAGE: offline/Calorimeter/CaloRec
9 
10 AUTHORS: H. Ma
11 CREATED: Apr 2001
12 
13 PURPOSE: Cluster base class.
14  Implements CaloCluster methods
15 
16 Updated: Redesign. May 21, 2001
17  CaloCluster is a concrete class
18 
19 Updated: Redesign. Feb 17, 2004 P Loch
20  Complete overhaul to accommodate navigation and 4-vector interfaces.
21 
22 Updated: Aug, 2004 sss
23  Fix phi range problem and a potential division by zero.
24 
25 Updated: 30 Jun, 2005 S.Menke
26  updateKine uses |E| instead of E for the position calculation
27  and updates all data members now
28 
29 ********************************************************************/
30 
31 // basics
32 #include "CaloEvent/CaloCluster.h"
33 #include "CaloEvent/CaloCell.h"
35 
36 // cell links
39 
40 // data store
41 #include "CaloEvent/CaloShower.h"
44 
45 // kinematics
47 
48 // data helpers
50 #include "CaloEvent/CaloPrefetch.h"
51 #include "CaloGeoHelpers/proxim.h"
52 
53 // calculators
56 
57 #include "CxxUtils/prefetch.h"
58 #include <vector>
59 #include <algorithm>
60 //#include <iostream>
61 
62 const double CaloCluster::m_errorValue = -999.;
63 
65 // Constructor //
67 /*
68  *
69  * \param eta0 \f$ \eta \f$ of cluster seed, optional
70  * \param phi0 \f$ \varphi \f$ of cluster seed, optional
71  *
72  */
73 CaloCluster::CaloCluster(double eta0 /*= 0*/, double phi0 /*= 0*/,
74  unsigned int varTypePattern,
75  unsigned int clusterSize)
78  m_dataStore(varTypePattern),
79  m_ownDataStore(false),
80  m_shower(nullptr),
81  m_basicSignal(0.),
82  m_time(0.),
83  m_samplingPattern(0),
84  m_barrel (false),
85  m_endcap (false),
86  m_clusterSize(clusterSize),
87  m_eta0 (eta0),
88  m_phi0 (phi0),
89  m_timeNorm(0.),
90  m_posNorm(0.),
91  m_posSamNorm(CaloSampling::Unknown,0.),
92  m_nBarrel(0),
93  m_nEndcap(0),
94  m_lockPattern(0x00000000),
95  m_rawE(0.),
96  m_rawEta(0.),
97  m_rawPhi(0.),
98  m_rawM(0.),
99  m_altE(0.),
100  m_altEta(0.),
101  m_altPhi(0.),
102  m_altM(0.)
103 {
105  m_badChannelData.clear();
106 }
107 
123  m_dataStore(pCluster->m_dataStore),
124  m_momentStore(pCluster->m_momentStore),
125  m_ownDataStore(true),
126  m_basicSignal(pCluster->m_basicSignal),
127  m_time(pCluster->m_time),
128  m_samplingPattern(pCluster->m_samplingPattern),
129  m_barrel(pCluster->m_barrel),
130  m_endcap(pCluster->m_endcap),
131  m_clusterSize(pCluster->m_clusterSize),
132  m_eta0(pCluster->m_eta0),
133  m_phi0(pCluster->m_phi0),
134  m_timeNorm(pCluster->m_timeNorm),
135  m_posNorm(pCluster->m_posNorm),
136  m_posSamNorm(pCluster->m_posSamNorm),
137  m_nBarrel(pCluster->m_nBarrel),
138  m_nEndcap(pCluster->m_nEndcap),
139  m_lockPattern(pCluster->m_lockPattern),
140  m_rawE(pCluster->m_rawE),
141  m_rawEta(pCluster->m_rawEta),
142  m_rawPhi(pCluster->m_rawPhi),
143  m_rawM(pCluster->m_rawM),
144  m_altE(pCluster->m_altE),
145  m_altEta(pCluster->m_altEta),
146  m_altPhi(pCluster->m_altPhi),
147  m_altM(pCluster->m_altM)
148 {
149  signalstate_t s = pCluster->m_defSigState;
150  if (!this->hasSignalState(s)) s = statename_t::CALIBRATED;
151  this->setDefaultSignalState(s);
152  this->setSignalState(s);
153  // deep copy external data
154  bool isExternalShowerThere = false;
155  if ( pCluster->m_dataLink.isValid()) {
156  if (*(pCluster->m_dataLink) != nullptr) isExternalShowerThere = true;
157  }
158  CaloShower* pData = isExternalShowerThere
159  ? new CaloShower(*(pCluster->m_dataLink)) : new CaloShower();
160  m_shower = pData;
161  CaloCellLink* pLink = pCluster->getCellLink() != nullptr ? new CaloCellLink(pCluster->getCellLink()) : new CaloCellLink();
162  this->setStores(pData,pLink,
164  P4EEtaPhiM::setE(pCluster->m_e);
165  P4EEtaPhiM::setEta(pCluster->m_eta);
166  P4EEtaPhiM::setPhi(pCluster->m_phi);
167  P4EEtaPhiM::setM(pCluster->m_m);
168  this->setRecoStatus(pCluster->getRecoStatus());
169  m_badChannelData.reserve(pCluster->m_badChannelData.size());
170  for (unsigned int i=0;i<pCluster->m_badChannelData.size();i++) {
172  }
173 }
174 
176  : I4Momentum(rCluster),
177  P4EEtaPhiMBase(rCluster),
178  INavigable(rCluster),
179  IAthenaBarCode(rCluster),
180  INavigable4Momentum(rCluster),
181  CaloCompositeKineBase(rCluster),
183  ISignalState(),
184  m_dataStore(rCluster.m_dataStore),
185  m_momentStore(rCluster.m_momentStore),
186  m_ownDataStore(true),
187  m_basicSignal(rCluster.m_basicSignal),
188  m_time(rCluster.m_time),
189  m_samplingPattern(rCluster.m_samplingPattern),
190  m_barrel(rCluster.m_barrel),
191  m_endcap(rCluster.m_endcap),
192  m_clusterSize(rCluster.m_clusterSize),
193  m_eta0(rCluster.m_eta0),
194  m_phi0(rCluster.m_phi0),
195  m_timeNorm(rCluster.m_posNorm),
196  m_posNorm(rCluster.m_posNorm),
197  m_posSamNorm(rCluster.m_posSamNorm),
198  m_nBarrel(rCluster.m_nBarrel),
199  m_nEndcap(rCluster.m_nEndcap),
200  m_lockPattern(rCluster.m_lockPattern),
201  m_rawE(rCluster.m_rawE),
202  m_rawEta(rCluster.m_rawEta),
203  m_rawPhi(rCluster.m_rawPhi),
204  m_rawM(rCluster.m_rawM),
205  m_altE(rCluster.m_altE),
206  m_altEta(rCluster.m_altEta),
207  m_altPhi(rCluster.m_altPhi),
208  m_altM(rCluster.m_altM)
209 {
210  signalstate_t s = rCluster.m_defSigState;
211  if (!this->hasSignalState(s)) s = statename_t::CALIBRATED;
212  this->setDefaultSignalState(s);
213  this->setSignalState(s);
214  // deep copy external data
215  bool isExternalShowerThere = false;
216  if ( rCluster.m_dataLink.isValid()) {
217  if (*(rCluster.m_dataLink) != nullptr) isExternalShowerThere = true;
218  }
219  CaloShower* pData = isExternalShowerThere
220  ? new CaloShower(*(rCluster.m_dataLink)) : new CaloShower();
221  m_shower = pData;
222  CaloCellLink* pLink = rCluster.getCellLink() != nullptr ? new CaloCellLink(rCluster.getCellLink()) : new CaloCellLink();
223  this->setStores(pData,pLink,
225  // energy etc may be corrected, so overwrite!
226  P4EEtaPhiM::setE(rCluster.m_e);
227  P4EEtaPhiM::setEta(rCluster.m_eta);
228  P4EEtaPhiM::setPhi(rCluster.m_phi);
229  P4EEtaPhiM::setM(rCluster.m_m);
230  this->setRecoStatus(rCluster.getRecoStatus());
231  m_badChannelData.reserve(rCluster.m_badChannelData.size());
232  for (unsigned int i=0;i<rCluster.m_badChannelData.size();i++) {
234  }
235 }
236 
238 // Destructor //
240 
249 {
250  //if ( m_ownDataStore && *m_dataLink != 0 ) delete *m_dataLink;
251  if ( m_ownDataStore && m_dataLink.isValid() ) delete *m_dataLink;
252 }
253 
254 
263 void CaloCluster::updateKine(const CaloCell* theCell, double weight)
264 {
265 
266  // update global kinematics
267  //
268  // for the update of the position the normalization is not a trival
269  // thing. The previous implementation used the sum of weighted
270  // energies as normalization. This leads to unphysical eta and phi
271  // values in case negative energies are added in. The new algorithm
272  // takes therefore |E| instead of E which gives the same eta and phi
273  // as before for the 2 cases where all cells are negative or all
274  // cells are positive. In the mixed case it will give the direction
275  // of activity in the calorimeter.
276 
277  if (!theCell->caloDDE()) return;
278 
279  double theEnergyNoWeight = theCell->e();
280  double theEnergy = weight * theEnergyNoWeight;
281  double cellEta = theCell->eta();
282  double cellPhi = theCell->phi();
283  // weight might be negative for removing cells
284  // therefore the AbsEnergy can be negative ...
285  double theAbsEnergy = weight * fabs(theEnergyNoWeight);
286  double thePhi = proxim(cellPhi,this->phi());
287  double theNewEta =
288  m_posNorm * this->eta() + theAbsEnergy * cellEta;
289  double theNewPhi = m_posNorm * this->phi() + theAbsEnergy * thePhi;
290  double theNewEnergy = this->e() + theEnergy;
291  m_posNorm += theAbsEnergy;
292 
293  if ( m_posNorm != 0. )
294  {
295  this->setEta(theNewEta/m_posNorm);
296  this->setPhi(CaloPhiRange::fix (theNewPhi/m_posNorm));
297  }
298  else
299  {
300  this->setEta(0);
301  this->setPhi(0);
302  }
303 
304  this->setE(theNewEnergy);
305 
306  // calculate the cluster time from cells which provide a time
307  // two modes are under discussion - either use an energy^2 weighted
308  // average (sigma_t ~ 1/E) or just the time of the leading cell
309  // for now the energy^2 weighted average is implemented ...
310 
311  // need sampling number already for time
312  CaloSampling::CaloSample sam = theCell->caloDDE()->getSampling();
313  // unknown sampling
314  if ( sam == CaloSampling::Unknown ) return;
315 
316  unsigned pmask = 0;
317  if (sam != CaloSampling::PreSamplerB &&
319  {
320  if ( theCell->caloDDE()->is_tile() )
321  pmask = 0x8080;
322  else
323  pmask = 0x2000;
324  }
325 
326  // Is time defined?
327  if ( theCell->provenance() & pmask ) {
328  // keep the sign of weight for the time norm in case a cell is removed
329  double theTimeNorm = fabs(weight) * theEnergy * theEnergyNoWeight;
330 
331  double theNewTime = m_timeNorm * this->getTime()
332  + theTimeNorm * theCell->time();
333 
334  m_timeNorm += theTimeNorm;
335 
336  if ( m_timeNorm != 0. )
337  {
338  this->setTime(theNewTime/m_timeNorm);
339  }
340  else
341  {
342  this->setTime(0);
343  }
344  }
345 
347  // Check Sampling Variable Updates //
349 
350  // no update required
351  if ( this->allLocked() ) return;
352 
353  // update sampling quantities
354 
355  // This has gotten a bit more involved. To handle the stores for the
356  // data correctly, a pointer to each store (can be different for each
357  // variable type) has to be retrieved first (internal function). As all
358  // variables need the sampling energy, we start with this store. Note that
359  // the store for each variable can be defined by calling the corresponding
360  // set method before the first \a updateKine invocation.
361 
363  // Energy in Sampling //
365 
367  if ( ! this->isLocked(typeE) )
368  {
369  CaloSamplingData* pEStore = this->getDataStore(typeE,true);
370  if ( pEStore != nullptr )
371  {
372  // note that this is a reference to a modifiable data word!
373  pEStore->retrieveData(typeE,sam) += theEnergy;
374  }
375  }
376 
377  double theOldNorm(m_posSamNorm[sam]);
378  m_posSamNorm[sam]+=theAbsEnergy;
379  double theNewNorm(m_posSamNorm[sam]);
380 
382  // Azimuth //
384 
385  // azimuth
387  if ( ! this->isLocked(typePhi) )
388  {
389  // central azimuth
390  CaloSamplingData* pPhiStore = this->getDataStore(typePhi,true);
391  if ( pPhiStore != nullptr )
392  {
393  double& refPhiSamp = pPhiStore->retrieveData(typePhi,sam);
394  thePhi = proxim(cellPhi,refPhiSamp);
395  theNewPhi = theNewNorm != 0.
396  ? CaloPhiRange::fix((theOldNorm*refPhiSamp+theAbsEnergy*thePhi)/theNewNorm)
397  : double(0);
398 
399  // spread in azimuth
402  if ( ! this->isLocked(typeDPhi) )
403  {
404  CaloSamplingData* pDPhiStore = this->getDataStore(typeDPhi,true);
405  if ( pDPhiStore != nullptr )
406  {
407  // non-const reference -> modification in place!
408  double& refDPhiSamp = pDPhiStore->retrieveData(typeDPhi,sam);
409  double wP2
410  = theOldNorm *
411  ( refDPhiSamp*refDPhiSamp + refPhiSamp*refPhiSamp)
412  + theAbsEnergy * thePhi * thePhi;
413  refDPhiSamp = theNewNorm != 0.
414  ? wP2 / theNewNorm - theNewPhi*theNewPhi
415  : double(0);
416  if ( refDPhiSamp > 0. )
417  {
418  refDPhiSamp = sqrt(refDPhiSamp);
419  }
420  else
421  {
422  refDPhiSamp = double(0);
423  }
424  }
425  }
426  // save the new phi value
427  refPhiSamp = theNewPhi;
428  }
429  }
430 
432  // Rapidity //
434 
435 
436  // rapidity
438  if ( ! this->isLocked(typeEta) )
439  {
440  CaloSamplingData* pEtaStore = this->getDataStore(typeEta,true);
441  if ( pEtaStore != nullptr )
442  {
443  double& refEtaSamp = pEtaStore->retrieveData(typeEta,sam);
444  double theNewEta = theNewNorm != 0.
445  ? (theOldNorm*refEtaSamp+theAbsEnergy* cellEta)/theNewNorm
446  : double(0);
447 
448  // spread in eta
451  if ( ! this->isLocked(typeDEta) )
452  {
453  CaloSamplingData* pDEtaStore = this->getDataStore(typeDEta,true);
454  if ( pDEtaStore != nullptr )
455  {
456  double& refDEtaSamp = pDEtaStore->retrieveData(typeDEta,sam);
457  double wE2 = theOldNorm * (refDEtaSamp * refDEtaSamp +
458  refEtaSamp * refEtaSamp )
459  + theAbsEnergy * cellEta * cellEta;
460  refDEtaSamp = theNewNorm != 0
461  ? wE2 / theNewNorm - theNewEta * theNewEta
462  : double(0);
463  if ( refDEtaSamp > 0. )
464  {
465  refDEtaSamp = sqrt(refDEtaSamp);
466  }
467  else
468  {
469  refDEtaSamp = double(0.0);
470  }
471  }
472  }
473  // save the new eta value
474  refEtaSamp = theNewEta;
475  }
476  }
477 
479  // Maximum Energy Cell //
481 
483  if ( ! this->isLocked(typeEMax) )
484  {
485  CaloSamplingData* pEMaxStore = this->getDataStore(typeEMax,true);
486  if ( pEMaxStore != nullptr )
487  {
488  double& refEMaxSamp = pEMaxStore->retrieveData(typeEMax,sam);
489  if ( refEMaxSamp < theEnergy )
490  {
491  // set new maximum energy
492  refEMaxSamp = theEnergy;
493  // set new eta
494  CaloVariableType::VariableType typeEtaMax =
496  if ( ! this->isLocked(typeEtaMax) )
497  {
498  CaloSamplingData* pEtaMaxStore =
499  this->getDataStore(typeEtaMax,true);
500  if ( pEtaMaxStore != nullptr )
501  {
502  pEtaMaxStore->retrieveData(typeEtaMax,sam) =
503  cellEta;
504  }
505  }
506  // set new phi
507  CaloVariableType::VariableType typePhiMax =
509  if ( ! this->isLocked(typePhiMax) )
510  {
511  CaloSamplingData* pPhiMaxStore =
512  this->getDataStore(typePhiMax,true);
513  if ( pPhiMaxStore != nullptr )
514  {
515  pPhiMaxStore->retrieveData(typePhiMax,sam) = thePhi;
516  }
517  } // lock on phi of maximum sampling signal
518  } // maximum condition
519  } // data store pointer
520  } // lock on max energy
521 
522  if ( theEnergy != 0)
523  {
524  // check sampling bit
527  // count cells in endcap
528 
529  switch(sam)
530  {
532  case CaloSampling::EME1:
533  case CaloSampling::EME2:
534  case CaloSampling::EME3:
535  case CaloSampling::HEC0:
536  case CaloSampling::HEC1:
537  case CaloSampling::HEC2:
538  case CaloSampling::HEC3:
539  case CaloSampling::FCAL0:
540  case CaloSampling::FCAL1:
541  case CaloSampling::FCAL2:
542  m_nEndcap += (weight<0?-1:1);
543  break;
544  default:
545  m_nBarrel += (weight<0?-1:1);
546  break;
547  }
548  }
549 
550  if ( m_nBarrel < 0 ) m_nBarrel = 0;
551  if ( m_nEndcap < 0 ) m_nEndcap = 0;
552 
553  m_barrel = (m_nBarrel>0);
554  m_endcap = (m_nEndcap>0);
555 }
556 
557 
558 namespace {
559 
560 
561 // This is factored out in order to allow instantiating the cell loop
562 // in versions that both use and do not use cell weights. In the no-weights
563 // case, the weight is a compile-time constant of 1, so all operations
564 // involving it will be optimized away.
565 
566 
567 struct CellAccum
568 {
569  CellAccum (double& the_posNorm,
570  std::vector<double>& the_posSamNorm,
571  int& the_nBarrel,
572  int& the_nEndcap,
573  double& the_timeNorm)
574  : EnergyInSample(),
575  EtaInSample(),
576  PhiInSample(),
577  MaxEnergyInSample(),
578  EtaMaxEnergyInSample(),
579  PhiMaxEnergyInSample(),
580  PresenceInSample(),
581  theNewEnergy(0),
582  theNewTime(0),
583  theNewEta(0),
584  theNewPhi(0),
585  phi0(-999),
586  posNorm (the_posNorm),
587  posSamNorm (the_posSamNorm),
588  nBarrel (the_nBarrel),
589  nEndcap (the_nEndcap),
590  timeNorm (the_timeNorm)
591  {}
592  double EnergyInSample[CaloSampling::Unknown];
593  double EtaInSample[CaloSampling::Unknown];
594  double PhiInSample[CaloSampling::Unknown];
595  double MaxEnergyInSample[CaloSampling::Unknown];
596  double EtaMaxEnergyInSample[CaloSampling::Unknown];
597  double PhiMaxEnergyInSample[CaloSampling::Unknown];
598  bool PresenceInSample[CaloSampling::Unknown];
599  double theNewEnergy;
600  double theNewTime;
601  double theNewEta;
602  double theNewPhi;
603  double phi0;
604 
605  double& posNorm;
606  std::vector<double>& posSamNorm;
607  int& nBarrel;
608  int& nEndcap;
609  double& timeNorm;
610 };
611 
612 
613 struct AccumWeight
614 {
615  AccumWeight (const CaloCluster& cl) : m_cl (cl) {}
616 
617  double operator() (const CaloCell& cell) const
618  {
619  return m_cl.getCellWeight (&cell);
620  }
621 
622  const CaloCluster& m_cl;
623 };
624 
625 
626 struct AccumNoWeight
627 {
628  double operator() (const CaloCell&) const { return 1; }
629 };
630 
631 
632 template <class WEIGHT>
633 inline
634 void accumCell (const CaloCell& cell, CellAccum& accum, const WEIGHT& w)
635 {
636  const CaloDetDescrElement* dde = cell.caloDDE();
637  if (!dde) return;
638  double weight = w (cell);
639  double fabsweight = fabs (weight);
640 
641  double theEnergyNoWeight = cell.e();
642  double theEnergy = weight * theEnergyNoWeight;
643  // weight might be negative for removing cells
644  // therefore the AbsEnergy can be negative ...
645  double theAbsEnergy = weight * fabs(theEnergyNoWeight);
646 
648  accum.PresenceInSample[sam] = true;
649  double cellEta = dde->eta();
650  double cellPhi = dde->phi();
651 
652  accum.EnergyInSample[sam] += theEnergy;
653  accum.theNewEnergy += theEnergy;
654  double thePhi;
655  if (accum.phi0 < -900) {
656  thePhi = accum.phi0 = cellPhi;
657  }
658  else
659  thePhi = proxim (cellPhi, accum.phi0);
660 
661  accum.theNewEta += theAbsEnergy * cellEta;
662  accum.theNewPhi += theAbsEnergy * thePhi;
663  if ( accum.MaxEnergyInSample[sam] < theEnergy ) {
664  accum.MaxEnergyInSample[sam] = theEnergy;
665  accum.EtaMaxEnergyInSample[sam] = cellEta;
666  accum.PhiMaxEnergyInSample[sam] = cellPhi;
667  }
668 
669  accum.posSamNorm[sam] += theAbsEnergy;
670  accum.posNorm += theAbsEnergy;
671 
672  accum.EtaInSample[sam] += theAbsEnergy * cellEta;
673  accum.PhiInSample[sam] += theAbsEnergy * thePhi;
674 
675  if ( theEnergy != 0)
676  {
677  // count cells in endcap
678  switch(sam)
679  {
681  case CaloSampling::EME1:
682  case CaloSampling::EME2:
683  case CaloSampling::EME3:
684  case CaloSampling::HEC0:
685  case CaloSampling::HEC1:
686  case CaloSampling::HEC2:
687  case CaloSampling::HEC3:
688  case CaloSampling::FCAL0:
689  case CaloSampling::FCAL1:
690  case CaloSampling::FCAL2:
691  accum.nEndcap += (weight<0?-1:1);
692  break;
693  case CaloSampling::EMB1:
694  case CaloSampling::EMB2:
695  default:
696  accum.nBarrel += (weight<0?-1:1);
697  break;
698  }
699 
700  if (sam != CaloSampling::PreSamplerB &&
702  {
703  unsigned int pmask = dde->is_tile() ? 0x8080 : 0x2000;
704 
705  // Is time defined?
706  if ( cell.provenance() & pmask ) {
707  // keep the sign of weight for the time norm in case a cell is removed
708  double theTimeNorm = fabsweight * theEnergy * theEnergyNoWeight;
709  accum.theNewTime += theTimeNorm * cell.time();
710  accum.timeNorm += theTimeNorm;
711  }
712  }
713  }
714 }
715 
716 
717 template <class WEIGHT>
718 inline
719 void accumCells (CaloCluster& cl, CellAccum& accum, const WEIGHT& w)
720 {
721  for (const CaloCell* c : cl)
723 
724  CaloCluster::cell_iterator it = cl.begin();
726  for (; it != end; ++it) {
728  accumCell (**it, accum, w);
729  }
730 }
731 
732 
733 } // anonymous namespace
734 
735 
736 void CaloCluster::calculateKine(const bool useweight,const bool updateLayers)
737 {
738  //static CaloPhiRange range;
739 
740  // update global kinematics
741  //
742  // for the update of the position the normalization is not a trival
743  // thing. The previous implementation used the sum of weighted
744  // energies as normalization. This leads to unphysical eta and phi
745  // values in case negative energies are added in. The new algorithm
746  // takes therefore |E| instead of E which gives the same eta and phi
747  // as before for the 2 cases where all cells are negative or all
748  // cells are positive. In the mixed case it will give the direction
749  // of activity in the calorimeter.
750 
751  m_posNorm = 0;
752  m_nBarrel = 0;
753  m_nEndcap = 0;
754  m_timeNorm = 0.;
755 
756  std::fill (m_posSamNorm.begin(), m_posSamNorm.end(), 0);
757 
758  CellAccum accum (m_posNorm, m_posSamNorm, m_nBarrel, m_nEndcap, m_timeNorm);
759  accum.theNewPhi = this->phi();
760  if (useweight)
761  accumCells (*this, accum, AccumWeight(this));
762  else
763  accumCells (*this, accum, AccumNoWeight());
764 
765  if ( m_posNorm != 0. )
766  {
767  double inorm = 1 / m_posNorm;
768  this->setEta(accum.theNewEta * inorm);
769  this->setPhi(CaloPhiRange::fix(accum.theNewPhi * inorm));
770  }
771  else
772  {
773  this->setEta(0);
774  this->setPhi(0);
775  }
776 
777  this->setE(accum.theNewEnergy);
778 
779  if ( m_timeNorm != 0. )
780  this->setTime(accum.theNewTime/m_timeNorm);
781  else
782  this->setTime(0);
783 
784 
786  // Check Sampling Variable Updates //
788 
789  if ( !updateLayers ) return;
790  if ( this->allLocked() ) return;
791  // update sampling quantities
792 
793  for(int i=0;i<(int)CaloSampling::Unknown;i++) {
794  if ( !accum.PresenceInSample[i] ) continue;
795  // check sampling bit
798  if ( m_posSamNorm[i] != 0 ) {
799  double inorm = 1 / m_posSamNorm[i];
800  accum.EtaInSample[i] *= inorm;
801  accum.PhiInSample[i] = CaloPhiRange::fix (accum.PhiInSample[i] * inorm);
802  }
803  }
804 
805 #define SETVAR(v, a) maybeSetVariable(v, a, (a)+sizeof(a)/sizeof((a)[0]))
806  SETVAR (CaloVariableType::ENERGY, accum.EnergyInSample);
807  SETVAR (CaloVariableType::ETA, accum.EtaInSample);
808  SETVAR (CaloVariableType::PHI, accum.PhiInSample);
809  SETVAR (CaloVariableType::MAX_ENERGY, accum.MaxEnergyInSample);
810  SETVAR (CaloVariableType::MAX_ETA, accum.EtaMaxEnergyInSample);
811  SETVAR (CaloVariableType::MAX_PHI, accum.PhiMaxEnergyInSample);
812 #undef SETVAR
813 
814  if ( m_nBarrel < 0 ) m_nBarrel = 0;
815  if ( m_nEndcap < 0 ) m_nEndcap = 0;
816 
817  m_barrel = (m_nBarrel>0);
818  m_endcap = (m_nEndcap>0);
819 }
820 
822 // Basic Data Management //
824 
836 double
838  const sampling_type& samType,
839  bool useLink ) const
840 {
841  const CaloSamplingData* pDataStore = this->getDataStore(varType,useLink);
842  return pDataStore != nullptr
843  ? pDataStore->retrieveData(varType,samType)
844  : double(0);
845 }
846 
856 bool
858  std::vector<double>& varList,
859  bool useLink) const
860 {
861  const CaloSamplingData* pDataStore = this->getDataStore(varType,useLink);
862  return pDataStore != nullptr ? pDataStore->retrieveData(varType,varList) : false;
863 }
864 
871 bool
873  const sampling_type& samType,
874  const double& varData,
875  bool useLink)
876 {
877  // check samplingpattern
878  if(!this->hasSampling(samType)){
879  // std::cout << " Cluster does not have sampling " << samType << std::endl;
882  }
883 
884  // allocate modifiable data store
885  CaloSamplingData* pDataStore = this->getDataStore(varType,useLink);
886  return pDataStore != nullptr
887  ? pDataStore->storeData(varType,samType,varData)
888  : false;
889 }
890 
891 bool
893  const std::vector<double>& varList,
894  bool useLink)
895 {
896  CaloSamplingData* pDataStore = this->getDataStore(varType,useLink);
897  return pDataStore != nullptr
898  ? pDataStore->storeData(varType,varList)
899  : false;
900 }
901 
903 // Retrieve and Set Sampling Variables //
905 
906 // most methods are inlined!
907 void
909 {
910  if ( this->isEMSampling(sampling) )
911  this->setVariable(CaloVariableType::MAX_ENERGY,sampling,m,true);
912 }
913 
914 void CaloCluster::setetamax(sampling_type sampling, double m)
915 {
916  if ( this->isEMSampling(sampling) )
917  this->setVariable(CaloVariableType::MAX_ETA,sampling,m,true);
918 }
919 
920 void CaloCluster::setphimax(sampling_type sampling, double m)
921 {
922  if ( this->isEMSampling(sampling) )
923  this->setVariable(CaloVariableType::MAX_PHI,sampling,m,true);
924 }
925 
931 {
932  if ( this->isEMSampling(sampling) )
933  this->setVariable(CaloVariableType::DELTA_ETA,sampling,size,true);
934 }
935 
941 {
942  if ( this->isEMSampling(sampling) )
943  this->setVariable(CaloVariableType::DELTA_PHI,sampling,size,true);
944 }
952 double
954  const int& sam) const
955 {
956  // check input
957  unsigned int iSamp((unsigned int)sam);
958  if ( iSamp > 3 ) return m_errorValue;
959 
960  // barrel and endcap
961  if ( this->inBarrel() && this->inEndcap() )
962  {
963  // offsets for sampling indicators
964  unsigned int bOff = (unsigned int)CaloSampling::PreSamplerB;
965  unsigned int eOff = (unsigned int)CaloSampling::PreSamplerE;
966  CaloSampling::CaloSample bSample =
967  (CaloSampling::CaloSample)(bOff+iSamp);
969  (CaloSampling::CaloSample)(eOff+iSamp);
970  double eBarrel = this->getVariable(CaloVariableType::ENERGY,
971  bSample,true);
972  double eEndCap = this->getVariable(CaloVariableType::ENERGY,
973  eSample,true);
974 
975  double vBarrel = this->getVariable(varType,bSample,true);
976  double vEndCap = this->getVariable(varType,eSample,true);
977 
978  // Deal with invalid eta/phi values.
979  if (varType == CaloVariableType::PHI ||
980  varType == CaloVariableType::ETA)
981  {
982  if (vBarrel <= m_errorValue) {
983  vBarrel = 0;
984  eBarrel = 0;
985  }
986  if (vEndCap <= m_errorValue) {
987  vEndCap = 0;
988  eEndCap = 0;
989  }
990  }
991 
992  // invalid signals
993  double eSum = eBarrel + eEndCap;
994  if ( eSum == 0. ) return m_errorValue;
995  // average
996  double vAverage(m_errorValue);
997  switch ( varType )
998  {
1000  {
1001  double phiSum =
1002  eSum * vBarrel + eEndCap * CaloPhiRange::diff(vEndCap,vBarrel);
1003  vAverage = CaloPhiRange::fix(phiSum/eSum);
1004  break;
1005  }
1006  case CaloVariableType::ETA:
1007  {
1008  vAverage = ( eBarrel * vBarrel + eEndCap * vEndCap ) / eSum;
1009  break;
1010  }
1012  {
1013  vAverage = eSum;
1014  break;
1015  }
1016  default:
1017  {
1018  break;
1019  }
1020  }
1021  return vAverage;
1022  }
1023 
1024  // barrel only
1025  if ( this->inBarrel() )
1026  {
1027  unsigned int bOff = (unsigned int)CaloSampling::PreSamplerB;
1028  CaloSampling::CaloSample bSample =
1029  (CaloSampling::CaloSample)(bOff+iSamp);
1030  return this->getVariable(varType,bSample);
1031  }
1032 
1033  // endcap only
1034  if ( this->inEndcap() )
1035  {
1036  unsigned int eOff = (unsigned int)CaloSampling::PreSamplerE;
1038  (CaloSampling::CaloSample)(eOff+iSamp);
1039  return this->getVariable(varType,eSample);
1040  }
1041 
1042  // just in case
1043  return m_errorValue;
1044 }
1045 
1055 const CaloSamplingData*
1056 CaloCluster::getDataStore(const variable_type& varType,bool traceLink) const
1057 {
1058  //
1059  //DEBUGstd::cout << "[CaloCluster@" << this
1060  //DEBUG << "]::getDataStore - const data store pointer requested, "
1061  //DEBUG << "try internal pointer = " << &m_dataStore;
1062 
1063  // check if variable in local data store
1064  if ( m_dataStore.contains(varType) )
1065  {
1066  // std::cout << "...successful!" << std::endl;
1067  return &m_dataStore;
1068  }
1069 
1070  // check linked data store if requested
1071  if ( traceLink && m_dataLink.isValid())
1072  {
1073  //DEBUG std::cout << "... unsuccessful, use linked pointer "
1074  //DEBUG << &((*m_dataLink)->getSamplingStore()) << std::endl;
1075  return &((*m_dataLink)->getSamplingStore());
1076  }
1077 
1078  //DEBUGstd::cout << "... failed, no external or internal pointer available!"
1079  //DEBUG << std::endl;
1080  return (const CaloSamplingData*)nullptr;
1081 }
1082 
1093 CaloCluster::getDataStore(const variable_type& varType,bool traceLink)
1094 {
1095  if ( m_dataStore.contains(varType) )
1096  {
1097  return &m_dataStore;
1098  }
1099 
1100  // check external store if requested
1101  if ( m_ownDataStore && !m_dataLink.isValid()) {
1102  m_shower = new CaloShower();
1103  m_dataLink.setElement(m_shower);
1104  }
1105 
1106  // trace
1107  if ( ( traceLink || m_ownDataStore ) && m_shower )
1108  {
1109  return &(m_shower->getSamplingStore());
1110  }
1111 
1112  return (CaloSamplingData*)nullptr;
1113 }
1114 
1116 // Moments //
1118 
1120 {
1121  moment_iterator iMom;
1122  // get store pointers
1123  const CaloClusterMomentStore* pFirstMomStore = nullptr;
1124  const CaloClusterMomentStore* pSecndMomStore = nullptr;
1125  // try to return valid iterator to first data object...
1126  if ( this->getMomentStorePtrs(pFirstMomStore,pSecndMomStore,
1127  useLink) ) //DEBUG,"begin") )
1128  {
1129  iMom = moment_iterator(pFirstMomStore->begin(),pFirstMomStore,
1130  pSecndMomStore);
1131  }
1132  else
1133  {
1134  iMom = moment_iterator();
1135  }
1136 
1137  return iMom;
1138 }
1139 
1140 
1142 {
1143  const CaloClusterMomentStore* pFirstMomStore = nullptr;
1144  const CaloClusterMomentStore* pSecndMomStore = nullptr;
1145  if ( this->getMomentStorePtrs(pFirstMomStore,pSecndMomStore,useLink) )
1146  //DEBUG,"end") )
1147  {
1149  pSecndMomStore != nullptr && pSecndMomStore->size() > 0
1150  ? pSecndMomStore->end()
1151  : pFirstMomStore->end();
1152  return moment_iterator(lMom,pFirstMomStore,pSecndMomStore);
1153  }
1154  else
1155  {
1156  return {};
1157  }
1158 }
1159 
1161 {
1162  // follow link policy
1163  if ( !useLink ) return &m_momentStore;
1164 
1165  // check on external link usage
1166  if ( ( m_dataLink.isValid() || m_ownDataStore ) && m_dataLink.isValid() )
1167  return &((*m_dataLink)->getMomentStore());
1168 
1169  return (const CaloClusterMomentStore*)nullptr;
1170 }
1171 
1173 {
1174  // follow link policy: do not use link!
1175  if ( !useLink ) return &m_momentStore;
1176 
1177  // follow link policy: use link!
1178  if ( m_ownDataStore && m_dataLink.isValid() == 0 )
1179  {
1180  m_shower = new CaloShower();
1181  m_dataLink.setElement(m_shower);
1182  return this->getMomentStore(useLink);
1183  }
1184 
1185  if ( m_shower || m_ownDataStore )
1186  {
1187  return &(m_shower->getMomentStore());
1188  }
1189  return (CaloClusterMomentStore*)nullptr;
1190 }
1191 
1193  bool useLink)
1194 {
1195  // this is the "write" implementation!
1196  return m_momentStore.contains(momType)
1197  ? &m_momentStore // moment already in local store
1198  : this->getMomentStore(useLink); // retrieve local or external
1199 }
1200 
1202 CaloCluster::getMomentStore(const moment_type& momType, bool useLink) const
1203 {
1204  // local store
1205  if ( m_momentStore.contains(momType) ) return &m_momentStore;
1206 
1207  // external store
1208  const CaloClusterMomentStore* pMomStore = this->getMomentStore(useLink);
1209 
1210  //
1211  return pMomStore != nullptr && pMomStore->contains(momType)
1212  ? pMomStore : (const CaloClusterMomentStore*) nullptr;
1213 }
1214 
1215 bool
1217  pFirstMomStore,
1218  const CaloClusterMomentStore*&
1219  pSecndMomStore,
1220  bool useLink) const
1221 // const std::string& mode) const
1222 {
1223  // first store is assumed local by default
1224  pFirstMomStore = this->getMomentStore();
1225  // second store is assumed NOT to exist by default
1226  pSecndMomStore = nullptr;
1227  // local first store does not exist or is empty...
1228  if ( pFirstMomStore == nullptr || pFirstMomStore->size() == 0 )
1229  {
1230  // ...try to make external store the first one!
1231  pFirstMomStore = this->getMomentStore(useLink);
1232  }
1233  // local first store exists...
1234  else
1235  {
1236  // ...check if second store available!
1237  pSecndMomStore = useLink ? this->getMomentStore(useLink) : nullptr;
1238  }
1239  return pFirstMomStore != nullptr;
1240 }
1241 
1248  const moment_value& momData,
1249  bool useLink)
1250 {
1251  // use momType for getMomentStore to override useLink in case
1252  // the moment has already been stored and should just be updated ...
1253  CaloClusterMomentStore* pMomStore = this->getMomentStore(momType,useLink);
1254  if ( pMomStore != nullptr ) pMomStore->insert(momType,momData);
1255 }
1265 bool
1267  moment_value& momData,
1268  bool useLink) const
1269 {
1270  const CaloClusterMomentStore* pMomStore = this->getMomentStore(momType,
1271  useLink);
1272  return pMomStore != nullptr
1273  ? pMomStore->retrieve(momType,momData)
1274  : false;
1275 }
1276 
1277 bool
1279  double& momValue,
1280  bool useLink) const
1281 {
1282  CaloClusterMoment momData(0);
1283  if ( this->retrieveMoment(momType,momData,useLink) )
1284  {
1285  momValue = momData.getValue();
1286  return true;
1287  }
1288  return false;
1289 }
1290 
1291 
1292 // lock variable
1294 {
1295  unsigned int bitPattern(CaloVariableType::getVariableBit(varType));
1296  m_lockPattern = ( m_lockPattern | bitPattern );
1297  return this->isLocked(bitPattern);
1298 }
1299 
1300 // unlock variable
1302 {
1303  unsigned int bitPattern(CaloVariableType::getVariableBit(varType));
1304  if ( this->isLocked(bitPattern) )
1305  {
1306  m_lockPattern = m_lockPattern ^ bitPattern;
1307  return ! this->isLocked(bitPattern);
1308  }
1309  else
1310  {
1311  return false;
1312  }
1313 }
1314 
1315 double CaloCluster::getRawE() const { return m_rawE; }
1316 double CaloCluster::getRawEta() const { return m_rawEta; }
1317 double CaloCluster::getRawPhi() const { return m_rawPhi; }
1318 double CaloCluster::getRawM() const { return m_rawM; }
1319 
1320 void CaloCluster::setRawE(double e) { m_rawE = e; }
1323 void CaloCluster::setRawM(double m) { m_rawM = m; }
1324 
1325 double CaloCluster::getAltE() const { return m_altE; }
1326 double CaloCluster::getAltEta() const { return m_altEta; }
1327 double CaloCluster::getAltPhi() const { return m_altPhi; }
1328 double CaloCluster::getAltM() const { return m_altM; }
1329 
1330 void CaloCluster::setAltE(double e) { m_altE = e; }
1333 void CaloCluster::setAltM(double m) { m_altM = m; }
1334 
1335 double CaloCluster::getCalE() const { return P4EEtaPhiM::e(); }
1336 double CaloCluster::getCalEta() const { return P4EEtaPhiM::eta(); }
1337 double CaloCluster::getCalPhi() const { return P4EEtaPhiM::phi(); }
1338 double CaloCluster::getCalM() const { return P4EEtaPhiM::m(); }
1339 
1344 
1346 {
1347  if ( !this->hasSignalState(s) ) return false;
1348 
1349  m_signalState = s;
1350 
1351  return
1352  s == statename_t::CALIBRATED ? this->setStateCal() :
1353  s == statename_t::ALTCALIBRATED ? this->setStateAlt() :
1354  s == statename_t::UNCALIBRATED ? this->setStateRaw() :
1355  false;
1356 }
1357 
1359 {
1360  return s == statename_t::CALIBRATED ||
1363 }
1364 
1366 {
1367  return s == m_signalState;
1368 }
1369 
1371 {
1373 }
1374 
1376 {
1377  // std::cout << "CaloCluster [" << this
1378  // << "] setStateRaw()" << std::endl;
1383  //
1388  //
1389  return true;
1390 }
1391 
1393 {
1394  // std::cout << "CaloCluster [" << this
1395  // << "] setStateAlt()" << std::endl;
1400  //
1405  return true;
1406 }
1407 
1409 {
1410  // std::cout << "CaloCluster [" << this
1411  // << "] setStateCal()" << std::endl;
1416  //
1421  return true;
1422 }
1423 
1425 {
1426  m_badChannelData.push_back(badChannel);
1427 }
1428 
1430 {
1431  m_badChannelData.clear();
1432 }
1433 
1435 {
1436  return &m_badChannelData;
1437 }
1438 
1439 unsigned int CaloCluster::getClusterEtaSize() const{
1440 
1441  unsigned int size = 0;
1442  if(m_clusterSize==SW_55ele ||
1445  size = 5;
1446  }else if(m_clusterSize==SW_35ele ||
1452  size = 3;
1453  }else if(m_clusterSize==SW_7_11){
1454  size = 7;
1455  }
1456 
1457  return size;
1458 
1459 }
1460 
1461 unsigned int CaloCluster::getClusterPhiSize() const{
1462 
1463  unsigned int size = 0;
1464  if(m_clusterSize==SW_55ele ||
1470  size = 5;
1471  }else if(
1475  size = 7;
1476  }else if(m_clusterSize==SW_7_11){
1477  size = 11;
1478  }
1479 
1480  return size;
1481 
1482 }
1483 
1484 CLHEP::HepLorentzVector
1486  if(hasSignalState(s)){
1487  switch (s) {
1488  case statename_t::CALIBRATED: {
1489  P4EEtaPhiM tmp = *this;
1490  return tmp.hlv();
1491  }
1494  return tmp.hlv();
1495  }
1498  return tmp.hlv();
1499  }
1500  default:
1501  break;
1502  }
1503  }
1504  return this->hlv();
1505 }
1506 
1507 unsigned int CaloCluster::samplingPattern() const
1508 {
1509  return m_samplingPattern;
1510 }
1511 
1512 
1513 // MomentStoreIter methods moved out-of-line to avoid a cling problem.
1514 // Symptom was that iteration over the moments would enter an infinte
1515 // loop in the ESD_18.0.0 test of CaloAthenaPool.
1516 
1518 CaloCluster::MomentStoreIter::MomentStoreIter() : m_iter(), m_firstStore(nullptr), m_secndStore(nullptr) { }
1521  const moment_store* firstStore,
1522  const moment_store* secndStore/*=0*/)
1523  : m_iter(iter), m_firstStore(firstStore), m_secndStore(secndStore)
1524 { }
1527 
1530 {
1531  m_iter++;
1532  if ( m_iter == m_firstStore->end() &&
1533  ( m_secndStore != nullptr && m_secndStore->size() > 0 ) )
1534  {
1535  m_iter = m_secndStore->begin();
1536  }
1537  return *this;
1538 }
1539 
1542 {
1543  if ( m_secndStore != nullptr && m_iter == m_secndStore->begin() )
1544  {
1545  m_iter = m_firstStore->end();
1546  }
1547  m_iter--;
1548  return *this;
1549 }
1550 
1559 
1562 { return m_iter == anOther.m_iter; }
1565 { return m_iter != anOther.m_iter; }
1566 
CaloCluster::isLocked
bool isLocked(const variable_type &varType) const
Check lock status of variable.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:1278
CaloCluster::m_ownDataStore
bool m_ownDataStore
}
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:485
CaloCluster::m_setPhi
SET_VALUE m_setPhi
Pointer to setter functions.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:685
AllowedVariables::e
e
Definition: AsgElectronSelectorTool.cxx:37
CaloCluster::SW_55ele
@ SW_55ele
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:87
GetLCDefs::Unknown
@ Unknown
Definition: GetLCDefs.h:21
CaloClusterMoment::MomentType
MomentType
enums to identify different moments
Definition: CaloClusterMoment.h:38
CaloCompositeKineBase::setRecoStatus
void setRecoStatus(const CaloRecoStatus &recStatus)
Set the reconstruction status.
Definition: CaloCompositeKineBase.h:82
CaloCluster::m_momentStore
CaloClusterMomentStore m_momentStore
cluster moments
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:480
CaloVariableType::VariableType
VariableType
Definition: CaloVariableType.h:15
I4Momentum
Definition: I4Momentum.h:31
CaloPrefetch.h
CaloCluster::eSample
double eSample(sampling_type sampling) const
Retrieve energy in a given sampling.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:975
CaloCluster::setTime
void setTime(double theTime)
Set cluster time.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:889
python.SystemOfUnits.s
int s
Definition: SystemOfUnits.py:131
CaloCluster::m_altPhi
double m_altPhi
Stores calibrated (cell weight) signal.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:709
CaloCell::phi
virtual double phi() const override final
get phi (through CaloDetDescrElement)
Definition: CaloCell.h:359
constants.EMB1
int EMB1
Definition: Calorimeter/CaloClusterCorrection/python/constants.py:53
python.SystemOfUnits.m
int m
Definition: SystemOfUnits.py:91
ReadCellNoiseFromCool.cell
cell
Definition: ReadCellNoiseFromCool.py:53
CaloCluster::resetSignalState
virtual void resetSignalState()
reset the signal state
Definition: CaloCluster.cxx:1370
CaloCluster::m_getM
GET_VALUE m_getM
Pointer to getter functions.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:678
CaloCluster::hasSampling
bool hasSampling(const sampling_type &theSampling) const
Checks if certain sampling contributes to cluster.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:954
CaloVariableType::MAX_ENERGY
@ MAX_ENERGY
Definition: CaloVariableType.h:20
CaloSamplingData::retrieveData
value_type retrieveData(variable_key_type theVariable, sampling_key_type theSampling) const
Retrieve const reference to individual variable.
Definition: CaloSamplingData.h:225
phi
Scalar phi() const
phi method
Definition: AmgMatrixBasePlugin.h:67
CaloCluster::setCalEta
void setCalEta(double eta)
Set calibrated (LC) eta.
Definition: CaloCluster.cxx:1341
P4EEtaPhiM::setEta
virtual void setEta(double theEta)
set eta data member
Definition: P4EEtaPhiM.h:117
CaloCluster::setetamax
void setetamax(sampling_type sampling, double m)
Set the of cell with maximum energy in a given sampling.
Definition: CaloCluster.cxx:914
CaloCluster::m_getPhi
GET_VALUE m_getPhi
Pointer to getter functions.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:676
CaloCluster::setRawEta
void setRawEta(double eta)
Set raw eta.
Definition: CaloCluster.cxx:1321
CaloVariableType::PHI
@ PHI
Definition: CaloVariableType.h:17
CaloCellPos2Ntuple.int
int
Definition: CaloCellPos2Ntuple.py:24
CaloClusterNavigable.h
CaloCluster::m_nEndcap
int m_nEndcap
Counter for number of endcap cells with non-zero weight and energy.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:579
CaloCluster::SW_35Econv
@ SW_35Econv
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:96
CaloCluster::CaloCluster
CaloCluster(double eta0=0, double phi0=0, unsigned int varTypePattern=0x00000000, unsigned int clusterSize=CaloCluster::SW_55ele)
Constructor.
Definition: CaloCluster.cxx:73
eta
Scalar eta() const
pseudorapidity method
Definition: AmgMatrixBasePlugin.h:83
ISignalState
Definition: ISignalState.h:42
CaloCompositeKineBase::getRecoStatus
const CaloRecoStatus & getRecoStatus() const
Retrieve the reconstruction status.
Definition: CaloCompositeKineBase.h:78
CaloCluster::getRawPhi
double getRawPhi() const
Access to raw phi.
Definition: CaloCluster.cxx:1317
CaloCluster::setCalE
void setCalE(double e)
Set calibrated (LC) energy.
Definition: CaloCluster.cxx:1340
CaloCluster::inBarrel
bool inBarrel() const
Returns true if at least one clustered cell in EMB.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:926
CaloSamplingData::storeData
bool storeData(variable_key_type theVariable, sampling_key_type theSampling, value_type theData)
}
Definition: CaloSamplingData.cxx:109
CaloCluster::setStateCal
bool setStateCal()
Helper to switch to calibrated (LC) state.
Definition: CaloCluster.cxx:1408
CaloCluster::MomentStoreIter
Internal cell iterator.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:155
InDetAccessor::phi0
@ phi0
Definition: InDetAccessor.h:33
CaloDetDescrElement
This class groups all DetDescr information related to a CaloCell. Provides a generic interface for al...
Definition: Calorimeter/CaloDetDescr/CaloDetDescr/CaloDetDescrElement.h:66
CaloCluster::setetasize
void setetasize(sampling_type sampling, double size)
Set the cluster size in for a given sampling.
Definition: CaloCluster.cxx:930
proxim
double proxim(double b, double a)
Definition: proxim.h:17
P4EEtaPhiM
Definition: P4EEtaPhiM.h:25
CaloCluster::SW_35gam
@ SW_35gam
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:92
CaloCluster::getDataStore
CaloSamplingData * getDataStore(const variable_type &theVariable, bool useLink=true)
Definition: CaloCluster.cxx:1093
skel.it
it
Definition: skel.GENtoEVGEN.py:396
CaloSampling
provides Calorimeter Sampling enum
Definition: Calorimeter/CaloGeoHelpers/CaloGeoHelpers/CaloSampling.h:17
CaloCluster::m_getEta
GET_VALUE m_getEta
Pointer to getter functions.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:674
CaloCell_ID_FCS::FCAL1
@ FCAL1
Definition: FastCaloSim_CaloCell_ID.h:41
CaloVariableType::DELTA_PHI
@ DELTA_PHI
Definition: CaloVariableType.h:19
P4EEtaPhiM::m_e
double m_e
Definition: P4EEtaPhiM.h:75
CaloCell.h
CaloCluster::setVariable
bool setVariable(const variable_type &varType, const sampling_type &samType, const double &varData, bool useLink=false)
General sampling variable setter.
Definition: CaloCluster.cxx:872
CaloCluster::getClusterPhiSize
unsigned int getClusterPhiSize() const
Definition: CaloCluster.cxx:1461
CaloCell::e
virtual double e() const override final
get energy (data member) (synonym to method energy()
Definition: CaloCell.h:317
CaloCluster::SW_37gam
@ SW_37gam
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:93
CaloCluster::m_altE
double m_altE
Stores calibrated (cell weight) signal.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:705
CaloCluster::m_timeNorm
double m_timeNorm
Stores the normalization for time calculation e.g.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:564
CaloCluster::setSignalState
virtual bool setSignalState(signalstate_t s)
Sets signal state.
Definition: CaloCluster.cxx:1345
CaloClusterMomentStore::CaloClusterMomentIterator
Internally used iterator.
Definition: CaloClusterMomentStore.h:54
CaloCell_ID_FCS::HEC2
@ HEC2
Definition: FastCaloSim_CaloCell_ID.h:29
CaloCluster::m_setEta
SET_VALUE m_setEta
Pointer to setter functions.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:683
CaloCluster::SW_7_11
@ SW_7_11
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:104
CaloCell::provenance
uint16_t provenance() const
get provenance (data member)
Definition: CaloCell.h:338
CaloCluster::samplingPattern
unsigned int samplingPattern() const
Get sampling bitmask.
Definition: CaloCluster.cxx:1507
CaloCluster::setDefaultSignalState
bool setDefaultSignalState(signalstate_t s)
Sets default signal state.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:865
CaloCluster::m_posSamNorm
std::vector< double > m_posSamNorm
Stores the normalization e.g.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:572
CaloCell::time
float time() const
get time (data member)
Definition: CaloCell.h:352
CaloShower
Data class for cluster variables associated with a CaloCluster.
Definition: CaloShower.h:12
P4EEtaPhiM::e
virtual double e() const
get energy data member
Definition: P4EEtaPhiM.h:102
CaloClusterMomentStore::contains
virtual bool contains(const moment_type &rMomType) const
Containment check.
Definition: CaloClusterMomentStore.h:237
CaloCluster::getCalE
double getCalE() const
Access to calibrated (LC) energy.
Definition: CaloCluster.cxx:1335
CaloDetDescrManager.h
Definition of CaloDetDescrManager.
CaloCluster::setenergymax
void setenergymax(sampling_type sampling, double m)
Set the maximum energy in a given sampling.
Definition: CaloCluster.cxx:908
P4EEtaPhiM::m_m
double m_m
Definition: P4EEtaPhiM.h:78
mergePhysValFiles.end
end
Definition: DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:93
CaloCell_ID.h
CaloClusterMomentStore
Stores CaloClusterMoment in a keyed map.
Definition: CaloClusterMomentStore.h:15
CaloCluster::getMomentStorePtrs
bool getMomentStorePtrs(const CaloClusterMomentStore *&pFirstStore, const CaloClusterMomentStore *&pSecndStore, bool useLink) const
Definition: CaloCluster.cxx:1216
CaloCluster::m_setM
SET_VALUE m_setM
Pointer to setter functions.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:687
CaloCluster::inEndcap
bool inEndcap() const
Returns true if at least one clustered cell in EMEC.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:931
P4EEtaPhiM::eta
virtual double eta() const
get eta data member
Definition: P4EEtaPhiM.h:105
dqt_zlumi_pandas.weight
int weight
Definition: dqt_zlumi_pandas.py:189
CaloVariableType::MAX_PHI
@ MAX_PHI
Definition: CaloVariableType.h:22
CaloCluster::unlockVariable
bool unlockVariable(const variable_type &varType)
Unlock variable (remove lock)
Definition: CaloCluster.cxx:1301
python.setupRTTAlg.size
int size
Definition: setupRTTAlg.py:39
proxim.h
CaloCluster::m_dataLink
data_link_type m_dataLink
{
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:488
CaloSamplingHelper::getSamplingBit
static unsigned int getSamplingBit(const CaloSample &rSample)
Return a unique bit set for a given sampling.
Definition: CaloEvent/CaloEvent/CaloSamplingHelper.h:48
CaloCluster::cell_iterator
CaloCompositeCellBase< CaloClusterNavigable >::cell_iterator cell_iterator
Iterator on CaloCell s.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:115
CaloSamplingHelper.h
CaloShower::getSamplingStore
const sampling_store & getSamplingStore() const
Retrieves the non-modifiable sampling data store.
Definition: CaloShower.h:77
CaloClusterMomentStore::begin
virtual moment_iterator begin() const
{
Definition: CaloClusterMomentStore.h:220
SETVAR
#define SETVAR(v, a)
CaloCluster::m_clusterSize
unsigned int m_clusterSize
Cluster size (e.g.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:554
CaloCell_ID_FCS::HEC1
@ HEC1
Definition: FastCaloSim_CaloCell_ID.h:28
constants.EMB2
int EMB2
Definition: Calorimeter/CaloClusterCorrection/python/constants.py:54
CaloCluster::MomentStoreIter::operator!=
bool operator!=(const MomentStoreIter &anOther) const
Inequality comparator.
Definition: CaloCluster.cxx:1564
CaloCluster::isAtSignalState
virtual bool isAtSignalState(signalstate_t s) const
check if we are at the passed state
Definition: CaloCluster.cxx:1365
fillPileUpNoiseLumi.next
next
Definition: fillPileUpNoiseLumi.py:52
CaloCluster::getBadChannel
const badChannelList * getBadChannel() const
Definition: CaloCluster.cxx:1434
lumiFormat.i
int i
Definition: lumiFormat.py:85
CaloSampling::CaloSample
CaloSample
Definition: Calorimeter/CaloGeoHelpers/CaloGeoHelpers/CaloSampling.h:22
CaloCluster::m_getE
GET_VALUE m_getE
Pointer to getter functions.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:672
CaloCluster::MomentStoreIter::operator==
bool operator==(const MomentStoreIter &anOther) const
Equality comparator.
Definition: CaloCluster.cxx:1561
CaloCluster::MomentStoreIter::operator*
const CaloClusterMoment & operator*() const
Operator access to CaloClusterMoment.
Definition: CaloCluster.cxx:1568
CaloVariableType::DELTA_ETA
@ DELTA_ETA
Definition: CaloVariableType.h:18
P4EEtaPhiM::m
virtual double m() const
get mass data member
Definition: P4EEtaPhiM.h:111
CaloCell::caloDDE
const CaloDetDescrElement * caloDDE() const
get pointer to CaloDetDescrElement (data member)
Definition: CaloCell.h:305
CaloCluster::getRawE
double getRawE() const
Access to raw energy.
Definition: CaloCluster.cxx:1315
CaloCluster::m_endcap
bool m_endcap
Flag is true if at least one cell in EMB.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:551
CaloCluster::setAltM
void setAltM(double m)
Set calibrated (cell weight) m.
Definition: CaloCluster.cxx:1333
CaloCluster::m_dataStore
CaloSamplingData m_dataStore
{\ brief Cached Stores
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:479
CaloCluster::getAltPhi
double getAltPhi() const
Access to calibrated (cell weight) phi.
Definition: CaloCluster.cxx:1327
CaloCluster::insertMoment
void insertMoment(const moment_type &momType, const moment_value &momValue, bool useLink=true)
Set individual moment.
Definition: CaloCluster.cxx:1247
CaloCompositeKineBase.h
CaloCluster::m_altM
double m_altM
Stores calibrated (cell weight) signal.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:711
CaloCluster::beginMoment
moment_iterator beginMoment(bool useLink=true) const
First iterator on moment store.
Definition: CaloCluster.cxx:1119
CaloCluster::MomentStoreIter::operator++
MomentStoreIter operator++()
Post-advance operator.
Definition: CaloCluster.cxx:1552
constants.EME1
int EME1
Definition: Calorimeter/CaloClusterCorrection/python/constants.py:55
CaloCluster
Principal data class for CaloCell clusters.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:79
CaloPhiRange.h
CaloPhiRange class declaration.
CaloCluster::m_rawM
double m_rawM
Stores raw signal.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:702
CaloCluster::setEta
virtual void setEta(double eta)
Set eta.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:769
P4SignalState::UNCALIBRATED
@ UNCALIBRATED
Definition: ISignalState.h:30
CaloShowerContainer.h
CaloCluster::setRawM
void setRawM(double m)
Set raw m.
Definition: CaloCluster.cxx:1323
CaloCluster::m_samplingPattern
unsigned int m_samplingPattern
Sampling pattern.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:501
CaloCluster::MomentStoreIter::operator--
MomentStoreIter operator--()
Post-step back operator.
Definition: CaloCluster.cxx:1556
CaloClusterMoment::getValue
const double & getValue() const
returns the value of this moment
Definition: CaloClusterMoment.h:153
INavigable
Definition: INavigable.h:18
PowhegPythia8EvtGen_jetjet.theEnergy
int theEnergy
Definition: PowhegPythia8EvtGen_jetjet.py:12
CaloCluster::badChannelList
std::vector< CaloClusterBadChannelData > badChannelList
Get Bad Channel information.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:458
xAOD::double
double
Definition: CompositeParticle_v1.cxx:159
CaloCluster::setRawE
void setRawE(double e)
Set raw energy.
Definition: CaloCluster.cxx:1320
CaloCluster::getCalEta
double getCalEta() const
Access to calibrated (LC) eta.
Definition: CaloCluster.cxx:1336
DeMoUpdate.tmp
string tmp
Definition: DeMoUpdate.py:1167
xAOD::CaloClusterBadChannelData
CaloClusterBadChannelData_v1 CaloClusterBadChannelData
Definition: Event/xAOD/xAODCaloEvent/xAODCaloEvent/CaloClusterBadChannelData.h:17
CaloCluster::setphimax
void setphimax(sampling_type sampling, double m)
Set the of cell with maximum energy in a given sampling.
Definition: CaloCluster.cxx:920
CaloCluster::setCalPhi
void setCalPhi(double phi)
Set calibrated (LC) phi.
Definition: CaloCluster.cxx:1342
CaloCluster::SW_55Econv
@ SW_55Econv
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:95
CaloPhiRange::fix
static double fix(double phi)
Definition: CaloPhiRange.cxx:14
CaloVariableType::MAX_ETA
@ MAX_ETA
Definition: CaloVariableType.h:21
IAthenaBarCode
Definition: AthenaKernel/AthenaKernel/IAthenaBarCode.h:48
CaloCluster::m_errorValue
static const double m_errorValue
Internal error return for real numbers.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:476
fill
void fill(H5::Group &out_file, size_t iterations)
Definition: test-hdf5-writer.cxx:95
CaloDetDescrElement::is_tile
bool is_tile() const
cell belongs to Tile
Definition: Calorimeter/CaloDetDescr/CaloDetDescr/CaloDetDescrElement.h:442
P4EEtaPhiM::setPhi
virtual void setPhi(double thePhi)
set phi data member
Definition: P4EEtaPhiM.h:120
CaloCluster::MomentStoreIter::getMomentType
moment_type getMomentType() const
Function access to moment type.
Definition: CaloCluster.cxx:1572
CaloCluster::calculateKine
void calculateKine(const bool useweight=true, const bool updateLayers=true)
Calculate cluster kinematics from contained cells.
Definition: CaloCluster.cxx:736
CaloCluster::moment_iterator
MomentStoreIter moment_iterator
Moment iterator type for CaloCluster clients.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:205
CaloCluster::setCalM
void setCalM(double m)
Set calibrated (LC) m.
Definition: CaloCluster.cxx:1343
CaloCluster::m_rawPhi
double m_rawPhi
Stores raw signal.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:700
CaloShower::getMomentStore
const moment_store & getMomentStore() const
Access cluster moment store.
Definition: CaloShower.h:71
CaloCluster::MomentStoreIter::next
MomentStoreIter next()
Advance iterator.
Definition: CaloCluster.cxx:1529
CaloCluster::getTime
double getTime() const
Access cluster time.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:886
P4EEtaPhiM::phi
virtual double phi() const
get phi data member
Definition: P4EEtaPhiM.h:108
CaloCluster::setStateAlt
bool setStateAlt()
Helper to switch to calibrated (cell weight) state.
Definition: CaloCluster.cxx:1392
CaloCell_ID_FCS::EME3
@ EME3
Definition: FastCaloSim_CaloCell_ID.h:26
CaloVariableType::getVariableBit
static unsigned int getVariableBit(const VariableType &varType)
Definition: CaloVariableType.h:25
CaloCluster::MomentStoreIter::~MomentStoreIter
~MomentStoreIter()
Destructor.
CaloCluster::~CaloCluster
virtual ~CaloCluster()
Destructor.
Definition: CaloCluster.cxx:248
CaloCluster::setRawPhi
void setRawPhi(double phi)
Set raw phi.
Definition: CaloCluster.cxx:1322
CaloCluster::endMoment
moment_iterator endMoment(bool useLink=true) const
Last iterator on moment store.
Definition: CaloCluster.cxx:1141
CaloCluster::hlv
virtual CLHEP::HepLorentzVector hlv() const
redefine hlv() here to avoid ambiguities
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:270
CaloCluster::m_altEta
double m_altEta
Stores calibrated (cell weight) signal.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:707
CaloCluster::setAltE
void setAltE(double e)
Set calibrated (cell weight) energy.
Definition: CaloCluster.cxx:1330
CaloSamplingData.h
CaloClusterMomentStore::insert
virtual void insert(const moment_type &rMomType, const moment_value &rMomData)
Insert key/data pair.
Definition: CaloClusterMomentStore.h:213
CaloClusterMomentStore::retrieve
virtual bool retrieve(const moment_type &rMomType, moment_value &rMomData) const
Retrieve cluster moment for a given key.
Definition: CaloClusterMomentStore.cxx:37
CaloCluster::setAltPhi
void setAltPhi(double phi)
Set calibrated (cell weight) phi.
Definition: CaloCluster.cxx:1332
CaloCluster::MomentStoreIter::getMoment
const CaloClusterMoment & getMoment() const
Function access to CaloClusterMoment.
Definition: CaloCluster.cxx:1570
CaloCell_ID_FCS::HEC0
@ HEC0
Definition: FastCaloSim_CaloCell_ID.h:27
CaloCompositeCellBase.h
CaloClusterNavigable
Navigable part of CaloCluster, use CaloCellLink.
Definition: CaloClusterNavigable.h:34
CaloClusterBadChannelData
Definition: Calorimeter/CaloEvent/CaloEvent/CaloClusterBadChannelData.h:12
CaloCluster::MomentStoreIter::m_iter
moment_iterator_i m_iter
Actual iterator on CaloClusterMomentStore.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:197
CaloCluster::m_setE
SET_VALUE m_setE
Pointer to setter functions.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:681
CaloCluster::SW_35ele
@ SW_35ele
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:88
CxxUtils::prefetchObj
void prefetchObj(const T *ptr)
Generic prefetch of the object of specific types (sizes).
Definition: prefetch.h:108
CaloCluster::SW_37Econv
@ SW_37Econv
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:97
CaloCluster::setE
virtual void setE(double e)
Set energy.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:767
CaloCluster::m_shower
CaloShower * m_shower
}
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:492
CaloCluster::allLocked
bool allLocked() const
Check if all variables are locked.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:1289
CaloCluster::getAltEta
double getAltEta() const
Access to calibrated (cell weight) eta.
Definition: CaloCluster.cxx:1326
CaloCell
Data object for each calorimeter readout cell.
Definition: CaloCell.h:57
CaloCluster::m_defSigState
signalstate_t m_defSigState
Stores default signal state.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:693
CaloSamplingData::contains
bool contains(variable_key_type theVariable) const
Check on available variable types.
Definition: CaloSamplingData.h:282
CaloCluster::lockVariable
bool lockVariable(const variable_type &varType)
Lock variable (protect against future updates)
Definition: CaloCluster.cxx:1293
P4EEtaPhiM::setM
virtual void setM(double theM)
set mass data member
Definition: P4EEtaPhiM.h:123
CaloDetDescrElement::getSampling
CaloCell_ID::CaloSample getSampling() const
cell sampling
Definition: Calorimeter/CaloDetDescr/CaloDetDescr/CaloDetDescrElement.h:395
CaloClusterMomentStore::end
virtual moment_iterator end() const
iterator loop terminator
Definition: CaloClusterMomentStore.h:226
CaloCluster::eta
virtual double eta() const
Retrieve eta independent of signal state.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:755
CaloCluster::SW_55gam
@ SW_55gam
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:91
CaloCell_ID_FCS::PreSamplerE
@ PreSamplerE
Definition: FastCaloSim_CaloCell_ID.h:23
P4EEtaPhiMBase
Definition: P4EEtaPhiMBase.h:26
CaloCell_ID_FCS::PreSamplerB
@ PreSamplerB
Definition: FastCaloSim_CaloCell_ID.h:19
CaloClusterMoment
defines enums and data types for different moments of CaloCluster
Definition: CaloClusterMoment.h:29
CaloClusterNavigable::getCellLink
CaloCellLink * getCellLink()
Definition: CaloClusterNavigable.cxx:39
P4SignalState::State
State
Definition: ISignalState.h:28
CaloCluster::m_nBarrel
int m_nBarrel
Counter for number of barrel cells with non-zero weight and energy.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:576
INavigable4Momentum
Definition: INavigable4Momentum.h:21
CaloCluster::MomentStoreIter::prev
MomentStoreIter prev()
Step back iterator.
Definition: CaloCluster.cxx:1541
CaloCluster::setStores
bool setStores(CaloShower *pData, CaloCellLink *pLink, bool ownStores=true)
Setup internal store.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:902
CaloCluster::updateKine
virtual void updateKine(const CaloCell *theCell, double weight)
Updates cluster kinematics when cell is added.
Definition: CaloCluster.cxx:263
CaloCluster::e
virtual double e() const
Retrieve energy independent of signal state.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:753
P4SignalState::CALIBRATED
@ CALIBRATED
Definition: ISignalState.h:31
P4EEtaPhiM::setE
virtual void setE(double theE)
set energy data member
Definition: P4EEtaPhiM.h:114
beamspotnt.varList
list varList
Definition: bin/beamspotnt.py:1108
CaloCluster::m_rawE
double m_rawE
Stores raw signal.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:696
CaloCluster::m_posNorm
double m_posNorm
Stores the normalization e.g.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:568
CaloCluster::getAltE
double getAltE() const
Access to calibrated (cell weight) energy.
Definition: CaloCluster.cxx:1325
CaloShower.h
CaloCell_ID_FCS::FCAL2
@ FCAL2
Definition: FastCaloSim_CaloCell_ID.h:42
CaloDetDescrElement::eta
float eta() const
cell eta
Definition: Calorimeter/CaloDetDescr/CaloDetDescr/CaloDetDescrElement.h:344
CaloCluster::variableBE
double variableBE(const variable_type &theVariable, const int &samplingIndex) const
Rewrite as for calculation.
Definition: CaloCluster.cxx:953
P4SignalState::ALTCALIBRATED
@ ALTCALIBRATED
Definition: ISignalState.h:32
CaloDetDescrElement::phi
float phi() const
cell phi
Definition: Calorimeter/CaloDetDescr/CaloDetDescr/CaloDetDescrElement.h:346
CaloCluster::getMomentStore
CaloClusterMomentStore * getMomentStore(bool useLink=true)
Definition: CaloCluster.cxx:1172
CaloVariableType::ETA
@ ETA
Definition: CaloVariableType.h:16
CaloCluster::getCalPhi
double getCalPhi() const
Access to calibrated (LC) phi.
Definition: CaloCluster.cxx:1337
CaloCluster::getAltM
double getAltM() const
Access to calibrated (cell weight) m.
Definition: CaloCluster.cxx:1328
CaloCluster::setphisize
void setphisize(sampling_type sampling, double size)
Set the cluster size in for a given sampling.
Definition: CaloCluster.cxx:940
CaloCluster::retrieveMoment
bool retrieveMoment(const moment_type &momType, moment_value &momValue, bool useLink=true) const
Retrieve individual moment.
Definition: CaloCluster.cxx:1266
CaloCluster::m
virtual double m() const
Retrieve mass independent of signal state.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:764
CaloCluster::m_signalState
signalstate_t m_signalState
Stores actual signal state.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:691
CaloCluster::setPhi
virtual void setPhi(double phi)
Set phi.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:771
CaloSamplingData
Simple data object to store all variables in calorimeter samplings.
Definition: CaloSamplingData.h:18
python.IoTestsLib.w
def w
Definition: IoTestsLib.py:200
CaloCluster::m_badChannelData
badChannelList m_badChannelData
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:583
CaloCell_ID_FCS::HEC3
@ HEC3
Definition: FastCaloSim_CaloCell_ID.h:30
CaloCluster::SW_37ele
@ SW_37ele
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:89
CaloClusterMomentStore::size
size_t size() const
Number of stored moments.
Definition: CaloClusterMomentStore.h:242
CaloCluster::hasSignalState
virtual bool hasSignalState(signalstate_t s) const
check if signal state exists for current implementation
Definition: CaloCluster.cxx:1358
P4EEtaPhiM::m_phi
double m_phi
Definition: P4EEtaPhiM.h:77
CaloCell_ID_FCS::FCAL0
@ FCAL0
Definition: FastCaloSim_CaloCell_ID.h:40
CaloCompositeCellBase
base class for methods and store of cell links
Definition: CaloCompositeCellBase.h:13
CaloCluster::addBadChannel
void addBadChannel(const CaloClusterBadChannelData &badChannel)
Add Bad channel information.
Definition: CaloCluster.cxx:1424
CaloCluster::setAltEta
void setAltEta(double eta)
Set calibrated (cell weight) eta.
Definition: CaloCluster.cxx:1331
python.compressB64.c
def c
Definition: compressB64.py:93
dq_make_web_display.cl
cl
print [x.__class__ for x in toList(dqregion.getSubRegions()) ]
Definition: dq_make_web_display.py:26
CaloCluster::getClusterEtaSize
unsigned int getClusterEtaSize() const
Definition: CaloCluster.cxx:1439
CaloCluster::m_barrel
bool m_barrel
Flag is true if at least one cell in EMB.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:549
CaloCluster::getRawM
double getRawM() const
Access to raw mass.
Definition: CaloCluster.cxx:1318
CaloPrefetch::nextDDE
void nextDDE(Iter iter, Iter endIter)
Prefetch next CaloDDE.
Definition: CaloPrefetch.h:47
CaloCluster::resetBadChannel
void resetBadChannel()
Reset Bad channel list.
Definition: CaloCluster.cxx:1429
CaloCluster::m_rawEta
double m_rawEta
Stores raw signal.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:698
CaloCluster::getCalM
double getCalM() const
Access to calibrated (LC) m.
Definition: CaloCluster.cxx:1338
constants.EME2
int EME2
Definition: Calorimeter/CaloClusterCorrection/python/constants.py:56
CaloCluster::setStateRaw
bool setStateRaw()
Helper to switch to raw state.
Definition: CaloCluster.cxx:1375
CaloVariableType::ENERGY
@ ENERGY
Definition: CaloVariableType.h:15
CaloCell::eta
virtual double eta() const override final
get eta (through CaloDetDescrElement)
Definition: CaloCell.h:366
prefetch.h
Functions to prefetch blocks of memory.
CaloPhiRange::diff
static double diff(double phi1, double phi2)
simple phi1 - phi2 calculation, but result is fixed to respect range.
Definition: CaloPhiRange.cxx:22
CaloCluster::MomentStoreIter::MomentStoreIter
MomentStoreIter()
Default constructor builds unusable iterator.
Definition: CaloCluster.cxx:1518
CaloCompositeKineBase
base class for kinematics of composite calo object
Definition: CaloCompositeKineBase.h:13
CaloCluster::getVariable
double getVariable(const variable_type &varType, const sampling_type &samType, bool useLink=true) const
General sampling variable access.
Definition: CaloCluster.cxx:837
CaloCluster::m_lockPattern
unsigned int m_lockPattern
Variable lock pattern.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:581
CaloCluster::getRawEta
double getRawEta() const
Access to raw eta.
Definition: CaloCluster.cxx:1316
P4EEtaPhiM::m_eta
double m_eta
Definition: P4EEtaPhiM.h:76
CaloCluster::phi
virtual double phi() const
Retrieve phi independent of signal state.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:759
CaloCluster::isEMSampling
bool isEMSampling(const sampling_type &theSampling) const
Checks if cells from a given sampling in EMB and EMEC are in the cluster.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:951