Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:28:10

0001 import FWCore.ParameterSet.Config as cms
0002 import RecoTracker.IterativeTracking.iterativeTkConfig as _cfg
0003 
0004 from Configuration.Eras.Modifier_fastSim_cff import fastSim
0005 
0006 # for dnn classifier
0007 from Configuration.ProcessModifiers.trackdnn_cff import trackdnn
0008 from RecoTracker.IterativeTracking.dnnQualityCuts import qualityCutDictionary
0009 
0010 # for no-loopers
0011 from Configuration.ProcessModifiers.trackingNoLoopers_cff import trackingNoLoopers
0012 
0013 ##########################################################################
0014 # Large impact parameter tracking using TIB/TID/TEC stereo layer seeding #
0015 ##########################################################################
0016 
0017 pixelLessStepClusters = _cfg.clusterRemoverForIter('PixelLessStep')
0018 for _eraName, _postfix, _era in _cfg.nonDefaultEras():
0019     _era.toReplaceWith(pixelLessStepClusters, _cfg.clusterRemoverForIter('PixelLessStep', _eraName, _postfix))
0020 
0021 
0022 
0023 # SEEDING LAYERS
0024 from RecoLocalTracker.SiStripClusterizer.SiStripClusterChargeCut_cfi import *
0025 import RecoTracker.TkSeedingLayers.seedingLayersEDProducer_cfi as _mod
0026 
0027 pixelLessStepSeedLayers = _mod.seedingLayersEDProducer.clone(
0028     layerList = [
0029     #TIB
0030     'TIB1+TIB2+MTIB3','TIB1+TIB2+MTIB4',
0031     #TIB+TID
0032     'TIB1+TIB2+MTID1_pos','TIB1+TIB2+MTID1_neg',
0033     #TID
0034     'TID1_pos+TID2_pos+TID3_pos','TID1_neg+TID2_neg+TID3_neg',#ring 1-2 (matched)
0035     'TID1_pos+TID2_pos+MTID3_pos','TID1_neg+TID2_neg+MTID3_neg',#ring 3 (mono)
0036     'TID1_pos+TID2_pos+MTEC1_pos','TID1_neg+TID2_neg+MTEC1_neg',
0037     #TID+TEC RING 1-3
0038     'TID2_pos+TID3_pos+TEC1_pos','TID2_neg+TID3_neg+TEC1_neg',#ring 1-2 (matched)
0039     'TID2_pos+TID3_pos+MTEC1_pos','TID2_neg+TID3_neg+MTEC1_neg',#ring 3 (mono)
0040     #TEC RING 1-3
0041     'TEC1_pos+TEC2_pos+TEC3_pos', 'TEC1_neg+TEC2_neg+TEC3_neg',
0042     'TEC1_pos+TEC2_pos+MTEC3_pos','TEC1_neg+TEC2_neg+MTEC3_neg',
0043     'TEC1_pos+TEC2_pos+TEC4_pos', 'TEC1_neg+TEC2_neg+TEC4_neg',
0044     'TEC1_pos+TEC2_pos+MTEC4_pos','TEC1_neg+TEC2_neg+MTEC4_neg',
0045     'TEC2_pos+TEC3_pos+TEC4_pos', 'TEC2_neg+TEC3_neg+TEC4_neg',
0046     'TEC2_pos+TEC3_pos+MTEC4_pos','TEC2_neg+TEC3_neg+MTEC4_neg',
0047     'TEC2_pos+TEC3_pos+TEC5_pos', 'TEC2_neg+TEC3_neg+TEC5_neg',
0048     'TEC2_pos+TEC3_pos+TEC6_pos', 'TEC2_neg+TEC3_neg+TEC6_neg',
0049     'TEC3_pos+TEC4_pos+TEC5_pos', 'TEC3_neg+TEC4_neg+TEC5_neg',
0050     'TEC3_pos+TEC4_pos+MTEC5_pos','TEC3_neg+TEC4_neg+MTEC5_neg',
0051     'TEC3_pos+TEC5_pos+TEC6_pos', 'TEC3_neg+TEC5_neg+TEC6_neg',
0052     'TEC4_pos+TEC5_pos+TEC6_pos', 'TEC4_neg+TEC5_neg+TEC6_neg'    
0053     ],
0054     TIB = dict(
0055          TTRHBuilder    = cms.string('WithTrackAngle'), 
0056          clusterChargeCut = cms.PSet(refToPSet_ = cms.string('SiStripClusterChargeCutTight')),
0057          matchedRecHits = cms.InputTag('siStripMatchedRecHits','matchedRecHit'),
0058          skipClusters   = cms.InputTag('pixelLessStepClusters')
0059     ),
0060     MTIB = dict(
0061          TTRHBuilder    = cms.string('WithTrackAngle'), 
0062          clusterChargeCut = cms.PSet(refToPSet_ = cms.string('SiStripClusterChargeCutTight')),
0063          skipClusters   = cms.InputTag('pixelLessStepClusters'),
0064          rphiRecHits    = cms.InputTag('siStripMatchedRecHits','rphiRecHit')
0065     ),
0066     TID = dict(
0067         matchedRecHits = cms.InputTag('siStripMatchedRecHits','matchedRecHit'),
0068         skipClusters = cms.InputTag('pixelLessStepClusters'),
0069         useRingSlector = cms.bool(True),
0070         TTRHBuilder = cms.string('WithTrackAngle'), 
0071         clusterChargeCut = cms.PSet(refToPSet_ = cms.string('SiStripClusterChargeCutTight')),
0072         minRing = cms.int32(1),
0073         maxRing = cms.int32(2)
0074     ),
0075     MTID = dict(
0076         rphiRecHits    = cms.InputTag('siStripMatchedRecHits','rphiRecHit'),
0077         skipClusters = cms.InputTag('pixelLessStepClusters'),
0078         useRingSlector = cms.bool(True),
0079         TTRHBuilder = cms.string('WithTrackAngle'), 
0080         clusterChargeCut = cms.PSet(refToPSet_ = cms.string('SiStripClusterChargeCutTight')),
0081         minRing = cms.int32(3),
0082         maxRing = cms.int32(3)
0083     ),
0084     TEC = dict(
0085         matchedRecHits = cms.InputTag('siStripMatchedRecHits','matchedRecHit'),
0086         skipClusters = cms.InputTag('pixelLessStepClusters'),
0087         useRingSlector = cms.bool(True),
0088         TTRHBuilder = cms.string('WithTrackAngle'), 
0089         clusterChargeCut = cms.PSet(refToPSet_ = cms.string('SiStripClusterChargeCutTight')),
0090         minRing = cms.int32(1),
0091         maxRing = cms.int32(2)
0092     ),
0093     MTEC = dict(
0094         rphiRecHits = cms.InputTag('siStripMatchedRecHits','rphiRecHit'),
0095         skipClusters = cms.InputTag('pixelLessStepClusters'),
0096         useRingSlector = cms.bool(True),
0097         TTRHBuilder = cms.string('WithTrackAngle'), 
0098         clusterChargeCut = cms.PSet(refToPSet_ = cms.string('SiStripClusterChargeCutTight')),
0099         minRing = cms.int32(3),
0100         maxRing = cms.int32(3)
0101     )
0102 )
0103 from Configuration.Eras.Modifier_trackingLowPU_cff import trackingLowPU
0104 trackingLowPU.toModify(pixelLessStepSeedLayers,
0105     layerList = [
0106         'TIB1+TIB2',
0107         'TID1_pos+TID2_pos','TID2_pos+TID3_pos',
0108         'TEC1_pos+TEC2_pos','TEC2_pos+TEC3_pos','TEC3_pos+TEC4_pos','TEC3_pos+TEC5_pos','TEC4_pos+TEC5_pos',
0109         'TID1_neg+TID2_neg','TID2_neg+TID3_neg',
0110         'TEC1_neg+TEC2_neg','TEC2_neg+TEC3_neg','TEC3_neg+TEC4_neg','TEC3_neg+TEC5_neg','TEC4_neg+TEC5_neg'
0111     ],
0112     TIB = dict(clusterChargeCut = dict(refToPSet_ = 'SiStripClusterChargeCutTiny')),
0113     TID = dict(clusterChargeCut = dict(refToPSet_ = 'SiStripClusterChargeCutTiny')),
0114     TEC = dict(clusterChargeCut = dict(refToPSet_ = 'SiStripClusterChargeCutTiny')),
0115     MTIB = None,
0116     MTID = None,
0117     MTEC = None,
0118 )
0119 from Configuration.ProcessModifiers.vectorHits_cff import vectorHits
0120 vectorHits.toModify(pixelLessStepSeedLayers,
0121     layerList = [
0122         'TOB1+TOB2', 'TOB2+TOB3',
0123 #        'TOB3+TOB4', 'TOB4+TOB5', 
0124         'TID1_pos+TID2_pos', 'TID1_neg+TID2_neg'
0125     ],
0126     TOB = dict(
0127          TTRHBuilder      = cms.string('WithTrackAngle'), 
0128          clusterChargeCut = cms.PSet(refToPSet_ = cms.string('SiStripClusterChargeCutNone')),
0129          vectorRecHits    = cms.InputTag("siPhase2VectorHits", 'vectorHitsAccepted'),
0130          skipClusters     = cms.InputTag('pixelLessStepClusters')
0131     ),
0132     TIB = None,
0133     TID = dict(
0134          clusterChargeCut = dict(refToPSet_ = 'SiStripClusterChargeCutNone'),
0135          vectorRecHits    = cms.InputTag("siPhase2VectorHits", 'accepted'),
0136          maxRing          = 8
0137     ),
0138     TEC  = None,
0139     MTIB = None,
0140     MTID = None,
0141     MTEC = None,
0142 )
0143 # TrackingRegion
0144 from RecoTracker.TkTrackingRegions.globalTrackingRegionFromBeamSpotFixedZ_cfi import globalTrackingRegionFromBeamSpotFixedZ as _globalTrackingRegionFromBeamSpotFixedZ
0145 pixelLessStepTrackingRegions = _globalTrackingRegionFromBeamSpotFixedZ.clone(
0146     RegionPSet = dict(
0147         ptMin            = 0.4,
0148         originHalfLength = 12.0,
0149         originRadius     = 1.0)
0150 )
0151 trackingLowPU.toModify(pixelLessStepTrackingRegions, RegionPSet = dict(
0152     ptMin            = 0.7,
0153     originHalfLength = 10.0,
0154     originRadius     = 2.0,
0155 ))
0156 
0157 from Configuration.Eras.Modifier_pp_on_XeXe_2017_cff import pp_on_XeXe_2017
0158 from Configuration.ProcessModifiers.pp_on_AA_cff import pp_on_AA
0159 from RecoTracker.IterativeTracking.MixedTripletStep_cff import _mixedTripletStepTrackingRegionsCommon_pp_on_HI
0160 (pp_on_XeXe_2017 | pp_on_AA).toReplaceWith(pixelLessStepTrackingRegions, 
0161                 _mixedTripletStepTrackingRegionsCommon_pp_on_HI.clone(RegionPSet=dict(
0162                     ptMinScaling4BigEvts = False,
0163                     fixedError           = 3.0,
0164                     ptMin                = 2.0,
0165                     originRadius         = 1.0 )
0166                 )
0167 )
0168 
0169 
0170 # seeding
0171 from RecoTracker.PixelLowPtUtilities.ClusterShapeHitFilterESProducer_cfi import ClusterShapeHitFilterESProducer as _ClusterShapeHitFilterESProducer
0172 pixelLessStepClusterShapeHitFilter = _ClusterShapeHitFilterESProducer.clone(
0173     ComponentName    = 'pixelLessStepClusterShapeHitFilter',
0174     doStripShapeCut  = cms.bool(False),
0175     clusterChargeCut = dict(refToPSet_ = 'SiStripClusterChargeCutTight')
0176 )
0177 
0178 from RecoTracker.TkHitPairs.hitPairEDProducer_cfi import hitPairEDProducer as _hitPairEDProducer
0179 pixelLessStepHitDoublets = _hitPairEDProducer.clone(
0180     seedingLayers   = 'pixelLessStepSeedLayers',
0181     trackingRegions = 'pixelLessStepTrackingRegions',
0182     maxElement      = 50000000,
0183     produceIntermediateHitDoublets = True,
0184 )
0185 from RecoTracker.TkSeedGenerator.multiHitFromChi2EDProducer_cfi import multiHitFromChi2EDProducer as _multiHitFromChi2EDProducer
0186 pixelLessStepHitTriplets = _multiHitFromChi2EDProducer.clone(
0187     doublets = 'pixelLessStepHitDoublets',
0188 )
0189 from RecoTracker.TkSeedGenerator.seedCreatorFromRegionConsecutiveHitsTripletOnlyEDProducer_cff import seedCreatorFromRegionConsecutiveHitsTripletOnlyEDProducer as _seedCreatorFromRegionConsecutiveHitsTripletOnlyEDProducer
0190 from RecoTracker.PixelLowPtUtilities.StripSubClusterShapeSeedFilter_cfi import StripSubClusterShapeSeedFilter as _StripSubClusterShapeSeedFilter
0191 pixelLessStepSeeds = _seedCreatorFromRegionConsecutiveHitsTripletOnlyEDProducer.clone(
0192     seedingHitSets = 'pixelLessStepHitTriplets',
0193     SeedComparitorPSet = dict(
0194         ComponentName = 'CombinedSeedComparitor',
0195         mode = cms.string('and'),
0196         comparitors = cms.VPSet(
0197             cms.PSet(# FIXME: is this defined in any cfi that could be imported instead of copy-paste?
0198                 ComponentName      = cms.string('PixelClusterShapeSeedComparitor'),
0199                 FilterAtHelixStage = cms.bool(True),
0200                 FilterPixelHits    = cms.bool(False),
0201                 FilterStripHits    = cms.bool(True),
0202                 ClusterShapeHitFilterName = cms.string('pixelLessStepClusterShapeHitFilter'),
0203                 ClusterShapeCacheSrc      = cms.InputTag('siPixelClusterShapeCache') # not really needed here since FilterPixelHits=False
0204             ),
0205             _StripSubClusterShapeSeedFilter.clone()
0206         )
0207     )
0208 )
0209 
0210 trackingLowPU.toModify(pixelLessStepHitDoublets, produceSeedingHitSets=True, produceIntermediateHitDoublets=False)
0211 trackingLowPU.toModify(pixelLessStepSeeds,
0212     seedingHitSets = 'pixelLessStepHitDoublets',
0213     SeedComparitorPSet = dict(# FIXME: is this defined in any cfi that could be imported instead of copy-paste?
0214         ComponentName      = 'PixelClusterShapeSeedComparitor',
0215         FilterAtHelixStage = cms.bool(True),
0216         FilterPixelHits    = cms.bool(False),
0217         FilterStripHits    = cms.bool(True),
0218         ClusterShapeHitFilterName = cms.string('ClusterShapeHitFilter'),
0219         ClusterShapeCacheSrc      = cms.InputTag('siPixelClusterShapeCache') # not really needed here since FilterPixelHits=False
0220     )
0221 )
0222 #fastsim
0223 import FastSimulation.Tracking.TrajectorySeedProducer_cfi
0224 from FastSimulation.Tracking.SeedingMigration import _hitSetProducerToFactoryPSet
0225 _fastSim_pixelLessStepSeeds = FastSimulation.Tracking.TrajectorySeedProducer_cfi.trajectorySeedProducer.clone(
0226     trackingRegions = 'pixelLessStepTrackingRegions',
0227     hitMasks        = cms.InputTag('pixelLessStepMasks'),
0228     seedFinderSelector = dict( MultiHitGeneratorFactory = _hitSetProducerToFactoryPSet(pixelLessStepHitTriplets).clone(
0229                               refitHits = False),
0230                               layerList = pixelLessStepSeedLayers.layerList.value()
0231 ))
0232 fastSim.toReplaceWith(pixelLessStepSeeds,_fastSim_pixelLessStepSeeds)
0233 
0234 vectorHits.toModify(pixelLessStepHitDoublets, produceSeedingHitSets=True, produceIntermediateHitDoublets=False)
0235 vectorHits.toModify(pixelLessStepSeeds, 
0236     seedingHitSets = "pixelLessStepHitDoublets",
0237     SeedComparitorPSet = dict(
0238         ClusterShapeHitFilterName = cms.string('ClusterShapeHitFilter'),
0239         FilterAtHelixStage = cms.bool(False),
0240         FilterStripHits = cms.bool(False),
0241     )
0242 )
0243 
0244 # QUALITY CUTS DURING TRACK BUILDING
0245 import TrackingTools.TrajectoryFiltering.TrajectoryFilter_cff
0246 _pixelLessStepTrajectoryFilterBase = TrackingTools.TrajectoryFiltering.TrajectoryFilter_cff.CkfBaseTrajectoryFilter_block.clone(
0247     maxLostHits         = 0,
0248     minimumNumberOfHits = 4,
0249     minPt               = 0.1
0250 )
0251 pixelLessStepTrajectoryFilter = _pixelLessStepTrajectoryFilterBase.clone(
0252     seedPairPenalty = 1,
0253 )
0254 trackingLowPU.toReplaceWith(pixelLessStepTrajectoryFilter, _pixelLessStepTrajectoryFilterBase)
0255 (pp_on_XeXe_2017 | pp_on_AA).toModify(pixelLessStepTrajectoryFilter, minPt=2.0)
0256 
0257 vectorHits.toReplaceWith(pixelLessStepTrajectoryFilter, _pixelLessStepTrajectoryFilterBase)
0258 vectorHits.toModify(pixelLessStepTrajectoryFilter, minimumNumberOfHits = 4, maxLostHits = 1)
0259 
0260 import RecoTracker.MeasurementDet.Chi2ChargeMeasurementEstimator_cfi
0261 pixelLessStepChi2Est = RecoTracker.MeasurementDet.Chi2ChargeMeasurementEstimator_cfi.Chi2ChargeMeasurementEstimator.clone(
0262     ComponentName    = 'pixelLessStepChi2Est',
0263     nSigma           = 3.0,
0264     MaxChi2          = 16.0,
0265     clusterChargeCut = cms.PSet(refToPSet_ = cms.string('SiStripClusterChargeCutTight'))
0266 )
0267 trackingLowPU.toModify(pixelLessStepChi2Est,
0268     clusterChargeCut = dict(refToPSet_ = 'SiStripClusterChargeCutTiny')
0269 )
0270 
0271 vectorHits.toModify(pixelLessStepChi2Est,
0272     clusterChargeCut = dict(refToPSet_ = 'SiStripClusterChargeCutNone'),
0273     MaxChi2 = 30.0
0274 )
0275 
0276 # TRACK BUILDING
0277 import RecoTracker.CkfPattern.GroupedCkfTrajectoryBuilder_cfi
0278 pixelLessStepTrajectoryBuilder = RecoTracker.CkfPattern.GroupedCkfTrajectoryBuilder_cfi.GroupedCkfTrajectoryBuilderIterativeDefault.clone(
0279     trajectoryFilter       = dict(refToPSet_ = 'pixelLessStepTrajectoryFilter'),
0280     minNrOfHitsForRebuild  = 4,
0281     maxCand                = 2,
0282     alwaysUseInvalidHits   = False,
0283     estimator              = 'pixelLessStepChi2Est',
0284     maxDPhiForLooperReconstruction = 2.0,
0285     maxPtForLooperReconstruction   = 0.7,
0286 )
0287 trackingNoLoopers.toModify(pixelLessStepTrajectoryBuilder,
0288                            maxPtForLooperReconstruction = 0.0)
0289 
0290 # MAKING OF TRACK CANDIDATES
0291 import RecoTracker.CkfPattern.CkfTrackCandidates_cfi
0292 # Give handle for CKF for HI
0293 _pixelLessStepTrackCandidatesCkf = RecoTracker.CkfPattern.CkfTrackCandidates_cfi.ckfTrackCandidatesIterativeDefault.clone(
0294     src                   = 'pixelLessStepSeeds',
0295     clustersToSkip        = 'pixelLessStepClusters',
0296     ### these two parameters are relevant only for the CachingSeedCleanerBySharedInput
0297     numHitsForSeedCleaner = 50,
0298     #onlyPixelHitsForSeedCleaner = True,
0299     TrajectoryBuilderPSet = dict(refToPSet_ = 'pixelLessStepTrajectoryBuilder'),
0300     TrajectoryCleaner     = 'pixelLessStepTrajectoryCleanerBySharedHits',
0301 )
0302 pixelLessStepTrackCandidates = _pixelLessStepTrackCandidatesCkf.clone()
0303 
0304 from Configuration.ProcessModifiers.trackingMkFitPixelLessStep_cff import trackingMkFitPixelLessStep
0305 import RecoTracker.MkFit.mkFitSeedConverter_cfi as mkFitSeedConverter_cfi
0306 import RecoTracker.MkFit.mkFitIterationConfigESProducer_cfi as mkFitIterationConfigESProducer_cfi
0307 import RecoTracker.MkFit.mkFitProducer_cfi as mkFitProducer_cfi
0308 import RecoTracker.MkFit.mkFitOutputConverter_cfi as mkFitOutputConverter_cfi
0309 pixelLessStepTrackCandidatesMkFitSeeds = mkFitSeedConverter_cfi.mkFitSeedConverter.clone(
0310     seeds = 'pixelLessStepSeeds',
0311 )
0312 pixelLessStepTrackCandidatesMkFitConfig = mkFitIterationConfigESProducer_cfi.mkFitIterationConfigESProducer.clone(
0313     ComponentName = 'pixelLessStepTrackCandidatesMkFitConfig',
0314     config = 'RecoTracker/MkFit/data/mkfit-phase1-pixelLessStep.json',
0315 )
0316 pixelLessStepTrackCandidatesMkFit = mkFitProducer_cfi.mkFitProducer.clone(
0317     seeds = 'pixelLessStepTrackCandidatesMkFitSeeds',
0318     config = ('', 'pixelLessStepTrackCandidatesMkFitConfig'),
0319     clustersToSkip = 'pixelLessStepClusters',
0320 )
0321 trackingMkFitPixelLessStep.toReplaceWith(pixelLessStepTrackCandidates, mkFitOutputConverter_cfi.mkFitOutputConverter.clone(
0322     seeds = 'pixelLessStepSeeds',
0323     mkFitSeeds = 'pixelLessStepTrackCandidatesMkFitSeeds',
0324     tracks = 'pixelLessStepTrackCandidatesMkFit',
0325     candMVASel = False,
0326     candWP = -0.7,
0327 ))
0328 (pp_on_XeXe_2017 | pp_on_AA).toModify(pixelLessStepTrackCandidatesMkFitConfig, minPt=2.0)
0329 
0330 import FastSimulation.Tracking.TrackCandidateProducer_cfi
0331 fastSim.toReplaceWith(pixelLessStepTrackCandidates,
0332                       FastSimulation.Tracking.TrackCandidateProducer_cfi.trackCandidateProducer.clone(
0333         src = 'pixelLessStepSeeds',
0334         MinNumberOfCrossedLayers = 6, # ?
0335         hitMasks = cms.InputTag('pixelLessStepMasks')
0336         )
0337 )
0338 
0339 vectorHits.toModify(pixelLessStepTrackCandidates,
0340     phase2clustersToSkip = 'pixelLessStepClusters',
0341     clustersToSkip = ''
0342 )
0343 
0344 from TrackingTools.TrajectoryCleaning.TrajectoryCleanerBySharedHits_cfi import trajectoryCleanerBySharedHits
0345 pixelLessStepTrajectoryCleanerBySharedHits = trajectoryCleanerBySharedHits.clone(
0346     ComponentName       = 'pixelLessStepTrajectoryCleanerBySharedHits',
0347     fractionShared      = 0.11,
0348     allowSharedFirstHit = True
0349 )
0350 trackingLowPU.toModify(pixelLessStepTrajectoryCleanerBySharedHits, fractionShared = 0.19)
0351 
0352 
0353 # TRACK FITTING
0354 import RecoTracker.TrackProducer.TrackProducerIterativeDefault_cfi
0355 pixelLessStepTracks = RecoTracker.TrackProducer.TrackProducerIterativeDefault_cfi.TrackProducerIterativeDefault.clone(
0356     src           = 'pixelLessStepTrackCandidates',
0357     AlgorithmName = 'pixelLessStep',
0358     Fitter        = 'FlexibleKFFittingSmoother'
0359 )
0360 fastSim.toModify(pixelLessStepTracks, TTRHBuilder = 'WithoutRefit')
0361 
0362 from Configuration.Eras.Modifier_phase2_timing_layer_cff import phase2_timing_layer
0363 phase2_timing_layer.toModify(pixelLessStepTracks, TrajectoryInEvent = True)
0364 
0365 # TRACK SELECTION AND QUALITY FLAG SETTING.
0366 from RecoTracker.FinalTrackSelectors.TrackMVAClassifierPrompt_cfi import *
0367 from RecoTracker.FinalTrackSelectors.TrackMVAClassifierDetached_cfi import *
0368 pixelLessStepClassifier1 = TrackMVAClassifierPrompt.clone(
0369     src         = 'pixelLessStepTracks',
0370     mva         = dict(GBRForestLabel = 'MVASelectorIter5_13TeV'),
0371     qualityCuts = [-0.4,0.0,0.4]
0372 )
0373 fastSim.toModify(pixelLessStepClassifier1, vertices = 'firstStepPrimaryVerticesBeforeMixing' )
0374 
0375 pixelLessStepClassifier2 = TrackMVAClassifierPrompt.clone(
0376     src         = 'pixelLessStepTracks',
0377     mva         = dict(GBRForestLabel = 'MVASelectorIter0_13TeV'),
0378     qualityCuts = [-0.0,0.0,0.0]
0379 )
0380 fastSim.toModify(pixelLessStepClassifier2, vertices = 'firstStepPrimaryVerticesBeforeMixing' )
0381 
0382 from RecoTracker.FinalTrackSelectors.ClassifierMerger_cfi import *
0383 pixelLessStep = ClassifierMerger.clone(
0384     inputClassifiers=['pixelLessStepClassifier1','pixelLessStepClassifier2']
0385 )
0386 from Configuration.Eras.Modifier_trackingPhase1_cff import trackingPhase1
0387 
0388 trackingPhase1.toReplaceWith(pixelLessStep, pixelLessStepClassifier1.clone(
0389     mva         = dict(GBRForestLabel = 'MVASelectorPixelLessStep_Phase1'),
0390     qualityCuts = [-0.4,0.0,0.4]
0391 ))
0392 
0393 from RecoTracker.FinalTrackSelectors.trackTfClassifier_cfi import *
0394 from RecoTracker.FinalTrackSelectors.trackSelectionTf_cfi import *
0395 from RecoTracker.FinalTrackSelectors.trackSelectionTf_CKF_cfi import *
0396 trackdnn.toReplaceWith(pixelLessStep, trackTfClassifier.clone(
0397     mva         = dict(tfDnnLabel  = 'trackSelectionTfPLess'),
0398     src         = 'pixelLessStepTracks',
0399     qualityCuts = qualityCutDictionary.PixelLessStep.value()
0400 ))
0401 (trackdnn & fastSim).toModify(pixelLessStep,vertices = 'firstStepPrimaryVerticesBeforeMixing')
0402 
0403 ((~trackingMkFitPixelLessStep) & trackdnn).toModify(pixelLessStep, mva = dict(tfDnnLabel  = 'trackSelectionTf_CKF'),
0404                                                     qualityCuts = [-0.82, -0.61, -0.16])
0405 
0406 pp_on_AA.toModify(pixelLessStep, qualityCuts = [-0.4,0.0,0.8])
0407 
0408 # For LowPU
0409 import RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi
0410 pixelLessStepSelector = RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.multiTrackSelector.clone(
0411     src='pixelLessStepTracks',
0412     useAnyMVA      = cms.bool(False),
0413     GBRForestLabel = cms.string('MVASelectorIter5'),
0414     trackSelectors = cms.VPSet(
0415         RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
0416             name = 'pixelLessStepLoose',
0417             chi2n_par = 0.5,
0418             res_par = ( 0.003, 0.001 ),
0419             minNumberLayers = 4,
0420             maxNumberLostLayers = 1,
0421             minNumber3DLayers = 3,
0422             d0_par1 = ( 1.3, 4.0 ),
0423             dz_par1 = ( 1.3, 4.0 ),
0424             d0_par2 = ( 1.3, 4.0 ),
0425             dz_par2 = ( 1.3, 4.0 )
0426         ),
0427         RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.tightMTS.clone(
0428             name = 'pixelLessStepTight',
0429             preFilterName = 'pixelLessStepLoose',
0430             chi2n_par = 0.35,
0431             res_par = ( 0.003, 0.001 ),
0432             minNumberLayers = 4,
0433             maxNumberLostLayers = 0,
0434             minNumber3DLayers = 3,
0435             d0_par1 = ( 1.1, 4.0 ),
0436             dz_par1 = ( 1.1, 4.0 ),
0437             d0_par2 = ( 1.1, 4.0 ),
0438             dz_par2 = ( 1.1, 4.0 )
0439         ),
0440         RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.highpurityMTS.clone(
0441             name = 'QualityMasks',
0442             preFilterName = 'pixelLessStepTight',
0443             chi2n_par = 0.2,
0444             res_par = ( 0.003, 0.001 ),
0445             minNumberLayers = 4,
0446             maxNumberLostLayers = 0,
0447             minNumber3DLayers = 3,
0448             d0_par1 = ( 0.9, 4.0 ),
0449             dz_par1 = ( 0.9, 4.0 ),
0450             d0_par2 = ( 0.9, 4.0 ),
0451             dz_par2 = ( 0.9, 4.0 )
0452         ),
0453     ),
0454     vertices = 'pixelVertices'#end of vpset
0455 ) #end of clone
0456 
0457 vectorHits.toModify(pixelLessStepSelector, 
0458     GBRForestLabel = None,
0459     useAnyMVA = None,
0460     trackSelectors= cms.VPSet(
0461         RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.looseMTS.clone(
0462             name = 'pixelLessStepLoose',
0463             chi2n_par = 1.0,
0464             res_par = ( 0.003, 0.001 ),
0465             minNumberLayers = 0,
0466             maxNumberLostLayers = 1,
0467             minNumber3DLayers = 0,
0468             d0_par1 = ( 0.9, 4.0 ),
0469             dz_par1 = ( 0.9, 4.0 ),
0470             d0_par2 = ( 1.0, 4.0 ),
0471             dz_par2 = ( 1.0, 4.0 )
0472         ),
0473         RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.tightMTS.clone(
0474             name = 'pixelLessStepTight',
0475             preFilterName = 'pixelLessStepLoose',
0476             chi2n_par = 0.35,
0477             res_par = ( 0.003, 0.001 ),
0478             minNumberLayers = 4,
0479             maxNumberLostLayers = 0,
0480             minNumber3DLayers = 3,
0481             d0_par1 = ( 1.1, 4.0 ),
0482             dz_par1 = ( 1.1, 4.0 ),
0483             d0_par2 = ( 1.1, 4.0 ),
0484             dz_par2 = ( 1.1, 4.0 )
0485         ),
0486         RecoTracker.FinalTrackSelectors.multiTrackSelector_cfi.highpurityMTS.clone(
0487             name = 'QualityMasks',
0488             preFilterName = 'pixelLessStepTight',
0489             chi2n_par = 0.2,
0490             res_par = ( 0.003, 0.001 ),
0491             minNumberLayers = 1,
0492             maxNumberLostLayers = 2,
0493             minNumber3DLayers = 0,
0494             d0_par1 = ( 100., 4.0 ),
0495             dz_par1 = ( 100., 4.0 ),
0496             d0_par2 = ( 100., 4.0 ),
0497             dz_par2 = ( 100., 4.0 )
0498         ),
0499     ),
0500     vertices = 'firstStepPrimaryVertices'
0501 ) 
0502 
0503 vectorHits.toModify(pixelLessStepSelector.trackSelectors[2], name = 'pixelLessStep')
0504 
0505 
0506 PixelLessStepTask = cms.Task(pixelLessStepClusters,
0507                              pixelLessStepSeedLayers,
0508                              pixelLessStepTrackingRegions,
0509                              pixelLessStepHitDoublets,
0510                              pixelLessStepHitTriplets,
0511                              pixelLessStepSeeds,
0512                              pixelLessStepTrackCandidates,
0513                              pixelLessStepTracks,
0514                              pixelLessStepClassifier1,pixelLessStepClassifier2,
0515                              pixelLessStep)
0516 PixelLessStep = cms.Sequence(PixelLessStepTask)
0517 
0518 _PixelLessStepTask_trackingMkFit = PixelLessStepTask.copy()
0519 _PixelLessStepTask_trackingMkFit.add(pixelLessStepTrackCandidatesMkFitSeeds, pixelLessStepTrackCandidatesMkFit, pixelLessStepTrackCandidatesMkFit)
0520 trackingMkFitPixelLessStep.toReplaceWith(PixelLessStepTask, _PixelLessStepTask_trackingMkFit)
0521 
0522 _PixelLessStepTask_LowPU = PixelLessStepTask.copyAndExclude([pixelLessStepHitTriplets, pixelLessStepClassifier1, pixelLessStepClassifier2])
0523 _PixelLessStepTask_LowPU.replace(pixelLessStep, pixelLessStepSelector)
0524 trackingLowPU.toReplaceWith(PixelLessStepTask, _PixelLessStepTask_LowPU)
0525 #fastsim
0526 from FastSimulation.Tracking.FastTrackerRecHitMaskProducer_cfi import maskProducerFromClusterRemover
0527 pixelLessStepMasks = maskProducerFromClusterRemover(pixelLessStepClusters)
0528 fastSim.toReplaceWith(PixelLessStepTask,
0529                       cms.Task(pixelLessStepMasks
0530                                    ,pixelLessStepTrackingRegions
0531                                    ,pixelLessStepSeeds
0532                                    ,pixelLessStepTrackCandidates
0533                                    ,pixelLessStepTracks
0534                                    ,pixelLessStepClassifier1,pixelLessStepClassifier2
0535                                    ,pixelLessStep                             
0536                                    )
0537 )
0538 from RecoLocalTracker.SiPhase2VectorHitBuilder.siPhase2VectorHits_cfi import *
0539 from RecoTracker.TkSeedGenerator.SeedingOTEDProducer_cfi import SeedingOTEDProducer as _SeedingOTEDProducer
0540 pixelLessStepSeeds_vectorHits = _SeedingOTEDProducer.clone()
0541 
0542 _PixelLessStepTask_vectorHits = cms.Task(siPhase2VectorHits,
0543                  pixelLessStepClusters,
0544                              pixelLessStepSeeds,
0545                              pixelLessStepTrackCandidates,
0546                              pixelLessStepTracks,
0547                              pixelLessStepSelector)
0548 _PixelLessStep_vectorHits = cms.Sequence(_PixelLessStepTask_vectorHits)
0549 vectorHits.toReplaceWith(pixelLessStepSeeds,pixelLessStepSeeds_vectorHits)
0550 vectorHits.toReplaceWith(PixelLessStepTask, _PixelLessStepTask_vectorHits)
0551 vectorHits.toReplaceWith(PixelLessStep, _PixelLessStep_vectorHits)