CMS 3D CMS Logo

PFBRECO_cff.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 
3 # getting the ptrs
4 from RecoParticleFlow.PFProducer.pfLinker_cff import particleFlowPtrs
5 
8 pfPileUpIsoPFBRECO = pfPileUp.clone( PFCandidates = 'particleFlowPtrs' )
9 from Configuration.ProcessModifiers.pp_on_AA_cff import pp_on_AA
10 pp_on_AA.toModify(pfPileUpIsoPFBRECO, Enable = False)
11 
12 pfNoPileUpIsoPFBRECO = pfNoPileUp.clone( topCollection = 'pfPileUpIsoPFBRECO',
13  bottomCollection = 'particleFlowPtrs')
14 pfNoPileUpIsoPFBRECOTask = cms.Task(
15  pfPileUpIsoPFBRECO,
16  pfNoPileUpIsoPFBRECO
17  )
18 pfNoPileUpIsoPFBRECOSequence = cms.Sequence(pfNoPileUpIsoPFBRECOTask)
19 
21 
22 pfPileUpPFBRECO = pfPileUp.clone( PFCandidates = 'particleFlowPtrs' )
23 pfNoPileUpPFBRECO = pfNoPileUp.clone( topCollection = 'pfPileUpPFBRECO',
24  bottomCollection = 'particleFlowPtrs')
25 pfNoPileUpPFBRECOTask = cms.Task(
26  pfPileUpPFBRECO,
27  pfNoPileUpPFBRECO
28  )
29 pfNoPileUpPFBRECOSequence = cms.Sequence(pfNoPileUpPFBRECOTask)
30 
32 pfAllNeutralHadronsPFBRECO = pfAllNeutralHadrons.clone( src = 'pfNoPileUpIsoPFBRECO' )
34 pfAllChargedHadronsPFBRECO = pfAllChargedHadrons.clone( src = 'pfNoPileUpIsoPFBRECO' )
36 pfAllPhotonsPFBRECO = pfAllPhotons.clone( src = 'pfNoPileUpIsoPFBRECO' )
38 pfAllMuonsPFBRECO = pfAllMuons.clone( src = 'pfNoPileUpPFBRECO' )
39 pfAllMuonsClonesPFBRECO = pfAllMuonsClones.clone( src = 'pfAllMuonsPFBRECO' )
41 pfAllElectronsPFBRECO = pfAllElectrons.clone( src = 'pfNoMuonPFBRECO' )
42 pfAllElectronsClonesPFBRECO = pfAllElectronsClones.clone( src = 'pfAllElectronsPFBRECO' )
44 pfAllChargedParticlesPFBRECO = pfAllChargedParticles.clone( src = 'pfNoPileUpIsoPFBRECO' )
46 pfAllNeutralHadronsAndPhotonsPFBRECO = pfAllNeutralHadronsAndPhotons.clone( src = 'pfNoPileUpIsoPFBRECO' )
47 pfPileUpAllChargedParticlesPFBRECO = pfAllChargedParticles.clone( src = 'pfPileUpIsoPFBRECO' )
48 pfSortByTypePFBRECOTask = cms.Task(
49  pfAllNeutralHadronsPFBRECO,
50  pfAllChargedHadronsPFBRECO,
51  pfAllPhotonsPFBRECO,
52  # charged hadrons + electrons + muons
53  pfAllChargedParticlesPFBRECO,
54  # same, but from pile up
55  pfPileUpAllChargedParticlesPFBRECO,
56  pfAllNeutralHadronsAndPhotonsPFBRECO
57 # +
58 # pfAllElectronsPFBRECO+
59 # pfAllMuonsPFBRECO
60  )
61 pfSortByTypePFBRECOSequence = cms.Sequence(pfSortByTypePFBRECOTask)
62 
63 pfParticleSelectionPFBRECOTask = cms.Task(
64  pfNoPileUpIsoPFBRECOTask,
65  # In principle JME sequence should go here, but this is used in RECO
66  # in addition to here, and is used in the "first-step" PF process
67  # so needs to go later.
68  #pfNoPileUpJMESequence +
69  pfNoPileUpPFBRECOTask,
70  pfSortByTypePFBRECOTask
71  )
72 pfParticleSelectionPFBRECOSequence = cms.Sequence(pfParticleSelectionPFBRECOTask)
73 
75 pfSelectedPhotonsPFBRECO = pfSelectedPhotons.clone( src = 'pfAllPhotonsPFBRECO' )
78 pfIsolatedPhotonsPFBRECO = pfIsolatedPhotons.clone( src = 'pfSelectedPhotonsPFBRECO',
79  isolationValueMapsCharged = cms.VInputTag( cms.InputTag("phPFIsoValueCharged04PFIdPFBRECO") ),
80  isolationValueMapsNeutral = cms.VInputTag( cms.InputTag("phPFIsoValueNeutral04PFIdPFBRECO"),
81  cms.InputTag("phPFIsoValueGamma04PFIdPFBRECO") ),
82  deltaBetaIsolationValueMap = 'phPFIsoValuePU04PFIdPFBRECO' )
83 pfPhotonPFBRECOSequence = cms.Sequence(
84  pfSelectedPhotonsPFBRECO +
85  pfPhotonIsolationPFBRECOSequence +
86  # selecting isolated photons:
87  pfIsolatedPhotonsPFBRECO
88  )
89 
91 pfMuonsFromVertexPFBRECO = pfMuonsFromVertex.clone( src = 'pfAllMuonsPFBRECO' )
93 pfIsolatedMuonsPFBRECO = pfIsolatedMuons.clone( src = 'pfMuonsFromVertexPFBRECO' )
94 pfMuonsPFBRECO = pfIsolatedMuonsPFBRECO.clone(cut = cms.string("pt > 5 & muonRef.isAvailable()"))
95 pfMuonPFBRECOSequence = cms.Sequence(
96  pfAllMuonsPFBRECO +
97  pfMuonsFromVertexPFBRECO +
98  pfIsolatedMuonsPFBRECO+
99  pfMuonsPFBRECO
100  )
101 
103 pfElectronsFromVertexPFBRECO = pfElectronsFromVertex.clone( src = 'pfAllElectronsPFBRECO' )
105 pfIsolatedElectronsPFBRECO = pfIsolatedElectrons.clone( src = 'pfElectronsFromVertexPFBRECO' )
106 pfElectronsPFBRECO = pfIsolatedElectronsPFBRECO.clone( cut = cms.string(" pt > 5 & gsfElectronRef.isAvailable() & gsfTrackRef.hitPattern().numberOfLostHits('MISSING_INNER_HITS')<2"))
107 pfElectronPFBRECOSequence = cms.Sequence(
108  pfAllElectronsPFBRECO +
109  pfElectronsFromVertexPFBRECO +
110  pfIsolatedElectronsPFBRECO +
111  pfElectronsPFBRECO
112  )
113 
114 from CommonTools.ParticleFlow.Tools.jetTools import jetAlgo
115 pfJetsPFBRECO = jetAlgo('AK4')
116 pfJetsPFBRECO.src = 'pfNoElectronJMEPFBRECO'
117 pfJetsPtrsPFBRECO = cms.EDProducer("PFJetFwdPtrProducer",
118  src=cms.InputTag("pfJetsPFBRECO")
119  )
120 pfJetPFBRECOSequence = cms.Sequence(
121  pfJetsPFBRECO +
122  pfJetsPtrsPFBRECO
123  )
124 
126 
128 pfMETPFBRECO = pfMET.clone( srcJets = 'pfJetsPFBRECO' )
129 
130 
139 
140 # sequential top projection cleaning
142 pfNoMuonPFBRECO = pfNoMuon.clone( topCollection = 'pfIsolatedMuonsPFBRECO',
143  bottomCollection = 'pfNoPileUpPFBRECO' )
144 pfNoMuonJMEPFBRECO = pfNoMuonJME.clone( topCollection = 'pfIsolatedMuonsPFBRECO' )
146 pfNoElectronPFBRECO = pfNoElectron.clone( topCollection = 'pfIsolatedElectronsPFBRECO',
147  bottomCollection = 'pfNoMuonPFBRECO' )
148 pfNoElectronJMEPFBRECO = pfNoElectronJME.clone( topCollection = 'pfIsolatedElectronsPFBRECO',
149  bottomCollection = 'pfNoMuonJMEPFBRECO' )
150 pfNoElectronJMEClonesPFBRECO = pfNoElectronJMEClones.clone( src = 'pfNoElectronJMEPFBRECO' )
152 pfNoJetPFBRECO = pfNoJet.clone( topCollection = 'pfJetsPtrsPFBRECO',
153  bottomCollection = 'pfNoElectronJMEPFBRECO' )
155 pfNoTauPFBRECO = pfNoTau.clone ( bottomCollection = 'pfJetsPtrsPFBRECO' )
156 pfNoTauClonesPFBRECO = pfNoTauClones.clone ( src = 'pfNoTauPFBRECO' )
157 
158 # generator tools
160 
161 PFBRECO = cms.Sequence(
162  particleFlowPtrs +
163  pfParticleSelectionPFBRECOSequence +
164  pfNoPileUpJMESequence +
165 # pfDeltaBetaWeightingPFBRECOSequence +
166  pfPhotonPFBRECOSequence +
167  pfMuonPFBRECOSequence +
168  pfNoMuonPFBRECO +
169  pfNoMuonJMEPFBRECO +
170  pfElectronPFBRECOSequence +
171  pfNoElectronPFBRECO +
172  pfNoElectronJMEPFBRECO +
173  pfNoElectronJMEClonesPFBRECO+
174  pfJetPFBRECOSequence +
175  pfNoJetPFBRECO +
176  pfTauSequence +
177  pfNoTauPFBRECO +
178  pfMETPFBRECO
179  )
pfTaus_cff
pfNoPileUpJME_cff
pfIsolatedPhotons_cfi
pfAllNeutralHadronsAndPhotons_cfi
genForPF2PAT_cff
pfPhotonIsolationPFBRECO_cff
pfSelectedPhotons_cfi
pfAllChargedHadrons_cfi
dataCertificationJetMET_cfi.jetAlgo
jetAlgo
Definition: dataCertificationJetMET_cfi.py:29
pfMuonsFromVertex_cfi
pfLinker_cff
pfAllChargedParticles_cfi
pfNoElectron_cfi
pfAllNeutralHadrons_cfi
pfNoMuon_cfi
pfNoJet_cff
pfIsolatedElectrons_cfi
pfElectronsFromVertex_cfi
pfNoTau_cff
pfAllPhotons_cfi
pfMET_cfi
pfPileUp_cfi
pfIsolatedMuons_cfi
pfAllElectrons_cfi
pfNoPileUp_cfi
pfAllMuons_cfi