Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2023-10-25 10:01:07

0001 import FWCore.ParameterSet.Config as cms
0002 
0003 ###### Muon reconstruction module #####
0004 from RecoMuon.MuonIdentification.earlyMuons_cfi import earlyDisplacedMuons
0005 
0006 ###### SEEDER MODELS ######
0007 #for displaced global muons
0008 import RecoTracker.SpecialSeedGenerators.outInSeedsFromStandaloneMuons_cfi
0009 muonSeededSeedsOutInDisplaced = RecoTracker.SpecialSeedGenerators.outInSeedsFromStandaloneMuons_cfi.outInSeedsFromStandaloneMuons.clone(
0010     src        = "earlyDisplacedMuons",
0011     fromVertex = False
0012 )
0013 ###------------- MeasurementEstimator, defining the searcgh window for pattern recongnition ----------------
0014 #for displaced global muons
0015 import TrackingTools.KalmanUpdators.Chi2MeasurementEstimator_cfi
0016 muonSeededMeasurementEstimatorForOutInDisplaced = TrackingTools.KalmanUpdators.Chi2MeasurementEstimator_cfi.Chi2MeasurementEstimator.clone(
0017     ComponentName = 'muonSeededMeasurementEstimatorForOutInDisplaced',
0018     MaxChi2 = 30.0, ## was 30 ## TO BE TUNED
0019     nSigma  = 3.,    ## was 3  ## TO BE TUNED 
0020 )
0021 
0022 ###------------- TrajectoryFilter, defining selections on the trajectories while building them ----------------
0023 #for displaced global muons
0024 import RecoTracker.IterativeTracking.MuonSeededStep_cff
0025 muonSeededTrajectoryFilterForOutInDisplaced = RecoTracker.IterativeTracking.MuonSeededStep_cff.muonSeededTrajectoryFilterForInOut.clone(
0026     constantValueForLostHitsFractionFilter = 10, ## allow more lost hits
0027     minimumNumberOfHits = 5 ## allow more lost hits
0028 )
0029 ###------------- TrajectoryBuilders ----------------
0030 #for displaced global muons
0031 muonSeededTrajectoryBuilderForOutInDisplaced = RecoTracker.CkfPattern.GroupedCkfTrajectoryBuilder_cfi.GroupedCkfTrajectoryBuilder.clone(
0032     foundHitBonus = 1000.0,
0033     lostHitPenalty = 1.0,
0034     maxCand   = 3,
0035     estimator = 'muonSeededMeasurementEstimatorForOutInDisplaced',
0036     trajectoryFilter = dict(refToPSet_ = 'muonSeededTrajectoryFilterForOutInDisplaced'),
0037     inOutTrajectoryFilter = dict(refToPSet_ = 'muonSeededTrajectoryFilterForOutInDisplaced'), # not sure if it is used
0038     minNrOfHitsForRebuild    = 5,
0039     requireSeedHitsInRebuild = True, 
0040     keepOriginalIfRebuildFails = False, 
0041 )
0042 ######## TRACK CANDIDATE MAKERS
0043 #for displaced global muons
0044 muonSeededTrackCandidatesOutInDisplaced = RecoTracker.CkfPattern.CkfTrackCandidates_cfi.ckfTrackCandidates.clone(
0045     src = "muonSeededSeedsOutInDisplaced",
0046     TrajectoryBuilderPSet = dict(refToPSet_ = "muonSeededTrajectoryBuilderForOutInDisplaced"),
0047     TrajectoryCleaner = 'muonSeededTrajectoryCleanerBySharedHits',
0048     numHitsForSeedCleaner = cms.int32(50),
0049     onlyPixelHitsForSeedCleaner = cms.bool(False),
0050 )
0051 
0052 ######## TRACK PRODUCERS 
0053 #for displaced global muon
0054 muonSeededTracksOutInDisplaced = RecoTracker.TrackProducer.TrackProducer_cfi.TrackProducer.clone(
0055     src = "muonSeededTrackCandidatesOutInDisplaced",
0056     AlgorithmName = 'muonSeededStepOutIn',
0057     Fitter = "muonSeededFittingSmootherWithOutliersRejectionAndRK",
0058 )
0059 
0060 #for displaced global muons
0061 muonSeededTracksOutInDisplacedClassifier = RecoTracker.IterativeTracking.MuonSeededStep_cff.muonSeededTracksOutInClassifier.clone(
0062     src='muonSeededTracksOutInDisplaced'
0063 )
0064 
0065 #for displaced global muons
0066 muonSeededStepCoreDisplacedTask = cms.Task(
0067     cms.TaskPlaceholder("muonSeededStepCoreInOutTask"),
0068     muonSeededSeedsOutInDisplaced , muonSeededTrackCandidatesOutInDisplaced , muonSeededTracksOutInDisplaced
0069 )
0070 muonSeededStepCoreDisplaced = cms.Sequence(muonSeededStepCoreDisplacedTask)
0071 
0072 #for displaced global muons
0073 muonSeededStepExtraDisplacedTask = cms.Task(
0074     cms.TaskPlaceholder("muonSeededStepExtraInOutTask"),
0075     muonSeededTracksOutInDisplacedClassifier
0076 )
0077 muonSeededStepExtraDisplaced = cms.Sequence(muonSeededStepExtraDisplacedTask)
0078 
0079 #for displaced global muons
0080 muonSeededStepDisplacedTask = cms.Task(
0081     earlyDisplacedMuons ,
0082     muonSeededStepCoreDisplacedTask ,
0083     muonSeededStepExtraDisplacedTask 
0084 )
0085 muonSeededStepDisplaced = cms.Sequence(muonSeededStepDisplacedTask)
0086     
0087 ##### MODULES FOR DEBUGGING ###############3
0088 #for displaced global muons
0089 muonSeededSeedsOutInDisplacedAsTracks = cms.EDProducer("FakeTrackProducerFromSeed", src = cms.InputTag("muonSeededSeedsOutInDisplaced"))
0090 #for displaced global muons
0091 muonSeededTrackCandidatesOutInDisplacedAsTracks = cms.EDProducer("FakeTrackProducerFromCandidate", src = cms.InputTag("muonSeededTrackCandidatesOutInDisplaced"))
0092 #for displaced global muons
0093 muonSeededStepDebugDisplacedTask = cms.Task(
0094     cms.TaskPlaceholder("muonSeededStepDebugInOutTask"),
0095     muonSeededSeedsOutInDisplacedAsTracks , muonSeededTrackCandidatesOutInDisplacedAsTracks 
0096 )
0097 muonSeededStepDebugDisplaced = cms.Sequence(muonSeededStepDebugDisplacedTask)