1 import FWCore.ParameterSet.Config
as cms
2 import RecoTracker.IterativeTracking.iterativeTkConfig
as _cfg
3 from Configuration.Eras.Modifier_fastSim_cff
import fastSim
9 tobTecStepClusters = _cfg.clusterRemoverForIter(
"TobTecStep")
10 for _eraName, _postfix, _era
in _cfg.nonDefaultEras():
11 _era.toReplaceWith(tobTecStepClusters, _cfg.clusterRemoverForIter(
"TobTecStep", _eraName, _postfix))
15 tobTecStepSeedLayersTripl = cms.EDProducer(
"SeedingLayersEDProducer",
16 layerList = cms.vstring(
18 'TOB1+TOB2+MTOB3',
'TOB1+TOB2+MTOB4',
20 'TOB1+TOB2+MTEC1_pos',
'TOB1+TOB2+MTEC1_neg',
23 TTRHBuilder = cms.string(
'WithTrackAngle'), clusterChargeCut = cms.PSet(refToPSet_ = cms.string(
'SiStripClusterChargeCutTight')),
24 matchedRecHits = cms.InputTag(
"siStripMatchedRecHits",
"matchedRecHit"),
25 skipClusters = cms.InputTag(
'tobTecStepClusters')
28 TTRHBuilder = cms.string(
'WithTrackAngle'), clusterChargeCut = cms.PSet(refToPSet_ = cms.string(
'SiStripClusterChargeCutTight')),
29 skipClusters = cms.InputTag(
'tobTecStepClusters'),
30 rphiRecHits = cms.InputTag(
"siStripMatchedRecHits",
"rphiRecHit")
33 rphiRecHits = cms.InputTag(
"siStripMatchedRecHits",
"rphiRecHit"),
34 skipClusters = cms.InputTag(
'tobTecStepClusters'),
35 useRingSlector = cms.bool(
True),
36 TTRHBuilder = cms.string(
'WithTrackAngle'), clusterChargeCut = cms.PSet(refToPSet_ = cms.string(
'SiStripClusterChargeCutTight')),
37 minRing = cms.int32(6),
38 maxRing = cms.int32(7)
43 from RecoTracker.TkTrackingRegions.globalTrackingRegionFromBeamSpotFixedZ_cfi
import globalTrackingRegionFromBeamSpotFixedZ
as _globalTrackingRegionFromBeamSpotFixedZ
44 tobTecStepTrackingRegionsTripl = _globalTrackingRegionFromBeamSpotFixedZ.clone(RegionPSet =
dict(
46 originHalfLength = 20.0,
50 from Configuration.Eras.Modifier_pp_on_XeXe_2017_cff
import pp_on_XeXe_2017
51 from Configuration.Eras.Modifier_pp_on_AA_2018_cff
import pp_on_AA_2018
53 (pp_on_XeXe_2017 | pp_on_AA_2018).toReplaceWith(tobTecStepTrackingRegionsTripl,
54 _mixedTripletStepTrackingRegionsCommon_pp_on_HI.clone(RegionPSet=
dict(
55 ptMinScaling4BigEvts=
False,
64 tobTecStepClusterShapeHitFilter = _ClusterShapeHitFilterESProducer.clone(
65 ComponentName =
'tobTecStepClusterShapeHitFilter',
66 doStripShapeCut = cms.bool(
False),
67 clusterChargeCut =
dict(refToPSet_ =
'SiStripClusterChargeCutTight')
70 from RecoTracker.TkHitPairs.hitPairEDProducer_cfi
import hitPairEDProducer
as _hitPairEDProducer
71 tobTecStepHitDoubletsTripl = _hitPairEDProducer.clone(
72 seedingLayers =
"tobTecStepSeedLayersTripl",
73 trackingRegions =
"tobTecStepTrackingRegionsTripl",
75 produceIntermediateHitDoublets =
True,
77 from RecoTracker.TkSeedGenerator.multiHitFromChi2EDProducer_cfi
import multiHitFromChi2EDProducer
as _multiHitFromChi2EDProducer
78 tobTecStepHitTripletsTripl = _multiHitFromChi2EDProducer.clone(
79 doublets =
"tobTecStepHitDoubletsTripl",
82 from RecoTracker.TkSeedGenerator.seedCreatorFromRegionConsecutiveHitsEDProducer_cff
import seedCreatorFromRegionConsecutiveHitsEDProducer
as _seedCreatorFromRegionConsecutiveHitsTripletOnlyEDProducer
83 from RecoPixelVertexing.PixelLowPtUtilities.StripSubClusterShapeSeedFilter_cfi
import StripSubClusterShapeSeedFilter
as _StripSubClusterShapeSeedFilter
84 _tobTecStepSeedComparitorPSet =
dict(
85 ComponentName =
'CombinedSeedComparitor',
86 mode = cms.string(
"and"),
87 comparitors = cms.VPSet(
89 ComponentName = cms.string(
'PixelClusterShapeSeedComparitor'),
90 FilterAtHelixStage = cms.bool(
True),
91 FilterPixelHits = cms.bool(
False),
92 FilterStripHits = cms.bool(
True),
93 ClusterShapeHitFilterName = cms.string(
'tobTecStepClusterShapeHitFilter'),
94 ClusterShapeCacheSrc = cms.InputTag(
"siPixelClusterShapeCache")
96 _StripSubClusterShapeSeedFilter.clone()
99 tobTecStepSeedsTripl = _seedCreatorFromRegionConsecutiveHitsTripletOnlyEDProducer.clone(
100 seedingHitSets =
"tobTecStepHitTripletsTripl",
101 SeedComparitorPSet = _tobTecStepSeedComparitorPSet,
104 import FastSimulation.Tracking.TrajectorySeedProducer_cfi
105 _fastSim_tobTecStepSeedsTripl = FastSimulation.Tracking.TrajectorySeedProducer_cfi.trajectorySeedProducer.clone(
106 trackingRegions =
"tobTecStepTrackingRegionsTripl",
107 hitMasks = cms.InputTag(
"tobTecStepMasks"),
109 from FastSimulation.Tracking.SeedingMigration
import _hitSetProducerToFactoryPSet
111 _fastSim_tobTecStepSeedsTripl.seedFinderSelector.MultiHitGeneratorFactory.SeedComparitorPSet=cms.PSet( ComponentName = cms.string(
"none" ) )
112 _fastSim_tobTecStepSeedsTripl.seedFinderSelector.MultiHitGeneratorFactory.refitHits =
False 113 _fastSim_tobTecStepSeedsTripl.seedFinderSelector.layerList = tobTecStepSeedLayersTripl.layerList.value()
114 fastSim.toReplaceWith(tobTecStepSeedsTripl,_fastSim_tobTecStepSeedsTripl)
117 tobTecStepSeedLayersPair = cms.EDProducer(
"SeedingLayersEDProducer",
118 layerList = cms.vstring(
'TOB1+TEC1_pos',
'TOB1+TEC1_neg',
119 'TEC1_pos+TEC2_pos',
'TEC1_neg+TEC2_neg',
120 'TEC2_pos+TEC3_pos',
'TEC2_neg+TEC3_neg',
121 'TEC3_pos+TEC4_pos',
'TEC3_neg+TEC4_neg',
122 'TEC4_pos+TEC5_pos',
'TEC4_neg+TEC5_neg',
123 'TEC5_pos+TEC6_pos',
'TEC5_neg+TEC6_neg',
124 'TEC6_pos+TEC7_pos',
'TEC6_neg+TEC7_neg'),
126 TTRHBuilder = cms.string(
'WithTrackAngle'), clusterChargeCut = cms.PSet(refToPSet_ = cms.string(
'SiStripClusterChargeCutTight')),
127 matchedRecHits = cms.InputTag(
"siStripMatchedRecHits",
"matchedRecHit"),
128 skipClusters = cms.InputTag(
'tobTecStepClusters')
131 matchedRecHits = cms.InputTag(
"siStripMatchedRecHits",
"matchedRecHit"),
132 skipClusters = cms.InputTag(
'tobTecStepClusters'),
133 useRingSlector = cms.bool(
True),
134 TTRHBuilder = cms.string(
'WithTrackAngle'), clusterChargeCut = cms.PSet(refToPSet_ = cms.string(
'SiStripClusterChargeCutTight')),
135 minRing = cms.int32(5),
136 maxRing = cms.int32(5)
140 tobTecStepTrackingRegionsPair = _globalTrackingRegionFromBeamSpotFixedZ.clone(RegionPSet =
dict(
142 originHalfLength = 30.0,
146 (pp_on_XeXe_2017 | pp_on_AA_2018).toReplaceWith(tobTecStepTrackingRegionsPair,
147 _mixedTripletStepTrackingRegionsCommon_pp_on_HI.clone(RegionPSet=
dict(
148 ptMinScaling4BigEvts=
False,
157 tobTecStepHitDoubletsPair = _hitPairEDProducer.clone(
158 seedingLayers =
"tobTecStepSeedLayersPair",
159 trackingRegions =
"tobTecStepTrackingRegionsPair",
160 produceSeedingHitSets =
True,
162 from RecoTracker.TkSeedGenerator.seedCreatorFromRegionConsecutiveHitsEDProducer_cff
import seedCreatorFromRegionConsecutiveHitsEDProducer
as _seedCreatorFromRegionConsecutiveHitsEDProducer
163 tobTecStepSeedsPair = _seedCreatorFromRegionConsecutiveHitsEDProducer.clone(
164 seedingHitSets =
"tobTecStepHitDoubletsPair",
165 SeedComparitorPSet = _tobTecStepSeedComparitorPSet,
168 import FastSimulation.Tracking.TrajectorySeedProducer_cfi
169 fastSim.toReplaceWith(tobTecStepSeedsPair,
170 FastSimulation.Tracking.TrajectorySeedProducer_cfi.trajectorySeedProducer.clone(
171 trackingRegions =
"tobTecStepTrackingRegionsPair",
172 hitMasks = cms.InputTag(
"tobTecStepMasks"),
173 seedFinderSelector =
dict(layerList = tobTecStepSeedLayersPair.layerList.value())
180 tobTecStepSeeds = RecoTracker.TkSeedGenerator.GlobalCombinedSeeds_cfi.globalCombinedSeeds.clone()
181 tobTecStepSeeds.seedCollections = cms.VInputTag(cms.InputTag(
'tobTecStepSeedsTripl'),cms.InputTag(
'tobTecStepSeedsPair'))
184 from Configuration.Eras.Modifier_trackingLowPU_cff
import trackingLowPU
185 trackingLowPU.toModify(tobTecStepHitDoubletsPair, seedingLayers =
'tobTecStepSeedLayers')
186 trackingLowPU.toReplaceWith(tobTecStepSeeds, _seedCreatorFromRegionConsecutiveHitsEDProducer.clone(
187 seedingHitSets =
"tobTecStepHitDoubletsPair",
193 _tobTecStepTrajectoryFilterBase = TrackingTools.TrajectoryFiltering.TrajectoryFilter_cff.CkfBaseTrajectoryFilter_block.clone(
195 minimumNumberOfHits = 5,
199 tobTecStepTrajectoryFilter = _tobTecStepTrajectoryFilterBase.clone(
202 trackingLowPU.toReplaceWith(tobTecStepTrajectoryFilter, _tobTecStepTrajectoryFilterBase.clone(
203 minimumNumberOfHits = 6,
205 for e
in [pp_on_XeXe_2017, pp_on_AA_2018]:
206 e.toModify(tobTecStepTrajectoryFilter, minPt=2.0)
208 tobTecStepInOutTrajectoryFilter = tobTecStepTrajectoryFilter.clone(
209 minimumNumberOfHits = 4,
213 import RecoTracker.MeasurementDet.Chi2ChargeMeasurementEstimator_cfi
214 tobTecStepChi2Est = RecoTracker.MeasurementDet.Chi2ChargeMeasurementEstimator_cfi.Chi2ChargeMeasurementEstimator.clone(
215 ComponentName = cms.string(
'tobTecStepChi2Est'),
216 nSigma = cms.double(3.0),
217 MaxChi2 = cms.double(16.0),
218 clusterChargeCut = cms.PSet(refToPSet_ = cms.string(
'SiStripClusterChargeCutTight'))
220 trackingLowPU.toModify(tobTecStepChi2Est,
221 clusterChargeCut =
dict(refToPSet_ =
'SiStripClusterChargeCutTiny')
226 tobTecStepTrajectoryBuilder = RecoTracker.CkfPattern.GroupedCkfTrajectoryBuilder_cfi.GroupedCkfTrajectoryBuilder.clone(
227 MeasurementTrackerName =
'',
228 trajectoryFilter = cms.PSet(refToPSet_ = cms.string(
'tobTecStepTrajectoryFilter')),
229 inOutTrajectoryFilter = cms.PSet(refToPSet_ = cms.string(
'tobTecStepInOutTrajectoryFilter')),
230 useSameTrajFilter =
False,
231 minNrOfHitsForRebuild = 4,
232 alwaysUseInvalidHits =
False,
234 estimator = cms.string(
'tobTecStepChi2Est'),
236 maxDPhiForLooperReconstruction = cms.double(2.0),
237 maxPtForLooperReconstruction = cms.double(0.7)
252 tobTecStepTrackCandidates = RecoTracker.CkfPattern.CkfTrackCandidates_cfi.ckfTrackCandidates.clone(
253 src = cms.InputTag(
'tobTecStepSeeds'),
254 clustersToSkip = cms.InputTag(
'tobTecStepClusters'),
256 numHitsForSeedCleaner = cms.int32(50),
257 onlyPixelHitsForSeedCleaner = cms.bool(
True),
259 TrajectoryBuilderPSet = cms.PSet(refToPSet_ = cms.string(
'tobTecStepTrajectoryBuilder')),
260 doSeedingRegionRebuilding =
True,
261 useHitsSplitting =
True,
262 cleanTrajectoryAfterInOut =
True,
263 TrajectoryCleaner =
'tobTecStepTrajectoryCleanerBySharedHits' 265 import FastSimulation.Tracking.TrackCandidateProducer_cfi
266 fastSim.toReplaceWith(tobTecStepTrackCandidates,
267 FastSimulation.Tracking.TrackCandidateProducer_cfi.trackCandidateProducer.clone(
268 MinNumberOfCrossedLayers = 3,
269 src = cms.InputTag(
"tobTecStepSeeds"),
270 hitMasks = cms.InputTag(
"tobTecStepMasks")
276 tobTecStepTrajectoryCleanerBySharedHits = trajectoryCleanerBySharedHits.clone(
277 ComponentName = cms.string(
'tobTecStepTrajectoryCleanerBySharedHits'),
278 fractionShared = cms.double(0.09),
279 allowSharedFirstHit = cms.bool(
True)
281 trackingLowPU.toModify(tobTecStepTrajectoryCleanerBySharedHits, fractionShared = 0.19)
285 tobTecStepFitterSmoother = TrackingTools.TrackFitters.RungeKuttaFitters_cff.KFFittingSmootherWithOutliersRejectionAndRK.clone(
286 ComponentName =
'tobTecStepFitterSmoother',
289 Fitter = cms.string(
'tobTecStepRKFitter'),
290 Smoother = cms.string(
'tobTecStepRKSmoother')
292 trackingLowPU.toModify(tobTecStepFitterSmoother, MinNumberOfHits = 8)
294 tobTecStepFitterSmootherForLoopers = tobTecStepFitterSmoother.clone(
295 ComponentName =
'tobTecStepFitterSmootherForLoopers',
296 Fitter = cms.string(
'tobTecStepRKFitterForLoopers'),
297 Smoother = cms.string(
'tobTecStepRKSmootherForLoopers')
301 tobTecStepRKTrajectoryFitter = TrackingTools.TrackFitters.RungeKuttaFitters_cff.RKTrajectoryFitter.clone(
302 ComponentName = cms.string(
'tobTecStepRKFitter'),
305 trackingLowPU.toModify(tobTecStepRKTrajectoryFitter, minHits = 8)
307 tobTecStepRKTrajectoryFitterForLoopers = tobTecStepRKTrajectoryFitter.clone(
308 ComponentName = cms.string(
'tobTecStepRKFitterForLoopers'),
309 Propagator = cms.string(
'PropagatorWithMaterialForLoopers'),
312 tobTecStepRKTrajectorySmoother = TrackingTools.TrackFitters.RungeKuttaFitters_cff.RKTrajectorySmoother.clone(
313 ComponentName = cms.string(
'tobTecStepRKSmoother'),
314 errorRescaling = 10.0,
317 trackingLowPU.toModify(tobTecStepRKTrajectorySmoother, minHits = 8)
319 tobTecStepRKTrajectorySmootherForLoopers = tobTecStepRKTrajectorySmoother.clone(
320 ComponentName = cms.string(
'tobTecStepRKSmootherForLoopers'),
321 Propagator = cms.string(
'PropagatorWithMaterialForLoopers'),
325 tobTecFlexibleKFFittingSmoother = TrackingTools.TrackFitters.FlexibleKFFittingSmoother_cfi.FlexibleKFFittingSmoother.clone(
326 ComponentName = cms.string(
'tobTecFlexibleKFFittingSmoother'),
327 standardFitter = cms.string(
'tobTecStepFitterSmoother'),
328 looperFitter = cms.string(
'tobTecStepFitterSmootherForLoopers'),
334 tobTecStepTracks = RecoTracker.TrackProducer.TrackProducer_cfi.TrackProducer.clone(
335 src =
'tobTecStepTrackCandidates',
336 AlgorithmName = cms.string(
'tobTecStep'),
338 Fitter =
'tobTecFlexibleKFFittingSmoother',
340 fastSim.toModify(tobTecStepTracks, TTRHBuilder =
'WithoutRefit')
346 tobTecStepClassifier1 = TrackMVAClassifierDetached.clone()
347 tobTecStepClassifier1.src =
'tobTecStepTracks' 348 tobTecStepClassifier1.mva.GBRForestLabel =
'MVASelectorIter6_13TeV' 349 tobTecStepClassifier1.qualityCuts = [-0.6,-0.45,-0.3]
350 fastSim.toModify(tobTecStepClassifier1, vertices =
"firstStepPrimaryVerticesBeforeMixing")
352 tobTecStepClassifier2 = TrackMVAClassifierPrompt.clone()
353 tobTecStepClassifier2.src =
'tobTecStepTracks' 354 tobTecStepClassifier2.mva.GBRForestLabel =
'MVASelectorIter0_13TeV' 355 tobTecStepClassifier2.qualityCuts = [0.0,0.0,0.0]
356 fastSim.toModify(tobTecStepClassifier2,vertices =
"firstStepPrimaryVerticesBeforeMixing")
359 tobTecStep = ClassifierMerger.clone()
360 tobTecStep.inputClassifiers=[
'tobTecStepClassifier1',
'tobTecStepClassifier2']
362 from Configuration.Eras.Modifier_trackingPhase1_cff
import trackingPhase1
363 trackingPhase1.toReplaceWith(tobTecStep, tobTecStepClassifier1.clone(
364 mva =
dict(GBRForestLabel =
'MVASelectorTobTecStep_Phase1'),
365 qualityCuts = [-0.6,-0.45,-0.3],
368 import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
369 trackingLowPU.toReplaceWith(tobTecStep, RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
370 src =
'tobTecStepTracks',
371 useAnyMVA = cms.bool(
False),
372 GBRForestLabel = cms.string(
'MVASelectorIter6'),
374 RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
375 name =
'tobTecStepLoose',
377 res_par = ( 0.003, 0.001 ),
379 maxNumberLostLayers = 1,
380 minNumber3DLayers = 2,
381 d0_par1 = ( 2.0, 4.0 ),
382 dz_par1 = ( 1.8, 4.0 ),
383 d0_par2 = ( 2.0, 4.0 ),
384 dz_par2 = ( 1.8, 4.0 )
386 RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.tightMTS.clone(
387 name =
'tobTecStepTight',
388 preFilterName =
'tobTecStepLoose',
390 res_par = ( 0.003, 0.001 ),
392 maxNumberLostLayers = 0,
393 minNumber3DLayers = 2,
394 d0_par1 = ( 1.5, 4.0 ),
395 dz_par1 = ( 1.4, 4.0 ),
396 d0_par2 = ( 1.5, 4.0 ),
397 dz_par2 = ( 1.4, 4.0 )
399 RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.highpurityMTS.clone(
400 name =
'QualityMasks',
401 preFilterName =
'tobTecStepTight',
403 res_par = ( 0.003, 0.001 ),
405 maxNumberLostLayers = 0,
406 minNumber3DLayers = 2,
407 d0_par1 = ( 1.4, 4.0 ),
408 dz_par1 = ( 1.3, 4.0 ),
409 d0_par2 = ( 1.4, 4.0 ),
410 dz_par2 = ( 1.3, 4.0 )
417 TobTecStepTask = cms.Task(tobTecStepClusters,
418 tobTecStepSeedLayersTripl,
419 tobTecStepTrackingRegionsTripl,
420 tobTecStepHitDoubletsTripl,
421 tobTecStepHitTripletsTripl,
422 tobTecStepSeedsTripl,
423 tobTecStepSeedLayersPair,
424 tobTecStepTrackingRegionsPair,
425 tobTecStepHitDoubletsPair,
428 tobTecStepTrackCandidates,
430 tobTecStepClassifier1,tobTecStepClassifier2,
432 TobTecStep = cms.Sequence(TobTecStepTask)
438 tobTecStepSeedLayers = cms.EDProducer(
"SeedingLayersEDProducer",
439 layerList = cms.vstring(
'TOB1+TOB2',
440 'TOB1+TEC1_pos',
'TOB1+TEC1_neg',
441 'TEC1_pos+TEC2_pos',
'TEC2_pos+TEC3_pos',
442 'TEC3_pos+TEC4_pos',
'TEC4_pos+TEC5_pos',
443 'TEC5_pos+TEC6_pos',
'TEC6_pos+TEC7_pos',
444 'TEC1_neg+TEC2_neg',
'TEC2_neg+TEC3_neg',
445 'TEC3_neg+TEC4_neg',
'TEC4_neg+TEC5_neg',
446 'TEC5_neg+TEC6_neg',
'TEC6_neg+TEC7_neg'),
448 matchedRecHits = cms.InputTag(
"siStripMatchedRecHits",
"matchedRecHit"),
449 skipClusters = cms.InputTag(
'tobTecStepClusters'),
450 TTRHBuilder = cms.string(
'WithTrackAngle'), clusterChargeCut = cms.PSet(refToPSet_ = cms.string(
'SiStripClusterChargeCutTiny'))
453 matchedRecHits = cms.InputTag(
"siStripMatchedRecHits",
"matchedRecHit"),
454 skipClusters = cms.InputTag(
'tobTecStepClusters'),
456 useRingSlector = cms.bool(
True),
457 TTRHBuilder = cms.string(
'WithTrackAngle'), clusterChargeCut = cms.PSet(refToPSet_ = cms.string(
'SiStripClusterChargeCutTiny')),
458 minRing = cms.int32(5),
459 maxRing = cms.int32(5)
463 trackingLowPU.toReplaceWith(TobTecStepTask,
466 tobTecStepSeedLayers,
467 tobTecStepTrackingRegionsPair,
468 tobTecStepHitDoubletsPair,
470 tobTecStepTrackCandidates,
477 import FastSimulation.Tracking.FastTrackerRecHitMaskProducer_cfi
478 tobTecStepMasks = FastSimulation.Tracking.FastTrackerRecHitMaskProducer_cfi.maskProducerFromClusterRemover(tobTecStepClusters)
479 fastSim.toReplaceWith(TobTecStepTask,
480 cms.Task(tobTecStepMasks
481 ,tobTecStepTrackingRegionsTripl
482 ,tobTecStepSeedsTripl
483 ,tobTecStepTrackingRegionsPair
486 ,tobTecStepTrackCandidates
488 ,tobTecStepClassifier1,tobTecStepClassifier2
def _hitSetProducerToFactoryPSet(producer)