Skip to content

Commit

Permalink
replace explict configuration with a reference from cfipython/, gener…
Browse files Browse the repository at this point in the history
…ated by PuppiProducer::fillDescriptions
  • Loading branch information
slava77devel committed Mar 17, 2021
1 parent 824dff7 commit 162ce95
Showing 1 changed file with 16 additions and 42 deletions.
58 changes: 16 additions & 42 deletions CommonTools/PileupAlgos/python/Puppi_cff.py
Expand Up @@ -24,48 +24,23 @@
)
)

puppi = cms.EDProducer("PuppiProducer",#cms.PSet(#"PuppiProducer",
puppiDiagnostics = cms.bool(False),
puppiNoLep = cms.bool(False),
UseFromPVLooseTight = cms.bool(False),
UseDeltaZCut = cms.bool(True),
EtaMinUseDeltaZ = cms.double(2.4),
DeltaZCut = cms.double(0.3),
NumOfPUVtxsForCharged = cms.uint32(2),
DeltaZCutForChargedFromPUVtxs = cms.double(0.2),
PtMaxCharged = cms.double(20.),
EtaMaxCharged = cms.double(99999.),
PtMaxPhotons = cms.double(-1.),
EtaMaxPhotons = cms.double(2.5),
PtMaxNeutrals = cms.double(200.),
PtMaxNeutralsStartSlope = cms.double(20.),
candName = cms.InputTag('particleFlow'),
vertexName = cms.InputTag('offlinePrimaryVertices'),
# from cfipython/, generated by PuppiProducer::fillDescriptions
import CommonTools.PileupAlgos.PuppiProducer_cfi as _mod
puppi = _mod.PuppiProducer.clone(
EtaMinUseDeltaZ = 2.4,
NumOfPUVtxsForCharged = 2,
PtMaxCharged = 20.,
PtMaxNeutralsStartSlope = 20.,
#candName = cms.string('packedPFCandidates'),
#vertexName = cms.string('offlineSlimmedPrimaryVertices'),
applyCHS = cms.bool (True),
invertPuppi = cms.bool (False),
useExp = cms.bool (False),
MinPuppiWeight = cms.double(0.01),
useExistingWeights = cms.bool(False),
clonePackedCands = cms.bool(False), # should only be set to True for MiniAOD
vtxNdofCut = cms.int32(4),
vtxZCut = cms.double(24),
usePUProxyValue = cms.bool(False),
PUProxyValue = cms.InputTag(''),
algos = cms.VPSet(
cms.PSet(
etaMin = cms.vdouble(0.),
etaMax = cms.vdouble(2.5),
ptMin = cms.vdouble(0.),
MinNeutralPt = cms.vdouble(0.2),
MinNeutralPtSlope = cms.vdouble(0.015),
RMSEtaSF = cms.vdouble(1.0),
MedEtaSF = cms.vdouble(1.0),
EtaMaxExtrap = cms.double(2.0),
clonePackedCands = False, # should only be set to True for MiniAOD
algos = {
0: dict(
puppiAlgos = puppiCentral
),
cms.PSet(
)
} #only one PSet is defined in reference
)
puppi.algos.append(cms.PSet(
etaMin = cms.vdouble( 2.5, 3.0),
etaMax = cms.vdouble( 3.0, 10.0),
ptMin = cms.vdouble( 0.0, 0.0),
Expand All @@ -75,7 +50,8 @@
MedEtaSF = cms.vdouble(0.90, 0.75),
EtaMaxExtrap = cms.double( 2.0),
puppiAlgos = puppiForward
),
)
)
# cms.PSet(
# etaMin = cms.double(3.0),
# etaMax = cms.double(10.0),
Expand All @@ -89,8 +65,6 @@
# EtaMaxExtrap = cms.double(2.0),
# puppiAlgos = puppiForward
# )
)
)

from Configuration.Eras.Modifier_phase2_common_cff import phase2_common
phase2_common.toModify(
Expand Down

0 comments on commit 162ce95

Please sign in to comment.