File indexing completed on 2025-05-09 22:40:13
0001 import FWCore.ParameterSet.Config as cms
0002 from PhysicsTools.NanoAOD.genparticles_cff import *
0003 from PhysicsTools.NanoAOD.simpleGenParticleFlatTableProducer_cfi import simpleGenParticleFlatTableProducer
0004
0005
0006
0007
0008
0009
0010 finalGenParticlesBPH = finalGenParticles.clone(
0011 src = cms.InputTag("mergedGenParticles"),
0012 select = cms.vstring(
0013 "drop *",
0014 "keep++ (abs(pdgId) == 511 || abs(pdgId) == 521 || abs(pdgId)==531)",
0015 )
0016 )
0017
0018 genParticleBPHTable = simpleGenParticleFlatTableProducer.clone(
0019 src = cms.InputTag("finalGenParticlesBPH"),
0020 name = cms.string("BPHGenPart"),
0021 doc = cms.string("interesting gen particles for BPH"),
0022 variables = cms.PSet(
0023 genParticleTable.variables,
0024 vx = Var("vx", float, doc="x coordinate of the production vertex position, in cm", precision=10),
0025 vy = Var("vy", float, doc="y coordinate of the production vertex position, in cm", precision=10),
0026 vz = Var("vz", float, doc="z coordinate of the production vertex position, in cm", precision=10),
0027 )
0028 )
0029
0030
0031
0032 genParticleBPHSequence = cms.Sequence(finalGenParticlesBPH)
0033 genParticleBPHTables = cms.Sequence(genParticleBPHTable)
0034