ATLAS Offline Software
Public Member Functions | Public Attributes | List of all members
CookieCutterHelpers::PhiSize Struct Reference

Find the size of the cluster in phi using L2 cells. More...

#include <CookieCutterHelpers.h>

Collaboration diagram for CookieCutterHelpers::PhiSize:

Public Member Functions

 PhiSize ()=default
 
 PhiSize (const CentralPosition &cp0, const xAOD::CaloCluster &cluster)
 

Public Attributes

float plusB = 0
 
float minusB = 0
 
float plusEC = 0
 
float minusEC = 0
 

Detailed Description

Find the size of the cluster in phi using L2 cells.

Parameters
cp0the reference position in calo-coordinates
clusterthe cluster filled with L2 and L3 cells

The window is computed using only cells in the second layer. Asymmetric sizes are computed for barrel and endcap. The size is the maximum difference in phi between the center of a cell and the refence, considering separately cells in the barrel and in the endcap. The computation is done separately for the cells with phi < reference phi or >=. A cutoff value of 1 is used.

Definition at line 48 of file CookieCutterHelpers.h.

Constructor & Destructor Documentation

◆ PhiSize() [1/2]

CookieCutterHelpers::PhiSize::PhiSize ( )
default

◆ PhiSize() [2/2]

CookieCutterHelpers::PhiSize::PhiSize ( const CentralPosition cp0,
const xAOD::CaloCluster cluster 
)

Definition at line 77 of file CookieCutterHelpers.cxx.

78 {
79  auto cell_itr = cluster.cell_cbegin();
80  auto cell_end = cluster.cell_cend();
81  for (; cell_itr != cell_end; ++cell_itr) {
82 
83  const CaloCell* cell = *cell_itr;
84  if (!cell) {
85  continue;
86  }
87 
88  const CaloDetDescrElement* dde = cell->caloDDE();
89  if (!dde) {
90  continue;
91  }
92 
93  if (cp0.emaxB > 0 && CaloCell_ID::EMB2 == dde->getSampling()) {
94  const float phi0 = cp0.phiB;
95  double cell_phi = proxim(dde->phi_raw(), phi0);
96  if (cell_phi > phi0) {
97  auto diff = cell_phi - phi0;
98  if (diff > plusB) {
99  plusB = diff;
100  }
101  } else {
102  auto diff = phi0 - cell_phi;
103  if (diff > minusB) {
104  minusB = diff;
105  }
106  }
107  } else if (cp0.emaxEC > 0 && CaloCell_ID::EME2 == dde->getSampling()) {
108  const float phi0 = cp0.phiEC;
109  double cell_phi = proxim(dde->phi_raw(), phi0);
110  if (cell_phi > phi0) {
111  auto diff = cell_phi - phi0;
112  if (diff > plusEC) {
113  plusEC = diff;
114  }
115  } else {
116  auto diff = phi0 - cell_phi;
117  if (diff > minusEC) {
118  minusEC = diff;
119  }
120  }
121  }
122  }
123 }

Member Data Documentation

◆ minusB

float CookieCutterHelpers::PhiSize::minusB = 0

Definition at line 51 of file CookieCutterHelpers.h.

◆ minusEC

float CookieCutterHelpers::PhiSize::minusEC = 0

Definition at line 53 of file CookieCutterHelpers.h.

◆ plusB

float CookieCutterHelpers::PhiSize::plusB = 0

Definition at line 50 of file CookieCutterHelpers.h.

◆ plusEC

float CookieCutterHelpers::PhiSize::plusEC = 0

Definition at line 52 of file CookieCutterHelpers.h.


The documentation for this struct was generated from the following files:
CookieCutterHelpers::PhiSize::minusEC
float minusEC
Definition: CookieCutterHelpers.h:53
ReadCellNoiseFromCool.cell
cell
Definition: ReadCellNoiseFromCool.py:53
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
proxim
double proxim(double b, double a)
Definition: proxim.h:17
mc.diff
diff
Definition: mc.SFGenPy8_MuMu_DD.py:14
CookieCutterHelpers::PhiSize::plusB
float plusB
Definition: CookieCutterHelpers.h:50
constants.EMB2
int EMB2
Definition: Calorimeter/CaloClusterCorrection/python/constants.py:54
CookieCutterHelpers::PhiSize::plusEC
float plusEC
Definition: CookieCutterHelpers.h:52
CookieCutterHelpers::PhiSize::minusB
float minusB
Definition: CookieCutterHelpers.h:51
xAOD::CaloCluster_v1::cell_cend
const_cell_iterator cell_cend() const
Definition: CaloCluster_v1.h:803
CaloCell
Data object for each calorimeter readout cell.
Definition: CaloCell.h:57
CaloDetDescrElement::getSampling
CaloCell_ID::CaloSample getSampling() const
cell sampling
Definition: Calorimeter/CaloDetDescr/CaloDetDescr/CaloDetDescrElement.h:395
xAOD::CaloCluster_v1::cell_cbegin
const_cell_iterator cell_cbegin() const
Definition: CaloCluster_v1.h:795
constants.EME2
int EME2
Definition: Calorimeter/CaloClusterCorrection/python/constants.py:56
CaloDetDescrElement::phi_raw
float phi_raw() const
cell phi_raw
Definition: Calorimeter/CaloDetDescr/CaloDetDescr/CaloDetDescrElement.h:352