21 DataMixingEMWorker::DataMixingEMWorker() {}
25 : label_(ps.getParameter<
std::
string>(
"Label"))
65 LogInfo(
"DataMixingEMWorker") <<
"===============> adding MC signals for " <<
e.id();
83 LogDebug(
"DataMixingEMWorker") <<
"processed EBRecHit with rawId: " << it->id().rawId() <<
"\n"
84 <<
" rechit energy: " << it->energy();
104 LogDebug(
"DataMixingEMWorker") <<
"processed EERecHit with rawId: " << it->id().rawId() <<
"\n"
105 <<
" rechit energy: " << it->energy();
116 ESRecHits = pESRecHits.
product();
118 LogDebug(
"DataMixingEMWorker") <<
"total # ES rechits: " << ESRecHits->
size();
128 LogDebug(
"DataMixingEMWorker") <<
"processed ESRecHit with rawId: " << it->id().rawId() <<
"\n"
129 <<
" rechit energy: " << it->energy();
138 unsigned int eventNr,
140 LogInfo(
"DataMixingEMWorker") <<
"\n===============> adding pileups from event " <<
ep->id()
141 <<
" for bunchcrossing " << bcr;
148 std::shared_ptr<Wrapper<EBRecHitCollection>
const> EBRecHitsPTR =
161 LogDebug(
"DataMixingEMWorker") <<
"processed EBRecHit with rawId: " << it->id().rawId() <<
"\n"
162 <<
" rechit energy: " << it->energy();
169 std::shared_ptr<Wrapper<EERecHitCollection>
const> EERecHitsPTR =
182 LogDebug(
"DataMixingEMWorker") <<
"processed EERecHit with rawId: " << it->id().rawId() <<
"\n"
183 <<
" rechit energy: " << it->energy();
190 std::shared_ptr<Wrapper<ESRecHitCollection>
const> ESRecHitsPTR =
194 const ESRecHitCollection *ESRecHits = const_cast<ESRecHitCollection *>(ESRecHitsPTR->product());
196 LogDebug(
"DataMixingEMWorker") <<
"total # ES rechits: " << ESRecHits->
size();
203 LogDebug(
"DataMixingEMWorker") <<
"processed ESRecHit with rawId: " << it->id().rawId() <<
"\n"
204 <<
" rechit energy: " << it->energy();
225 EBRecHitMap::const_iterator iEBchk;
228 currentID = iEB->first;
230 if (currentID == formerID) {
232 ESum += (iEB->second).
energy();
237 EBrechits->push_back(aHit);
240 formerID = currentID;
241 ESum = (iEB->second).
energy();
242 EBTime = (iEB->second).
time();
248 EBrechits->push_back(aHit);
260 EERecHitMap::const_iterator iEEchk;
263 currentID = iEE->first;
265 if (currentID == formerID) {
267 ESum += (iEE->second).
energy();
272 EErechits->push_back(aHit);
275 formerID = currentID;
276 ESum = (iEE->second).
energy();
277 EETime = (iEE->second).
time();
283 EErechits->push_back(aHit);
295 ESRecHitMap::const_iterator iESchk;
298 currentID = iES->first;
300 if (currentID == formerID) {
302 ESum += (iES->second).
energy();
307 ESrechits->push_back(aHit);
310 formerID = currentID;
311 ESum = (iES->second).
energy();
312 ESTime = (iES->second).
time();
318 ESrechits->push_back(aHit);
325 LogInfo(
"DataMixingEMWorker") <<
"total # EB Merged rechits: " << EBrechits->size();
326 LogInfo(
"DataMixingEMWorker") <<
"total # EE Merged rechits: " << EErechits->size();
327 LogInfo(
"DataMixingEMWorker") <<
"total # ES Merged rechits: " << ESrechits->size();