diff --git a/PWGLF/Tasks/QC/mcParticlePrediction.cxx b/PWGLF/Tasks/QC/mcParticlePrediction.cxx index c190fe5a525..2c9bd255524 100644 --- a/PWGLF/Tasks/QC/mcParticlePrediction.cxx +++ b/PWGLF/Tasks/QC/mcParticlePrediction.cxx @@ -496,9 +496,9 @@ struct McParticlePrediction { continue; } - // if (!particle.isPhysicalPrimary()) { - // continue; - // } + if (!particle.isPhysicalPrimary()) { + continue; + } TParticlePDG* p = pdgDB->GetParticle(particle.pdgCode()); if (p) { @@ -513,27 +513,6 @@ struct McParticlePrediction { continue; } - // Check if particle has daughters (not a final state particle) - auto daughters = particle.daughters_as(); - bool isValid = false; - - if (daughters.size() > 0) { - isValid = true; - for (const auto& daughter : daughters) { - if (!daughter.isPhysicalPrimary()) { - isValid = false; - break; - } - } - } else { - // Final state particle - check if particle itself is physical primary - isValid = particle.isPhysicalPrimary(); - } - - if (!isValid) { - continue; - } - histos.fill(HIST("particles/vtx/x"), particle.vx()); histos.fill(HIST("particles/vtx/y"), particle.vy()); histos.fill(HIST("particles/vtx/z"), particle.vz() - mcCollision.posZ());