Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:23:56

0001 import FWCore.ParameterSet.Config as cms
0002 from PhysicsTools.PatAlgos.slimming.prunedGenParticles_cfi import *
0003 from PhysicsTools.PatAlgos.slimming.packedGenParticles_cfi import *
0004 
0005 prunedGenParticlesWithStatusOne = prunedGenParticles.clone()
0006 prunedGenParticlesWithStatusOne.select.append( "keep    status == 1")
0007 
0008 prunedGenParticles.src =  cms.InputTag("prunedGenParticlesWithStatusOne")
0009 
0010 packedGenParticles.inputCollection = cms.InputTag("prunedGenParticlesWithStatusOne")
0011 packedGenParticles.map = cms.InputTag("prunedGenParticles") # map with rekey association from prunedGenParticlesWithStatusOne to prunedGenParticles, used to relink our refs to prunedGen
0012 packedGenParticles.inputOriginal = cms.InputTag("genParticles")
0013 
0014 genParticlesTask = cms.Task(
0015     prunedGenParticles,
0016     packedGenParticles,
0017     prunedGenParticlesWithStatusOne
0018 )
0019 
0020 from PhysicsTools.PatAlgos.packedGenParticlesSignal_cfi import *
0021 
0022 _genParticlesHITask = genParticlesTask.copy()
0023 _genParticlesHITask.add(packedGenParticlesSignal)
0024 
0025 from Configuration.ProcessModifiers.pp_on_AA_cff import pp_on_AA
0026 pp_on_AA.toReplaceWith(genParticlesTask, _genParticlesHITask)