37 ROOT::Math::SMatrixIdentity
id;
39 const float uncert = 0.001;
203 mySimEvent_ = std::make_unique<FSimEvent>(particleFilter_);
259 const std::vector<PileupSummaryInfo> &PupInfo = *PupInfo_h;
283 mySimEvent_->fill(*simTracksHandle, *simVerticesHandle);
285 HepMC::GenVertex *
primaryVertex = *(hevH)->GetEvent()->vertices_begin();
286 const float mm2cm = 0.1;
293 std::vector<FSimTrack *> allselectedgentracks;
294 const float eeInnerRadius = 25.;
295 const float eeOuterRadius = 160.;
297 for (
unsigned int i = 0;
i <
npart; ++
i) {
298 std::vector<float> xp, yp, zp;
302 int reachedEE = ReachHGCal::notReach;
310 if (myTrack.noEndVertex())
314 toHGCalPropagator.
propagate(myTrack.momentum(), myTrack.vertex().position(), myTrack.charge(), propcoords);
317 if (reachesHGCal &&
vtx.Rho() < eeOuterRadius &&
vtx.Rho() > eeInnerRadius) {
318 reachedEE = ReachHGCal::onEESurface;
321 for (
int i = 0;
i < myTrack.nDaughters(); ++
i)
322 dpt += myTrack.daughter(
i).momentum().pt();
323 if (
abs(myTrack.type()) == 11)
324 fbrem = dpt / myTrack.momentum().pt();
325 }
else if (reachesHGCal &&
vtx.Rho() > eeOuterRadius)
326 reachedEE = ReachHGCal::outsideEESurface;
329 for (
unsigned il = 1; il <=
nlayers; ++il) {
330 const float charge = myTrack.charge();
333 indiv_particleProp.
propagate(myTrack.momentum(), myTrack.vertex().position(),
charge, propCoords);
335 xp.push_back(propCoords.
x);
336 yp.push_back(propCoords.
y);
337 zp.push_back(propCoords.
z);
340 vtx = myTrack.endVertex().position();
342 auto orig_vtx = myTrack.vertex().position();
359 toHGCalPropagator.
propagate(myTrack.momentum(), orig_vtx, myTrack.charge(), hitsHGCal);
379 gen_n_ = genParticlesHandle->size();
381 for (
const auto &particle : *genParticlesHandle) {
384 gen_pt_.push_back(particle.pt());
389 std::vector<int>
daughters(particle.daughterRefVector().size(), 0);
390 for (
unsigned j = 0;
j < particle.daughterRefVector().size(); ++
j) {
391 daughters[
j] = static_cast<int>(particle.daughterRefVector().at(
j).key());
398 for (
size_t i = 0;
i < allselectedgentracks.size();
i++) {
399 const auto tracki = allselectedgentracks.at(
i);
401 for (
size_t j =
i + 1;
j < allselectedgentracks.size();
j++) {
402 const auto trackj = allselectedgentracks.at(
j);
404 if (!tracki->noMother()) {
405 if (&tracki->mother() == trackj)
408 if (!trackj->noMother()) {
409 if (&trackj->mother() == tracki)
415 for (
const auto &PVI : PupInfo) {
416 if (PVI.getBunchCrossing() == 0) {