1 import FWCore.ParameterSet.Config
as cms
8 from RecoEgamma.EgammaIsolationAlgos.egammaHBHERecHitThreshold_cff
import egammaHBHERecHit
10 from RecoEgamma.EgammaIsolationAlgos.egammaEcalPFClusterIsolationProducerRecoPhoton_cfi
import egammaEcalPFClusterIsolationProducerRecoPhoton
11 from RecoEgamma.EgammaIsolationAlgos.egammaHcalPFClusterIsolationProducerRecoPhoton_cfi
import egammaHcalPFClusterIsolationProducerRecoPhoton
16 photons = cms.EDProducer(
"GEDPhotonProducer",
17 photonProducer = cms.InputTag(
"photonCore"),
18 reconstructionStep = cms.string(
"tmp"),
19 outputPhotonCollection = cms.string(
""),
20 pfEgammaCandidates = cms.InputTag(
""),
21 valueMapPhotons = cms.string(
""),
23 regressionWeightsFromDB = cms.bool(
True),
24 energyRegressionWeightsFileLocation = cms.string(
'/afs/cern.ch/user/b/bendavid/cmspublic/regweights/gbrph.root'),
25 energyRegressionWeightsDBLocation = cms.string(
'wgbrph'),
26 superClusterEnergyCorrFunction = cms.string(
"EcalClusterEnergyCorrection"),
27 superClusterEnergyErrorFunction = cms.string(
"EcalClusterEnergyUncertainty"),
28 superClusterCrackEnergyCorrFunction = cms.string(
"EcalClusterCrackCorrection"),
29 photonEcalEnergyCorrFunction = cms.string(
"EcalClusterEnergyCorrectionObjectSpecific"),
31 candidateP4type = cms.string(
"fromEcalEnergy"),
32 isolationSumsCalculatorSet = cms.PSet(isolationSumsCalculator),
33 mipVariableSet = cms.PSet(mipVariable),
34 mvaBasedHaloVariableSet = cms.PSet(mvaHaloVariable),
35 usePrimaryVertex = cms.bool(
True),
36 primaryVertexProducer = cms.InputTag(
'offlinePrimaryVerticesWithBS'),
37 posCalc_t0_endcPresh = cms.double(3.6),
38 posCalc_logweight = cms.bool(
True),
39 posCalc_w0 = cms.double(4.2),
40 hbheInstance = cms.string(
''),
41 posCalc_t0_endc = cms.double(6.3),
42 barrelEcalHits = cms.InputTag(
"ecalRecHit",
"EcalRecHitsEB"),
43 hbheModule = cms.string(
'hbhereco'),
44 endcapEcalHits = cms.InputTag(
"ecalRecHit",
"EcalRecHitsEE"),
45 preshowerHits = cms.InputTag(
"ecalPreshowerRecHit",
"EcalRecHitsES"),
46 runMIPTagger = cms.bool(
True),
47 runMVABasedHaloTagger = cms.bool(
False),
48 highEt = cms.double(100.),
49 minR9Barrel = cms.double(0.94),
50 minR9Endcap = cms.double(0.95),
51 multThresEB = cms.double(1.00),
52 multThresEE = cms.double(1.25),
53 hOverEConeSize = cms.double(0.15),
54 hbheRecHits = egammaHBHERecHit.hbheRecHits,
55 recHitEThresholdHB = egammaHBHERecHit.recHitEThresholdHB,
56 recHitEThresholdHE = egammaHBHERecHit.recHitEThresholdHE,
57 usePFThresholdsFromDB = egammaHBHERecHit.usePFThresholdsFromDB,
58 maxHcalRecHitSeverity = egammaHBHERecHit.maxHcalRecHitSeverity,
59 hcalRun2EffDepth = cms.bool(
False),
60 posCalc_x0 = cms.double(0.89),
61 posCalc_t0_barl = cms.double(7.7),
62 minSCEtBarrel = cms.double(10.0),
63 minSCEtEndcap = cms.double(10.0),
64 maxHoverEBarrel = cms.double(0.5),
65 maxHoverEEndcap = cms.double(0.5),
66 ecalRecHitSumEtOffsetBarrel = cms.double(999999999),
67 ecalRecHitSumEtSlopeBarrel = cms.double(0.),
68 ecalRecHitSumEtOffsetEndcap = cms.double(999999999),
69 ecalRecHitSumEtSlopeEndcap = cms.double(0.),
70 hcalRecHitSumEtOffsetBarrel = cms.double(999999999),
71 hcalRecHitSumEtSlopeBarrel = cms.double(0.),
72 hcalRecHitSumEtOffsetEndcap = cms.double(999999999),
73 hcalRecHitSumEtSlopeEndcap = cms.double(0.),
74 nTrackSolidConeBarrel =cms.double(999999999),
75 nTrackSolidConeEndcap =cms.double(999999999),
76 nTrackHollowConeBarrel =cms.double(999999999),
77 nTrackHollowConeEndcap =cms.double(999999999),
78 trackPtSumSolidConeBarrel =cms.double(999999999),
79 trackPtSumSolidConeEndcap =cms.double(999999999),
80 trackPtSumHollowConeBarrel =cms.double(999999999),
81 trackPtSumHollowConeEndcap =cms.double(999999999),
82 sigmaIetaIetaCutBarrel=cms.double(999999999),
83 sigmaIetaIetaCutEndcap=cms.double(999999999),
84 posCalcParameters = cms.PSet( T0_barl = cms.double(7.4),
85 T0_endc = cms.double(6.3),
86 T0_endcPresh = cms.double(3.6),
87 LogWeighted = cms.bool(
True),
92 RecHitFlagToBeExcludedEB = cleanedHybridSuperClusters.RecHitFlagToBeExcluded,
93 RecHitSeverityToBeExcludedEB = cleanedHybridSuperClusters.RecHitSeverityToBeExcluded,
94 RecHitFlagToBeExcludedEE = multi5x5BasicClustersCleaned.RecHitFlagToBeExcluded,
95 RecHitSeverityToBeExcludedEE = cleanedHybridSuperClusters.RecHitSeverityToBeExcluded,
96 checkHcalStatus = cms.bool(
True),
97 PhotonDNNPFid = cms.PSet(
98 enabled = cms.bool(
False),
99 inputTensorName = cms.string(
"FirstLayer_input"),
100 outputTensorName = cms.string(
"sequential/FinalLayer/Sigmoid"),
101 modelsFiles = cms.vstring(
102 'RecoEgamma/PhotonIdentification/data/Photon_PFID_dnn/v1/EB/EB_modelDNN.pb',
103 'RecoEgamma/PhotonIdentification/data/Photon_PFID_dnn/v1/EE/EE_modelDNN.pb'),
104 scalersFiles = cms.vstring(
105 'RecoEgamma/PhotonIdentification/data/Photon_PFID_dnn/v1/EB/EB_scaler.txt',
106 'RecoEgamma/PhotonIdentification/data/Photon_PFID_dnn/v1/EE/EE_scaler.txt' 108 outputDim = cms.vuint32(1,1),
109 useEBModelInGap = cms.bool(
True)
111 pfECALClusIsolCfg = cms.PSet(
112 pfClusterProducer = egammaEcalPFClusterIsolationProducerRecoPhoton.pfClusterProducer,
113 drMax = egammaEcalPFClusterIsolationProducerRecoPhoton.drMax,
114 drVetoBarrel = egammaEcalPFClusterIsolationProducerRecoPhoton.drVetoBarrel,
115 drVetoEndcap = egammaEcalPFClusterIsolationProducerRecoPhoton.drVetoEndcap,
116 etaStripBarrel = egammaEcalPFClusterIsolationProducerRecoPhoton.etaStripBarrel,
117 etaStripEndcap = egammaEcalPFClusterIsolationProducerRecoPhoton.etaStripEndcap,
118 energyBarrel = egammaEcalPFClusterIsolationProducerRecoPhoton.energyBarrel,
119 energyEndcap = egammaEcalPFClusterIsolationProducerRecoPhoton.energyEndcap
122 pfHCALClusIsolCfg = cms.PSet(
124 pfClusterProducerHCAL = egammaHcalPFClusterIsolationProducerRecoPhoton.pfClusterProducerHCAL,
125 useHF = egammaHcalPFClusterIsolationProducerRecoPhoton.useHF,
126 pfClusterProducerHFEM = egammaHcalPFClusterIsolationProducerRecoPhoton.pfClusterProducerHFEM,
127 pfClusterProducerHFHAD = egammaHcalPFClusterIsolationProducerRecoPhoton.pfClusterProducerHFHAD,
128 drMax = egammaHcalPFClusterIsolationProducerRecoPhoton.drMax,
129 drVetoBarrel = egammaHcalPFClusterIsolationProducerRecoPhoton.drVetoBarrel,
130 drVetoEndcap = egammaHcalPFClusterIsolationProducerRecoPhoton.drVetoEndcap,
131 etaStripBarrel = egammaHcalPFClusterIsolationProducerRecoPhoton.etaStripBarrel,
132 etaStripEndcap = egammaHcalPFClusterIsolationProducerRecoPhoton.etaStripEndcap,
133 energyBarrel = egammaHcalPFClusterIsolationProducerRecoPhoton.energyBarrel,
134 energyEndcap = egammaHcalPFClusterIsolationProducerRecoPhoton.energyEndcap,
135 useEt = egammaHcalPFClusterIsolationProducerRecoPhoton.useEt,
141 photonsHGC = photons.clone(
142 photonProducer =
'photonCoreHGC' 145 islandPhotons = cms.EDProducer(
"PhotonProducer",
146 photonCoreProducer = cms.InputTag(
"islandPhotonCore"),
147 regressionWeightsFromDB = cms.bool(
True),
148 energyRegressionWeightsFileLocation = cms.string(
'/afs/cern.ch/user/b/bendavid/cmspublic/regweights/gbrph.root'),
149 energyRegressionWeightsDBLocation = cms.string(
'wgbrph'),
150 superClusterEnergyCorrFunction = cms.string(
"EcalClusterEnergyCorrection"),
151 superClusterEnergyErrorFunction = cms.string(
"EcalClusterEnergyUncertainty"),
152 superClusterCrackEnergyCorrFunction = cms.string(
"EcalClusterCrackCorrection"),
153 photonEcalEnergyCorrFunction = cms.string(
"EcalClusterEnergyCorrectionObjectSpecific"),
154 candidateP4type = cms.string(
"fromEcalEnergy"),
155 isolationSumsCalculatorSet = cms.PSet(isolationSumsCalculator),
156 mipVariableSet = cms.PSet(mipVariable),
157 usePrimaryVertex = cms.bool(
True),
158 primaryVertexProducer = cms.InputTag(
'offlinePrimaryVerticesWithBS'),
159 posCalc_t0_endcPresh = cms.double(3.6),
160 posCalc_logweight = cms.bool(
True),
161 posCalc_w0 = cms.double(4.2),
162 hbheInstance = cms.string(
''),
163 posCalc_t0_endc = cms.double(6.3),
164 barrelEcalHits = cms.InputTag(
"ecalRecHit",
"EcalRecHitsEB"),
165 hbheModule = cms.string(
'hbhereco'),
166 endcapEcalHits = cms.InputTag(
"ecalRecHit",
"EcalRecHitsEE"),
167 runMIPTagger = cms.bool(
True),
168 runMVABasedHaloTagger = cms.bool(
False),
169 highEt = cms.double(100.),
170 minR9Barrel = cms.double(10.0),
171 minR9Endcap = cms.double(10.0),
172 hOverEConeSize = cms.double(0.15),
173 hbheRecHits = egammaHBHERecHit.hbheRecHits,
174 recHitEThresholdHB = egammaHBHERecHit.recHitEThresholdHB,
175 recHitEThresholdHE = egammaHBHERecHit.recHitEThresholdHE,
176 usePFThresholdsFromDB = egammaHBHERecHit.usePFThresholdsFromDB,
177 maxHcalRecHitSeverity = egammaHBHERecHit.maxHcalRecHitSeverity,
178 hcalRun2EffDepth = cms.bool(
False),
179 posCalc_x0 = cms.double(0.89),
180 posCalc_t0_barl = cms.double(7.7),
181 minSCEtBarrel = cms.double(5.0),
182 minSCEtEndcap = cms.double(15.0),
183 maxHoverEBarrel = cms.double(0.99),
184 maxHoverEEndcap = cms.double(0.5),
185 ecalRecHitSumEtOffsetBarrel = cms.double(999999999),
186 ecalRecHitSumEtSlopeBarrel = cms.double(0.),
187 ecalRecHitSumEtOffsetEndcap = cms.double(999999999),
188 ecalRecHitSumEtSlopeEndcap = cms.double(0.),
189 hcalRecHitSumEtOffsetBarrel = cms.double(999999999),
190 hcalRecHitSumEtSlopeBarrel = cms.double(0.),
191 hcalRecHitSumEtOffsetEndcap = cms.double(999999999),
192 hcalRecHitSumEtSlopeEndcap = cms.double(0.),
193 nTrackSolidConeBarrel =cms.double(999999999),
194 nTrackSolidConeEndcap =cms.double(999999999),
195 nTrackHollowConeBarrel =cms.double(999999999),
196 nTrackHollowConeEndcap =cms.double(999999999),
197 trackPtSumSolidConeBarrel =cms.double(999999999),
198 trackPtSumSolidConeEndcap =cms.double(999999999),
199 trackPtSumHollowConeBarrel =cms.double(999999999),
200 trackPtSumHollowConeEndcap =cms.double(999999999),
201 sigmaIetaIetaCutBarrel=cms.double(999999999),
202 sigmaIetaIetaCutEndcap=cms.double(999999999),
203 posCalcParameters = cms.PSet( T0_barl = cms.double(7.4),
204 T0_endc = cms.double(6.3),
205 T0_endcPresh = cms.double(3.6),
206 LogWeighted = cms.bool(
True),
207 W0 = cms.double(4.2),
208 X0 = cms.double(0.89)
211 RecHitFlagToBeExcludedEB = cleanedHybridSuperClusters.RecHitFlagToBeExcluded,
212 RecHitSeverityToBeExcludedEB = cleanedHybridSuperClusters.RecHitSeverityToBeExcluded,
213 RecHitFlagToBeExcludedEE = multi5x5BasicClustersCleaned.RecHitFlagToBeExcluded,
214 RecHitSeverityToBeExcludedEE = cleanedHybridSuperClusters.RecHitSeverityToBeExcluded,
217 from Configuration.ProcessModifiers.egamma_lowPt_exclusive_cff
import egamma_lowPt_exclusive
218 egamma_lowPt_exclusive.toModify(photons,