CMS 3D CMS Logo

globals_cff.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
3 
4 rhoTable = cms.EDProducer("GlobalVariablesTableProducer",
5  variables = cms.PSet(
6  fixedGridRhoFastjetAll = ExtVar( cms.InputTag("fixedGridRhoFastjetAll"), "double", doc = "rho from all PF Candidates, used e.g. for JECs" ),
7  fixedGridRhoFastjetCentralNeutral = ExtVar( cms.InputTag("fixedGridRhoFastjetCentralNeutral"), "double", doc = "rho from neutral PF Candidates with |eta| < 2.5, used e.g. for rho corrections of some lepton isolations" ),
8  fixedGridRhoFastjetCentralCalo = ExtVar( cms.InputTag("fixedGridRhoFastjetCentralCalo"), "double", doc = "rho from calo towers with |eta| < 2.5, used e.g. egamma PFCluster isolation" ),
9  fixedGridRhoFastjetCentral = ExtVar( cms.InputTag("fixedGridRhoFastjetCentral"), "double", doc = "rho from all PF Candidates for central region, used e.g. for JECs" ),
10  fixedGridRhoFastjetCentralChargedPileUp = ExtVar( cms.InputTag("fixedGridRhoFastjetCentralChargedPileUp"), "double", doc = "rho from charged PF Candidates for central region, used e.g. for JECs" ),
11  )
12 )
13 
14 puTable = cms.EDProducer("NPUTablesProducer",
15  src = cms.InputTag("slimmedAddPileupInfo"),
16  pvsrc = cms.InputTag("offlineSlimmedPrimaryVertices"),
17  zbins = cms.vdouble( [0.0,1.7,2.6,3.0,3.5,4.2,5.2,6.0,7.5,9.0,12.0] ),
18  savePtHatMax = cms.bool(False),
19 )
20 
21 genTable = cms.EDProducer("SimpleGenEventFlatTableProducer",
22  src = cms.InputTag("generator"),
23  cut = cms.string(""),
24  name= cms.string("Generator"),
25  doc = cms.string("Generator information"),
26  singleton = cms.bool(True),
27  extension = cms.bool(False),
28  variables = cms.PSet(
29  x1 = Var( "?hasPDF?pdf().x.first:-1", float, doc="x1 fraction of proton momentum carried by the first parton",precision=14 ),
30  x2 = Var( "?hasPDF?pdf().x.second:-1", float, doc="x2 fraction of proton momentum carried by the second parton",precision=14 ),
31  xpdf1 = Var( "?hasPDF?pdf().xPDF.first:-1", float, doc="x*pdf(x) for the first parton", precision=14 ),
32  xpdf2 = Var( "?hasPDF?pdf().xPDF.second:-1", float, doc="x*pdf(x) for the second parton", precision=14 ),
33  id1 = Var( "?hasPDF?pdf().id.first:-1", int, doc="id of first parton", precision=6 ),
34  id2 = Var( "?hasPDF?pdf().id.second:-1", int, doc="id of second parton", precision=6 ),
35  scalePDF = Var( "?hasPDF?pdf().scalePDF:-1", float, doc="Q2 scale for PDF", precision=14 ),
36  binvar = Var("?hasBinningValues()?binningValues()[0]:-1", float, doc="MC generation binning value", precision=14),
37  weight = Var("weight()", float,doc="MC generator weight", precision=14),
38  ),
39 )
40 
41 globalTablesTask = cms.Task(rhoTable)
42 globalTablesMCTask = cms.Task(puTable,genTable)
common_cff
common_cff.Var
def Var(expr, valtype, compression=None, doc=None, mcOnly=False, precision=-1)
Definition: common_cff.py:20
common_cff.ExtVar
def ExtVar(tag, valtype, compression=None, doc=None, mcOnly=False, precision=-1)
Definition: common_cff.py:31