10 #include "CaloDetDescr/CaloDetDescrElement.h"
18 #include "GaudiKernel/ThreadLocalContext.h"
33 m_calocell_id(nullptr)
36 declareInterface<IDataRetriever>(
this);
38 declareInterface<IDataRetriever>(
this);
64 return StatusCode::SUCCESS;
87 return StatusCode::SUCCESS;
98 const EventContext& ctx = Gaudi::Hive::currentContext();
112 DataVect feedThrough; feedThrough.reserve(cellContainer->
size());
116 DataVect cellTimeVec; cellTimeVec.reserve(cellContainer->
size());
118 DataVect cellPedestal; cellPedestal.reserve(cellContainer->
size());
119 DataVect adc2Mev; adc2Mev.reserve(cellContainer->
size());
120 DataVect BadCell; BadCell.reserve(cellContainer->
size());
138 ATH_MSG_ERROR(
"in getFCalData(), Could not retrieve LAr Pedestal" );
144 ATH_MSG_ERROR(
"in getFCalData(),Could not get LArOnlineID!" );
153 double energyGeV, xmm, ymm, zmm, dxmm, dymm, dzmm, cellTime;
154 double energyAllLArFcal = 0.;
158 if((*it1)->badcell()) BadCell.push_back(1);
160 else BadCell.push_back(-1);
165 HWIdentifier LArhwid =
cabling->createSignalChannelIDFromHash((*it1)->caloDDE()->calo_hash());
169 bool maskChannel =
false;
176 if (maskChannel)
continue;
179 energyGeV = (*it1)->energy()*(1./
GeV);
181 energyAllLArFcal += energyGeV;
184 xmm = (*it1)->x()*0.1;
185 ymm = (*it1)->y()*0.1;
186 zmm = (*it1)->z()*0.1;
187 x.emplace_back( gcvt( xmm, 4, rndStr) );
188 y.emplace_back( gcvt( ymm, 4, rndStr) );
189 z.emplace_back( gcvt( zmm, 4, rndStr) );
192 feedThrough.emplace_back(onlineId->
feedthrough(LArhwid));
193 slot.emplace_back(onlineId->
slot(LArhwid));
196 cellTime = (*it1)->time();
197 cellTimeVec.emplace_back( gcvt( cellTime,
m_cellTimePrec, rndStr) );
198 cellGain.emplace_back( (*it1)->gain() );
200 int fcalgain = (*it1)->gain();
201 float pedestal=larPedestal->
pedestal(LArhwid,fcalgain);
205 cellPedestal.emplace_back(pedvalue);
208 if (polynom_adc2mev.size()==0){ adc2Mev.emplace_back(-1); }
209 else{ adc2Mev.emplace_back(polynom_adc2mev[1]); }
214 dxmm = elt->
dx()*0.1;
215 dymm = elt->
dy()*0.1;
216 dzmm = elt->
dz()*0.1;
217 dx.emplace_back( gcvt( dxmm, 4, rndStr) );
218 dy.emplace_back( gcvt( dymm, 4, rndStr) );
219 dz.emplace_back( gcvt( dzmm, 4, rndStr) );
227 ATH_MSG_DEBUG(
" Total energy in FCAL (LAr) in GeV : " << energyAllLArFcal );
238 DataMap[
"id"] = std::move(idVec);
240 DataMap[
"feedThrough"] = std::move(feedThrough);
241 DataMap[
"slot"] = std::move(slot);
244 DataMap[
"BadCell"] = std::move(BadCell);
245 }
DataMap[
"sub"] = std::move(sub);
249 DataMap[
"cellTime"] = std::move(cellTimeVec);
251 DataMap[
"cellPedestal"] = std::move(cellPedestal);
252 DataMap[
"adc2Mev"] = std::move(adc2Mev);