CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
TobTecStep_cff.py
Go to the documentation of this file.
2 
3 #######################################################################
4 # Very large impact parameter tracking using TOB + TEC ring 5 seeding #
5 #######################################################################
6 
7 tobTecStepClusters = cms.EDProducer("TrackClusterRemover",
8  clusterLessSolution = cms.bool(True),
9  oldClusterRemovalInfo = cms.InputTag("pixelLessStepClusters"),
10  trajectories = cms.InputTag("pixelLessStepTracks"),
11  overrideTrkQuals = cms.InputTag('pixelLessStep'),
12  TrackQuality = cms.string('highPurity'),
13  minNumberOfLayersWithMeasBeforeFiltering = cms.int32(0),
14  pixelClusters = cms.InputTag("siPixelClusters"),
15  stripClusters = cms.InputTag("siStripClusters"),
16  Common = cms.PSet(
17  maxChi2 = cms.double(9.0)
18  )
19 )
20 
21 # TRIPLET SEEDING LAYERS
22 tobTecStepSeedLayersTripl = cms.EDProducer("SeedingLayersEDProducer",
23  layerList = cms.vstring(
24  #TOB
25  'TOB1+TOB2+MTOB3',
26  #TOB+MTEC
27  'TOB1+TOB2+MTEC1_pos','TOB1+TOB2+MTEC1_neg',
28  ),
29  TOB = cms.PSet(
30  TTRHBuilder = cms.string('WithTrackAngle'),
31  matchedRecHits = cms.InputTag("siStripMatchedRecHits","matchedRecHit"),
32  skipClusters = cms.InputTag('tobTecStepClusters')
33  ),
34  MTOB = cms.PSet(
35  TTRHBuilder = cms.string('WithTrackAngle'),
36  skipClusters = cms.InputTag('tobTecStepClusters'),
37  rphiRecHits = cms.InputTag("siStripMatchedRecHits","rphiRecHit")
38  ),
39  MTEC = cms.PSet(
40  rphiRecHits = cms.InputTag("siStripMatchedRecHits","rphiRecHit"),
41  skipClusters = cms.InputTag('tobTecStepClusters'),
42  useRingSlector = cms.bool(True),
43  TTRHBuilder = cms.string('WithTrackAngle'),
44  minRing = cms.int32(6),
45  maxRing = cms.int32(7)
46  )
47 )
48 # TRIPLET SEEDS
50 tobTecStepSeedsTripl = RecoTracker.TkSeedGenerator.GlobalSeedsFromTriplets_cff.globalSeedsFromTriplets.clone()
51 #OrderedHitsFactory
52 tobTecStepSeedsTripl.OrderedHitsFactoryPSet.SeedingLayers = 'tobTecStepSeedLayersTripl'
53 tobTecStepSeedsTripl.OrderedHitsFactoryPSet.ComponentName = 'StandardMultiHitGenerator'
54 import RecoTracker.TkSeedGenerator.MultiHitGeneratorFromChi2_cfi
55 tobTecStepSeedsTripl.OrderedHitsFactoryPSet.GeneratorPSet = RecoTracker.TkSeedGenerator.MultiHitGeneratorFromChi2_cfi.MultiHitGeneratorFromChi2.clone(
56  extraPhiKDBox = 0.01
57  )
58 #RegionFactory
59 tobTecStepSeedsTripl.RegionFactoryPSet.RegionPSet.ptMin = 0.55
60 tobTecStepSeedsTripl.RegionFactoryPSet.RegionPSet.originHalfLength = 20.0
61 tobTecStepSeedsTripl.RegionFactoryPSet.RegionPSet.originRadius = 3.5
62 #SeedCreator
63 tobTecStepSeedsTripl.SeedCreatorPSet.ComponentName = 'SeedFromConsecutiveHitsCreator' #empirically better than 'SeedFromConsecutiveHitsTripletOnlyCreator'
64 tobTecStepSeedsTripl.SeedCreatorPSet.OriginTransverseErrorMultiplier = 1.0
65 #SeedComparitor
66 
67 tobTecStepSeedsTripl.SeedComparitorPSet = cms.PSet(
68  ComponentName = cms.string('PixelClusterShapeSeedComparitor'),
69  FilterAtHelixStage = cms.bool(True),
70  FilterPixelHits = cms.bool(False),
71  FilterStripHits = cms.bool(True),
72  ClusterShapeHitFilterName = cms.string('tobTecStepClusterShapeHitFilter'),
73  ClusterShapeCacheSrc = cms.InputTag("siPixelClusterShapeCache") # not really needed here since FilterPixelHits=False
74 )
75 # PAIR SEEDING LAYERS
76 tobTecStepSeedLayersPair = cms.EDProducer("SeedingLayersEDProducer",
77  layerList = cms.vstring('TOB1+TEC1_pos','TOB1+TEC1_neg',
78  'TEC1_pos+TEC2_pos','TEC1_neg+TEC2_neg',
79  'TEC2_pos+TEC3_pos','TEC2_neg+TEC3_neg',
80  'TEC3_pos+TEC4_pos','TEC3_neg+TEC4_neg',
81  'TEC4_pos+TEC5_pos','TEC4_neg+TEC5_neg',
82  'TEC5_pos+TEC6_pos','TEC5_neg+TEC6_neg',
83  'TEC6_pos+TEC7_pos','TEC6_neg+TEC7_neg'),
84  TOB = cms.PSet(
85  TTRHBuilder = cms.string('WithTrackAngle'),
86  matchedRecHits = cms.InputTag("siStripMatchedRecHits","matchedRecHit"),
87  skipClusters = cms.InputTag('tobTecStepClusters')
88  ),
89  TEC = cms.PSet(
90  matchedRecHits = cms.InputTag("siStripMatchedRecHits","matchedRecHit"),
91  skipClusters = cms.InputTag('tobTecStepClusters'),
92  useRingSlector = cms.bool(True),
93  TTRHBuilder = cms.string('WithTrackAngle'),
94  minRing = cms.int32(5),
95  maxRing = cms.int32(5)
96  )
97 )
98 # PAIR SEEDS
100 tobTecStepClusterShapeHitFilter = RecoPixelVertexing.PixelLowPtUtilities.ClusterShapeHitFilterESProducer_cfi.ClusterShapeHitFilterESProducer.clone(
101  ComponentName = cms.string('tobTecStepClusterShapeHitFilter'),
102  PixelShapeFile= cms.string('RecoPixelVertexing/PixelLowPtUtilities/data/pixelShape.par'),
103  minGoodStripCharge = cms.double(2069),
104  doStripShapeCut = cms.bool(False)
105  )
106 
108 tobTecStepSeedsPair = RecoTracker.TkSeedGenerator.GlobalMixedSeeds_cff.globalMixedSeeds.clone()
109 #OrderedHitsFactory
110 tobTecStepSeedsPair.OrderedHitsFactoryPSet.ComponentName = cms.string('StandardHitPairGenerator')
111 tobTecStepSeedsPair.OrderedHitsFactoryPSet.SeedingLayers = 'tobTecStepSeedLayersPair'
112 #RegionFactory
113 tobTecStepSeedsPair.RegionFactoryPSet.RegionPSet.ptMin = 0.6
114 tobTecStepSeedsPair.RegionFactoryPSet.RegionPSet.originHalfLength = 30.0
115 tobTecStepSeedsPair.RegionFactoryPSet.RegionPSet.originRadius = 6.0
116 #SeedCreator
117 tobTecStepSeedsPair.SeedCreatorPSet.OriginTransverseErrorMultiplier = 1.0
118 #SeedComparitor
119 tobTecStepSeedsPair.SeedComparitorPSet = cms.PSet(
120  ComponentName = cms.string('PixelClusterShapeSeedComparitor'),
121  FilterAtHelixStage = cms.bool(True),
122  FilterPixelHits = cms.bool(False),
123  FilterStripHits = cms.bool(True),
124  ClusterShapeHitFilterName = cms.string('tobTecStepClusterShapeHitFilter'),
125  ClusterShapeCacheSrc = cms.InputTag("siPixelClusterShapeCache") # not really needed here since FilterPixelHits=False
126 )
128 tobTecStepSeeds = RecoTracker.TkSeedGenerator.GlobalCombinedSeeds_cfi.globalCombinedSeeds.clone()
129 tobTecStepSeeds.seedCollections = cms.VInputTag(cms.InputTag('tobTecStepSeedsTripl'),cms.InputTag('tobTecStepSeedsPair'))
130 
131 # QUALITY CUTS DURING TRACK BUILDING (for inwardss and outwards track building steps)
133 
134 tobTecStepTrajectoryFilter = TrackingTools.TrajectoryFiltering.TrajectoryFilter_cff.CkfBaseTrajectoryFilter_block.clone(
135  maxLostHits = 0,
136  minimumNumberOfHits = 6,
137  minPt = 0.1,
138  minHitsMinPt = 3
139  )
140 
141 tobTecStepInOutTrajectoryFilter = tobTecStepTrajectoryFilter.clone(
142  maxLostHits = 0,
143  minimumNumberOfHits = 4,
144  minPt = 0.1,
145  minHitsMinPt = 3
146  )
147 
148 import TrackingTools.KalmanUpdators.Chi2ChargeMeasurementEstimatorESProducer_cfi
149 tobTecStepChi2Est = TrackingTools.KalmanUpdators.Chi2ChargeMeasurementEstimatorESProducer_cfi.Chi2ChargeMeasurementEstimator.clone(
150  ComponentName = cms.string('tobTecStepChi2Est'),
151  nSigma = cms.double(3.0),
152  MaxChi2 = cms.double(16.0),
153  minGoodStripCharge = cms.double(2069)
154 )
155 
156 # TRACK BUILDING
158 tobTecStepTrajectoryBuilder = RecoTracker.CkfPattern.GroupedCkfTrajectoryBuilder_cfi.GroupedCkfTrajectoryBuilder.clone(
159  MeasurementTrackerName = '',
160  trajectoryFilter = cms.PSet(refToPSet_ = cms.string('tobTecStepTrajectoryFilter')),
161  inOutTrajectoryFilter = cms.PSet(refToPSet_ = cms.string('tobTecStepInOutTrajectoryFilter')),
162  useSameTrajFilter = False,
163  minNrOfHitsForRebuild = 4,
164  alwaysUseInvalidHits = False,
165  maxCand = 2,
166  estimator = cms.string('tobTecStepChi2Est'),
167  #startSeedHitsInRebuild = True
168  maxDPhiForLooperReconstruction = cms.double(2.0),
169  maxPtForLooperReconstruction = cms.double(0.7)
170  )
171 
172 # MAKING OF TRACK CANDIDATES
174 tobTecStepTrackCandidates = RecoTracker.CkfPattern.CkfTrackCandidates_cfi.ckfTrackCandidates.clone(
175  src = cms.InputTag('tobTecStepSeeds'),
176  clustersToSkip = cms.InputTag('tobTecStepClusters'),
177  ### these two parameters are relevant only for the CachingSeedCleanerBySharedInput
178  numHitsForSeedCleaner = cms.int32(50),
179  onlyPixelHitsForSeedCleaner = cms.bool(True),
180 
181  TrajectoryBuilderPSet = cms.PSet(refToPSet_ = cms.string('tobTecStepTrajectoryBuilder')),
182  doSeedingRegionRebuilding = True,
183  useHitsSplitting = True,
184  cleanTrajectoryAfterInOut = True
185 )
186 
187 from TrackingTools.TrajectoryCleaning.TrajectoryCleanerBySharedHits_cfi import trajectoryCleanerBySharedHits
188 tobTecStepTrajectoryCleanerBySharedHits = trajectoryCleanerBySharedHits.clone(
189  ComponentName = cms.string('tobTecStepTrajectoryCleanerBySharedHits'),
190  fractionShared = cms.double(0.09),
191  allowSharedFirstHit = cms.bool(True)
192  )
193 tobTecStepTrackCandidates.TrajectoryCleaner = 'tobTecStepTrajectoryCleanerBySharedHits'
194 
195 # TRACK FITTING AND SMOOTHING OPTIONS
197 tobTecStepFitterSmoother = TrackingTools.TrackFitters.RungeKuttaFitters_cff.KFFittingSmootherWithOutliersRejectionAndRK.clone(
198  ComponentName = 'tobTecStepFitterSmoother',
199  EstimateCut = 30,
200  MinNumberOfHits = 8,
201  Fitter = cms.string('tobTecStepRKFitter'),
202  Smoother = cms.string('tobTecStepRKSmoother')
203  )
204 
205 tobTecStepFitterSmootherForLoopers = tobTecStepFitterSmoother.clone(
206  ComponentName = 'tobTecStepFitterSmootherForLoopers',
207  Fitter = cms.string('tobTecStepRKFitterForLoopers'),
208  Smoother = cms.string('tobTecStepRKSmootherForLoopers')
209 )
210 
211 # Also necessary to specify minimum number of hits after final track fit
212 tobTecStepRKTrajectoryFitter = TrackingTools.TrackFitters.RungeKuttaFitters_cff.RKTrajectoryFitter.clone(
213  ComponentName = cms.string('tobTecStepRKFitter'),
214  minHits = 8
215 )
216 tobTecStepRKTrajectoryFitterForLoopers = tobTecStepRKTrajectoryFitter.clone(
217  ComponentName = cms.string('tobTecStepRKFitterForLoopers'),
218  Propagator = cms.string('PropagatorWithMaterialForLoopers'),
219 )
220 
221 tobTecStepRKTrajectorySmoother = TrackingTools.TrackFitters.RungeKuttaFitters_cff.RKTrajectorySmoother.clone(
222  ComponentName = cms.string('tobTecStepRKSmoother'),
223  errorRescaling = 10.0,
224  minHits = 8
225 )
226 tobTecStepRKTrajectorySmootherForLoopers = tobTecStepRKTrajectorySmoother.clone(
227  ComponentName = cms.string('tobTecStepRKSmootherForLoopers'),
228  Propagator = cms.string('PropagatorWithMaterialForLoopers'),
229 )
230 
232 tobTecFlexibleKFFittingSmoother = TrackingTools.TrackFitters.FlexibleKFFittingSmoother_cfi.FlexibleKFFittingSmoother.clone(
233  ComponentName = cms.string('tobTecFlexibleKFFittingSmoother'),
234  standardFitter = cms.string('tobTecStepFitterSmoother'),
235  looperFitter = cms.string('tobTecStepFitterSmootherForLoopers'),
236 )
237 
238 
239 # TRACK FITTING
241 tobTecStepTracks = RecoTracker.TrackProducer.TrackProducer_cfi.TrackProducer.clone(
242  src = 'tobTecStepTrackCandidates',
243  AlgorithmName = cms.string('iter6'),
244  #Fitter = 'tobTecStepFitterSmoother',
245  Fitter = 'tobTecFlexibleKFFittingSmoother',
246  )
247 
248 import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
249 tobTecStepSelector = RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
250  src='tobTecStepTracks',
251  useAnyMVA = cms.bool(True),
252  GBRForestLabel = cms.string('MVASelectorIter6_13TeV_v0'),
253  trackSelectors= cms.VPSet(
254  RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
255  name = 'tobTecStepLoose',
256  chi2n_par = 9999,
257  useMVA = cms.bool(True),
258  minMVA = cms.double(-0.6),
259  #chi2n_par = 0.4,
260  #res_par = ( 0.003, 0.001 ),
261  #minNumberLayers = 5,
262  #maxNumberLostLayers = 1,
263  #minNumber3DLayers = 2,
264  d0_par1 = ( 2.0, 4.0 ),
265  dz_par1 = ( 1.8, 4.0 ),
266  d0_par2 = ( 2.0, 4.0 ),
267  dz_par2 = ( 1.8, 4.0 )
268  ),
269  RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.tightMTS.clone(
270  name = 'tobTecStepTight',
271  preFilterName = 'tobTecStepLoose',
272  chi2n_par = 0.3,
273  res_par = ( 0.003, 0.001 ),
274  minNumberLayers = 5,
275  maxNumberLostLayers = 0,
276  minNumber3DLayers = 2,
277  d0_par1 = ( 1.5, 4.0 ),
278  dz_par1 = ( 1.4, 4.0 ),
279  d0_par2 = ( 1.5, 4.0 ),
280  dz_par2 = ( 1.4, 4.0 )
281  ),
282  RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
283  name = 'tobTecStep',
284  preFilterName = 'tobTecStepLoose',
285  chi2n_par = cms.double(9999),
286  useMVA = cms.bool(True),
287  minMVA = cms.double(0.6),
288  qualityBit = cms.string('highPurity'),
289  keepAllTracks = cms.bool(True),
290  #chi2n_par = 0.2,
291  #res_par = ( 0.003, 0.001 ),
292  #minNumberLayers = 5,
293  #maxNumberLostLayers = 0,
294  #minNumber3DLayers = 2,
295  #max_minMissHitOutOrIn = 1,
296  #max_lostHitFraction = 1.0,
297  d0_par1 = ( 1.2, 4.0 ),
298  dz_par1 = ( 1.1, 4.0 ),
299  d0_par2 = ( 1.2, 4.0 ),
300  dz_par2 = ( 1.1, 4.0 )
301  ),
302  ) #end of vpset
303  ) #end of clone
304 
305 
306 TobTecStep = cms.Sequence(tobTecStepClusters*
307  tobTecStepSeedLayersTripl*
308  tobTecStepSeedsTripl*
309  tobTecStepSeedLayersPair*
310  tobTecStepSeedsPair*
311  tobTecStepSeeds*
312  tobTecStepTrackCandidates*
313  tobTecStepTracks*
314  tobTecStepSelector)
315