1 import FWCore.ParameterSet.Config
as cms
25 fixedGridRhoFastjetAllTmp = fixedGridRhoFastjetAll.clone(pfCandidatesTag =
"particleFlowTmp")
27 particleFlowTmpTask = cms.Task(particleFlowTmp)
28 particleFlowTmpSeq = cms.Sequence(particleFlowTmpTask)
30 particleFlowRecoTask = cms.Task( particleFlowTrackWithDisplacedVertexTask,
32 pfGsfElectronMVASelectionTask,
34 particleFlowEGammaFullTask,
36 fixedGridRhoFastjetAllTmp,
38 particleFlowEGammaFinalTask,
39 pfParticleSelectionTask )
40 particleFlowReco = cms.Sequence(particleFlowRecoTask)
42 particleFlowLinksTask = cms.Task( particleFlow, particleFlowPtrs, chargedHadronPFTrackIsolation, particleBasedIsolationTask)
43 particleFlowLinks = cms.Sequence(particleFlowLinksTask)
47 particleFlowTmpBarrel = particleFlowTmp.clone()
48 _phase2_hgcal_particleFlowTmp = cms.EDProducer(
49 "PFCandidateListMerger",
50 src = cms.VInputTag(
"particleFlowTmpBarrel",
55 from Configuration.Eras.Modifier_phase2_hgcal_cff
import phase2_hgcal
56 phase2_hgcal.toReplaceWith( particleFlowTmp, _phase2_hgcal_particleFlowTmp )
57 phase2_hgcal.toModify(
58 particleFlowTmpBarrel,
72 _phase2_hgcal_simPFTask = cms.Task( pfTrack ,
73 hgcalTrackCollection ,
75 quickTrackAssociatorByHits ,
76 particleFlowClusterHGCalFromSimCl ,
78 _phase2_hgcal_simPFSequence = cms.Sequence(_phase2_hgcal_simPFTask)
80 _phase2_hgcal_particleFlowRecoTask = cms.Task( _phase2_hgcal_simPFTask , particleFlowRecoTask.copy() )
81 _phase2_hgcal_particleFlowRecoTask.replace( particleFlowTmpTask, cms.Task( particleFlowTmpBarrel, particleFlowTmp ) )
83 phase2_hgcal.toReplaceWith( particleFlowRecoTask, _phase2_hgcal_particleFlowRecoTask )
87 from Configuration.Eras.Modifier_pp_on_XeXe_2017_cff
import pp_on_XeXe_2017
88 from Configuration.ProcessModifiers.pp_on_AA_cff
import pp_on_AA
90 for e
in [pp_on_XeXe_2017, pp_on_AA]:
91 e.toModify(particleFlowDisplacedVertexCandidate,
92 tracksSelectorParameters = dict(pt_min = 999999.0,
94 pt_min_prim = 999999.0,
98 e.toModify(particleFlowBlock, useNuclear = cms.bool(
False))
100 e.toModify(pfNoPileUpIso, enable = cms.bool(
False))
101 e.toModify(pfPileUpIso, enable = cms.bool(
False))
102 e.toModify(pfNoPileUp, enable = cms.bool(
False))
103 e.toModify(pfPileUp, enable = cms.bool(
False))
107 from Configuration.ProcessModifiers.mlpf_cff
import mlpf
108 from RecoParticleFlow.PFProducer.mlpfProducer_cfi
import mlpfProducer
110 _mlpfTask = cms.Task(mlpfProducer, particleFlowRecoTask.copy())
112 mlpf.toReplaceWith(particleFlowRecoTask, _mlpfTask)
118 if hasattr(process,
'particleFlowBlock'):
119 for i, pset
in enumerate(process.particleFlowBlock.elementImporters):
120 if pset.importerName.value() == name:
124 from Configuration.Eras.Modifier_phase2_hgcal_cff
import phase2_hgcal
126 if hasattr(process,
'particleFlowTmp'):
127 process.particleFlowTmp.src = [
'particleFlowTmpBarrel',
'simPFProducer']
129 if hasattr(process,
'particleFlowTmpBarrel'):
130 process.particleFlowTmpBarrel.vetoEndcap =
False
132 _insertTrackImportersWithVeto = {}
133 _trackImporters = [
'GeneralTracksImporter',
'ConvBremTrackImporter',
134 'ConversionTrackImporter',
'NuclearInteractionTrackImporter']
135 for importer
in _trackImporters:
137 _insertTrackImportersWithVeto[idx] = dict(
138 vetoMode = cms.uint32(0),
139 vetoSrc = cms.InputTag(
'hgcalTrackCollection:TracksInHGCal')
141 phase2_hgcal.toModify(
142 process.particleFlowBlock,
143 elementImporters = _insertTrackImportersWithVeto