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)+
29 cms.Sequence(genParticleTablesTask)+
30 cms.Sequence(genVertexTablesTask)+
33 cms.Sequence(particleLevelTablesTask)+
39 process.rivetMetTable.extension =
False
40 process.lheInfoTable.storeLHEParticles =
True
41 process.lheInfoTable.precision = 14
42 process.genWeightsTable.keepAllPSWeights =
True
43 process.genJetFlavourAssociation.jets = process.genJetTable.src
44 process.genJetFlavourTable.src = process.genJetTable.src
45 process.genJetAK8FlavourAssociation.jets = process.genJetAK8Table.src
46 process.genJetAK8FlavourTable.src = process.genJetAK8Table.src
47 process.particleLevel.particleMaxEta = 999.
48 process.particleLevel.lepMinPt = 0.
49 process.particleLevel.lepMaxEta = 999.
50 process.genJetFlavourTable.jetFlavourInfos =
"genJetFlavourAssociation"
58 process.nanogenSequence.insert(0, process.genParticles2HepMCHiggsVtx)
59 process.nanogenSequence.insert(0, process.genParticles2HepMC)
60 process.nanogenSequence.insert(0, process.mergedGenParticles)
62 process.metMCTable.src =
"slimmedMETs"
63 process.metMCTable.variables.pt =
Var(
"genMET.pt", float, doc=
"pt")
64 process.metMCTable.variables.phi =
Var(
"genMET.phi", float, doc=
"phi")
65 process.metMCTable.variables.phi.precision = CandVars.phi.precision
67 process.rivetProducerHTXS.HepMCCollection =
"genParticles2HepMCHiggsVtx:unsmeared"
68 process.genParticleTable.src =
"prunedGenParticles"
69 process.patJetPartonsNano.particles =
"prunedGenParticles"
70 process.particleLevel.src =
"genParticles2HepMC:unsmeared"
72 process.genJetTable.src =
"slimmedGenJets"
73 process.genJetAK8Table.src =
"slimmedGenJetsAK8"
74 process.tauGenJetsForNano.GenParticles =
"prunedGenParticles"
75 process.genVisTaus.srcGenParticles =
"prunedGenParticles"
82 process.metMCTable.src =
"genMetTrue"
83 process.metMCTable.variables = cms.PSet(PTVars)
85 process.rivetProducerHTXS.HepMCCollection =
"generatorSmeared"
86 process.genParticleTable.src =
"genParticles"
87 process.patJetPartonsNano.particles =
"genParticles"
88 process.particleLevel.src =
"generatorSmeared"
90 process.genJetTable.src =
"ak4GenJets"
91 process.genJetAK8Table.src =
"ak8GenJets"
92 process.tauGenJetsForNano.GenParticles =
"genParticles"
93 process.genVisTaus.srcGenParticles =
"genParticles"
96 process.nanogenSequence.remove(process.genParticles2HepMCHiggsVtx)
97 process.nanogenSequence.remove(process.genParticles2HepMC)
98 process.nanogenSequence.remove(process.mergedGenParticles)
104 process.finalGenParticles.src = process.genParticleTable.src.getModuleLabel()
105 process.genParticleTable.src =
"finalGenParticles"
106 process.nanogenSequence.insert(0, process.finalGenParticles)
111 if process.nanogenSequence.contains(process.mergedGenParticles):
112 raise ValueError(
"Applying the MiniAOD genParticle pruner to MiniAOD is redunant. " \
113 "Use a different customization.")
115 process.prunedGenParticles = prunedGenParticles.clone()
116 process.prunedGenParticles.src =
"genParticles"
117 process.genParticleTable.src =
"prunedGenParticles"
119 process.nanogenSequence.insert(0, process.prunedGenParticles)
130 process.genParticleTable.variables.pt.precision = precision
131 process.genJetTable.variables.pt.precision = precision
132 process.metMCTable.variables.pt.precision = precision
136 process.genParticleTable.variables.eta.precision = precision
137 process.genJetTable.variables.eta.precision = precision
141 process.genParticleTable.variables.phi.precision = precision
142 process.genJetTable.variables.phi.precision = precision
143 process.metMCTable.variables.phi.precision = precision
147 process.genParticleTable.variables.mass.precision = precision
148 process.genJetTable.variables.mass.precision = precision
152 process.lheInfoTable.precision = 23
156 process.genWeightsTable.lheWeightPrecision = 23