CMS 3D CMS Logo

Puppi_cff.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 
3 puppiCentral = cms.VPSet(
4  cms.PSet(
5  algoId = cms.int32(5), #0 is default Puppi
6  useCharged = cms.bool(True),
7  applyLowPUCorr = cms.bool(True),
8  combOpt = cms.int32(0),
9  cone = cms.double(0.4),
10  rmsPtMin = cms.double(0.1),
11  rmsScaleFactor = cms.double(1.0)
12  )
13  )
14 
15 puppiForward = cms.VPSet(
16  cms.PSet(
17  algoId = cms.int32(5), #0 is default Puppi
18  useCharged = cms.bool(False),
19  applyLowPUCorr = cms.bool(True),
20  combOpt = cms.int32(0),
21  cone = cms.double(0.4),
22  rmsPtMin = cms.double(0.5),
23  rmsScaleFactor = cms.double(1.0)
24  )
25  )
26 
27 # from cfipython/, generated by PuppiProducer::fillDescriptions
28 from CommonTools.ParticleFlow.pfNoPileUpJME_cff import primaryVertexAssociationJME
29 import CommonTools.PileupAlgos.PuppiProducer_cfi as _mod
30 puppi = _mod.PuppiProducer.clone(
31  UseDeltaZCutForPileup = False,
32  DeltaZCut = primaryVertexAssociationJME.assignment.maxDzForPrimaryAssignment,
33  EtaMinUseDeltaZ = primaryVertexAssociationJME.assignment.EtaMinUseDz,
34  PtMaxCharged = primaryVertexAssociationJME.assignment.PtMaxCharged,
35  NumOfPUVtxsForCharged = primaryVertexAssociationJME.assignment.NumOfPUVtxsForCharged,
36  DeltaZCutForChargedFromPUVtxs = primaryVertexAssociationJME.assignment.DzCutForChargedFromPUVtxs,
37  PtMaxNeutralsStartSlope = 20.,
38  PtMaxPhotons = 20.,
39  clonePackedCands = False, # should only be set to True for MiniAOD
40  algos = {
41  0: dict(
42  puppiAlgos = puppiCentral
43  )
44  } #only one PSet is defined in reference
45 )
46 puppi.algos.append(cms.PSet(
47  etaMin = cms.vdouble( 2.5, 3.0),
48  etaMax = cms.vdouble( 3.0, 10.0),
49  ptMin = cms.vdouble( 0.0, 0.0),
50  MinNeutralPt = cms.vdouble( 1.7, 2.0),
51  MinNeutralPtSlope = cms.vdouble(0.08, 0.08),
52  RMSEtaSF = cms.vdouble(1.20, 0.95),
53  MedEtaSF = cms.vdouble(0.90, 0.75),
54  EtaMaxExtrap = cms.double( 2.0),
55  puppiAlgos = puppiForward
56  )
57 )
58  # cms.PSet(
59  # etaMin = cms.double(3.0),
60  # etaMax = cms.double(10.0),
61  # ptMin = cms.double(0.0),
62  # MinNeutralPt = cms.double(2.0),
63  # MinNeutralPtSlope = cms.double(0.07),
64  # # RMSEtaSF = cms.double(1.18),
65  # # MedEtaSF = cms.double(0.4397),
66  # RMSEtaSF = cms.double(1.10),
67  # MedEtaSF = cms.double(0.90),
68  # EtaMaxExtrap = cms.double(2.0),
69  # puppiAlgos = puppiForward
70  # )
71 
72 from Configuration.Eras.Modifier_phase2_common_cff import phase2_common
73 phase2_common.toModify(
74  puppi,
75  EtaMinUseDeltaZ = 4.0,
76  DeltaZCut = 0.1,
77  algos = cms.VPSet(
78  cms.PSet(
79  etaMin = cms.vdouble(0., 2.5),
80  etaMax = cms.vdouble(2.5, 3.5),
81  ptMin = cms.vdouble(0., 0.), #Normally 0
82  MinNeutralPt = cms.vdouble(0.2, 0.2),
83  MinNeutralPtSlope = cms.vdouble(0.015, 0.030),
84  RMSEtaSF = cms.vdouble(1.0, 1.0),
85  MedEtaSF = cms.vdouble(1.0, 1.0),
86  EtaMaxExtrap = cms.double(2.0),
87  puppiAlgos = puppiCentral
88  ), cms.PSet(
89  etaMin = cms.vdouble( 3.5),
90  etaMax = cms.vdouble(10.0),
91  ptMin = cms.vdouble( 0.), #Normally 0
92  MinNeutralPt = cms.vdouble( 2.0),
93  MinNeutralPtSlope = cms.vdouble(0.08),
94  RMSEtaSF = cms.vdouble(1.0 ),
95  MedEtaSF = cms.vdouble(0.75),
96  EtaMaxExtrap = cms.double( 2.0),
97  puppiAlgos = puppiForward
98  )
99  )
100 )
101 
102 from Configuration.ProcessModifiers.pp_on_AA_cff import pp_on_AA
103 pp_on_AA.toModify(puppi, algos = [])
104 
105 puppiNoLep = puppi.clone(
106  puppiNoLep = True
107  )