45 return StatusCode::SUCCESS;
79 return StatusCode::SUCCESS;
86 const EventContext& ctx)
const
94 decoration0(decorKeys[0], ctx);
96 decoration1(decorKeys[1], ctx);
98 decoration2(decorKeys[2], ctx);
100 decoration3(decorKeys[3], ctx);
102 decoration4(decorKeys[4], ctx);
104 decoration5(decorKeys[5], ctx);
106 decoration6(decorKeys[6], ctx);
108 decoration7(decorKeys[7], ctx);
110 decoration8(decorKeys[8], ctx);
112 decoration9(decorKeys[9], ctx);
114 decoration10(decorKeys[10], ctx);
116 decoration11(decorKeys[11], ctx);
120 for (
const auto*
egamma : *importedEgamma) {
135 decoration9(*
egamma) =
res.cells_quality;
140 return StatusCode::SUCCESS;
147 const EventContext& ctx)
const
161 throw std::runtime_error(
"Cabling retrieval failed");
164 for (
const CaloCell* cell : *cluster) {
166 int sampling = cell->caloDDE()->getSampling();
172 if (sampling == CaloCell_ID::PreSamplerB || sampling == CaloCell_ID::PreSamplerE){
176 else if (sampling == CaloCell_ID::EMB1 || sampling == CaloCell_ID::EME1){
180 else if (sampling == CaloCell_ID::EMB2 || sampling == CaloCell_ID::EME2){
184 else if (sampling == CaloCell_ID::EMB3 || sampling == CaloCell_ID::EME3){
194 decorations.
cells_E.push_back(cell->e());
195 decorations.
cells_time.push_back(cell->time());
196 decorations.
cells_eta.push_back(cell->eta());
197 decorations.
cells_phi.push_back(cell->phi());
198 decorations.
cells_x.push_back(cell->x());
199 decorations.
cells_y.push_back(cell->y());
200 decorations.
cells_z.push_back(cell->z());
201 decorations.
cells_gain.push_back((
int)cell->gain());
206 (uint64_t)(cabling->createSignalChannelID(cell->caloDDE()->identify()))
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_VERBOSE(x)
#define ATH_MSG_WARNING(x)
std::pair< std::vector< unsigned int >, bool > res
Data object for each calorimeter readout cell.
SG::ReadCondHandleKey< LArOnOffIdMapping > m_cablingKey
SG::ReadHandleKey< xAOD::EgammaContainer > m_SGKey_photons
SG::WriteDecorHandleKeyArray< xAOD::EgammaContainer > m_SGKey_photons_decorations
SG::WriteDecorHandleKeyArray< xAOD::EgammaContainer > m_SGKey_electrons_decorations
SG::ReadHandleKey< xAOD::EgammaContainer > m_SGKey_electrons
StatusCode decorateCells(const SG::ReadHandleKey< xAOD::EgammaContainer > &contKey, const SG::WriteDecorHandleKeyArray< xAOD::EgammaContainer > &decorKeys, const EventContext &ctx) const
virtual StatusCode addBranches(const EventContext &ctx) const override final
virtual StatusCode initialize() override final
cell_decorations getDecorations(const xAOD::CaloCluster *cluster, const EventContext &ctx) const
Property holding a SG store/key/clid from which a ReadHandle is made.
Handle class for adding a decoration to an object.
This is a data object, containing a collection of egamma Objects.
const CaloClusterCellLink * getCellLinks() const
Get a pointer to the CaloClusterCellLink object (const version)
Athena::TPCnvVers::Old Athena::TPCnvVers::Old Athena::TPCnvVers::Old Athena::TPCnvVers::Old Athena::TPCnvVers::Current Athena::TPCnvVers::Current egammaContainer
DecorHandleKeyArray< WriteDecorHandle< T, S >, WriteDecorHandleKey< T >, Gaudi::DataHandle::Writer > WriteDecorHandleKeyArray
const T * get(const ReadCondHandleKey< T > &key, const EventContext &ctx)
Convenience function to retrieve an object given a ReadCondHandleKey.
CaloCluster_v1 CaloCluster
Define the latest version of the calorimeter cluster class.
EgammaContainer_v1 EgammaContainer
Definition of the current "egamma container version".
std::vector< int > cells_gain
std::vector< float > cells_x
std::vector< int > cells_layer
std::vector< float > cells_time
std::vector< float > cells_phi
std::vector< uint64_t > cells_onlId
std::vector< int > cells_quality
std::vector< float > cells_y
std::vector< float > cells_eta
std::vector< float > cells_z
std::vector< float > cells_E