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 puppi = cms.EDProducer("PuppiProducer",#cms.PSet(#"PuppiProducer",
28  puppiDiagnostics = cms.bool(False),
29  puppiNoLep = cms.bool(False),
30  UseFromPVLooseTight = cms.bool(False),
31  UseDeltaZCut = cms.bool(True),
32  EtaMinUseDeltaZ = cms.double(2.4),
33  DeltaZCut = cms.double(0.3),
34  NumOfPUVtxsForCharged = cms.uint32(0),
35  DeltaZCutForChargedFromPUVtxs = cms.double(0.2),
36  PtMaxCharged = cms.double(20.),
37  EtaMaxCharged = cms.double(99999.),
38  PtMaxPhotons = cms.double(-1.),
39  EtaMaxPhotons = cms.double(2.5),
40  PtMaxNeutrals = cms.double(200.),
41  PtMaxNeutralsStartSlope = cms.double(20.),
42  candName = cms.InputTag('particleFlow'),
43  vertexName = cms.InputTag('offlinePrimaryVertices'),
44  #candName = cms.string('packedPFCandidates'),
45  #vertexName = cms.string('offlineSlimmedPrimaryVertices'),
46  applyCHS = cms.bool (True),
47  invertPuppi = cms.bool (False),
48  useExp = cms.bool (False),
49  MinPuppiWeight = cms.double(0.01),
50  useExistingWeights = cms.bool(False),
51  clonePackedCands = cms.bool(False), # should only be set to True for MiniAOD
52  vtxNdofCut = cms.int32(4),
53  vtxZCut = cms.double(24),
54  usePUProxyValue = cms.bool(False),
55  PUProxyValue = cms.InputTag(''),
56  algos = cms.VPSet(
57  cms.PSet(
58  etaMin = cms.vdouble(0.),
59  etaMax = cms.vdouble(2.5),
60  ptMin = cms.vdouble(0.),
61  MinNeutralPt = cms.vdouble(0.2),
62  MinNeutralPtSlope = cms.vdouble(0.015),
63  RMSEtaSF = cms.vdouble(1.0),
64  MedEtaSF = cms.vdouble(1.0),
65  EtaMaxExtrap = cms.double(2.0),
66  puppiAlgos = puppiCentral
67  ),
68  cms.PSet(
69  etaMin = cms.vdouble( 2.5, 3.0),
70  etaMax = cms.vdouble( 3.0, 10.0),
71  ptMin = cms.vdouble( 0.0, 0.0),
72  MinNeutralPt = cms.vdouble( 1.7, 2.0),
73  MinNeutralPtSlope = cms.vdouble(0.08, 0.08),
74  RMSEtaSF = cms.vdouble(1.20, 0.95),
75  MedEtaSF = cms.vdouble(0.90, 0.75),
76  EtaMaxExtrap = cms.double( 2.0),
77  puppiAlgos = puppiForward
78  ),
79  # cms.PSet(
80  # etaMin = cms.double(3.0),
81  # etaMax = cms.double(10.0),
82  # ptMin = cms.double(0.0),
83  # MinNeutralPt = cms.double(2.0),
84  # MinNeutralPtSlope = cms.double(0.07),
85  # # RMSEtaSF = cms.double(1.18),
86  # # MedEtaSF = cms.double(0.4397),
87  # RMSEtaSF = cms.double(1.10),
88  # MedEtaSF = cms.double(0.90),
89  # EtaMaxExtrap = cms.double(2.0),
90  # puppiAlgos = puppiForward
91  # )
92  )
93 )
94 
95 from Configuration.Eras.Modifier_phase2_common_cff import phase2_common
96 phase2_common.toModify(
97  puppi,
98  EtaMinUseDeltaZ = -1.,
99  PtMaxCharged = -1.,
100  PtMaxNeutralsStartSlope = 0.,
101  DeltaZCut = cms.double(0.1),
102  algos = cms.VPSet(
103  cms.PSet(
104  etaMin = cms.vdouble(0., 2.5),
105  etaMax = cms.vdouble(2.5, 3.5),
106  ptMin = cms.vdouble(0., 0.), #Normally 0
107  MinNeutralPt = cms.vdouble(0.2, 0.2),
108  MinNeutralPtSlope = cms.vdouble(0.015, 0.030),
109  RMSEtaSF = cms.vdouble(1.0, 1.0),
110  MedEtaSF = cms.vdouble(1.0, 1.0),
111  EtaMaxExtrap = cms.double(2.0),
112  puppiAlgos = puppiCentral
113  ), cms.PSet(
114  etaMin = cms.vdouble( 3.5),
115  etaMax = cms.vdouble(10.0),
116  ptMin = cms.vdouble( 0.), #Normally 0
117  MinNeutralPt = cms.vdouble( 2.0),
118  MinNeutralPtSlope = cms.vdouble(0.08),
119  RMSEtaSF = cms.vdouble(1.0 ),
120  MedEtaSF = cms.vdouble(0.75),
121  EtaMaxExtrap = cms.double( 2.0),
122  puppiAlgos = puppiForward
123  )
124  )
125 )
126 
127 puppiNoLep = puppi.clone(
128  puppiNoLep = True,
129  PtMaxPhotons = 20.
130  )