11 nanoMetadata = cms.EDProducer(
"UniqueStringProducer",
13 tag = cms.string(
"untagged"),
17 nanogenSequence = cms.Sequence(
19 cms.Sequence(particleLevelTask)+
22 genJetFlavourAssociation+
25 genJetAK8FlavourAssociation+
26 genJetAK8FlavourTable+
27 cms.Sequence(genTauTask)+
30 cms.Sequence(genParticleTablesTask)+
31 cms.Sequence(genVertexTablesTask)+
34 cms.Sequence(particleLevelTablesTask)+
40 process.rivetMetTable.extension =
False 41 process.lheInfoTable.storeLHEParticles =
True 42 process.lheInfoTable.precision = 14
43 process.genWeightsTable.keepAllPSWeights =
True 44 process.genJetFlavourAssociation.jets = process.genJetTable.src
45 process.genJetFlavourTable.src = process.genJetTable.src
46 process.genJetAK8FlavourAssociation.jets = process.genJetAK8Table.src
47 process.genJetAK8FlavourTable.src = process.genJetAK8Table.src
48 process.particleLevel.particleMaxEta = 999.
49 process.particleLevel.lepMinPt = 0.
50 process.particleLevel.lepMaxEta = 999.
51 process.genJetFlavourTable.jetFlavourInfos =
"genJetFlavourAssociation" 59 process.nanogenSequence.insert(0, process.genParticles2HepMCHiggsVtx)
60 process.nanogenSequence.insert(0, process.genParticles2HepMC)
61 process.nanogenSequence.insert(0, process.mergedGenParticles)
63 process.metMCTable.src =
"slimmedMETs" 64 process.metMCTable.variables.pt =
Var(
"genMET.pt", float, doc=
"pt")
65 process.metMCTable.variables.phi =
Var(
"genMET.phi", float, doc=
"phi")
66 process.metMCTable.variables.phi.precision = CandVars.phi.precision
68 process.rivetProducerHTXS.HepMCCollection =
"genParticles2HepMCHiggsVtx:unsmeared" 69 process.genParticleTable.src =
"prunedGenParticles" 70 process.patJetPartonsNano.particles =
"prunedGenParticles" 71 process.particleLevel.src =
"genParticles2HepMC:unsmeared" 73 process.genJetTable.src =
"slimmedGenJets" 74 process.genJetAK8Table.src =
"slimmedGenJetsAK8" 75 process.tauGenJetsForNano.GenParticles =
"prunedGenParticles" 76 process.genVisTaus.srcGenParticles =
"prunedGenParticles" 83 process.metMCTable.src =
"genMetTrue" 84 process.metMCTable.variables = cms.PSet(PTVars)
86 process.rivetProducerHTXS.HepMCCollection =
"generatorSmeared" 87 process.genParticleTable.src =
"genParticles" 88 process.patJetPartonsNano.particles =
"genParticles" 89 process.particleLevel.src =
"generatorSmeared" 91 process.genJetTable.src =
"ak4GenJetsNoNu" 92 process.genJetAK8Table.src =
"ak8GenJetsNoNu" 93 process.tauGenJetsForNano.GenParticles =
"genParticles" 94 process.genVisTaus.srcGenParticles =
"genParticles" 97 process.nanogenSequence.remove(process.genParticles2HepMCHiggsVtx)
98 process.nanogenSequence.remove(process.genParticles2HepMC)
99 process.nanogenSequence.remove(process.mergedGenParticles)
105 process.finalGenParticles.src = process.genParticleTable.src.getModuleLabel()
106 process.genParticleTable.src =
"finalGenParticles" 107 process.nanogenSequence.insert(0, process.finalGenParticles)
112 if process.nanogenSequence.contains(process.mergedGenParticles):
113 raise ValueError(
"Applying the MiniAOD genParticle pruner to MiniAOD is redunant. " \
114 "Use a different customization.")
116 process.prunedGenParticles = prunedGenParticles.clone()
117 process.prunedGenParticles.src =
"genParticles" 118 process.genParticleTable.src =
"prunedGenParticles" 120 process.nanogenSequence.insert(0, process.prunedGenParticles)
131 process.genParticleTable.variables.pt.precision = precision
132 process.genJetTable.variables.pt.precision = precision
133 process.metMCTable.variables.pt.precision = precision
137 process.genParticleTable.variables.eta.precision = precision
138 process.genJetTable.variables.eta.precision = precision
142 process.genParticleTable.variables.phi.precision = precision
143 process.genJetTable.variables.phi.precision = precision
144 process.metMCTable.variables.phi.precision = precision
148 process.genParticleTable.variables.mass.precision = precision
149 process.genJetTable.variables.mass.precision = precision
153 process.lheInfoTable.precision = 23
157 process.genWeightsTable.lheWeightPrecision = 23
def pruneGenParticlesMini(process)
def setGenMassPrecision(process, precision)
def Var(expr, valtype, doc=None, precision=-1)
def customizeNanoGEN(process)
def setLHEFullPrecision(process)
def setGenPhiPrecision(process, precision)
def setGenPtPrecision(process, precision)
def nanoGenCommonCustomize(process)
def pruneGenParticlesNano(process)
def setGenFullPrecision(process)
def setGenWeightsFullPrecision(process)
def customizeNanoGENFromMini(process)
def setGenEtaPrecision(process, precision)