CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
RecoMuonPPonly_cff.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 
3 # Seed generator
5 # Stand alone muon track producer
7 
8 # refitted stand-alone muons.
9 refittedStandAloneMuons = standAloneMuons.clone(
10  STATrajBuilderParameters = dict(DoRefit = True)
11 )
12 #refittedStandAloneMuons.STATrajBuilderParameters.DoRefit = True
13 # Displaced SA muons
15 displacedMuonSeeds = CosmicMuonSeed.clone(
16  ForcePointDown = False
17 )
18 
19 displacedStandAloneMuons = standAloneMuons.clone(
20  InputObjects = 'displacedMuonSeeds',
21  MuonTrajectoryBuilder = 'StandAloneMuonTrajectoryBuilder',
22  TrackLoaderParameters = dict(VertexConstraint = False)
23 )
24 
25 # Global muon track producer
28 displacedGlobalMuons = globalMuons.clone(
29  MuonCollectionLabel = 'displacedStandAloneMuons:',
30  TrackerCollectionLabel = 'displacedTracks'
31 )
32 
33 # TeV refinement
35 
36 # SET Muon tracking
38 
39 # Muon Id producer
41 muons1stStep.fillGlobalTrackQuality = True
42 
43 #Muon Id isGood flag ValueMap producer sequence
45 
46 # Muon Isolation sequence
48 
49 # ---------------------------------------------------- #
50 ################## Make the sequences ##################
51 # ---------------------------------------------------- #
52 from Configuration.Eras.Modifier_fastSim_cff import fastSim
53 
54 # Muon Tracking sequence
55 standalonemuontrackingTask = cms.Task(standAloneMuons,
56  refittedStandAloneMuons,
57  displacedMuonSeeds,
58  displacedStandAloneMuons,
59  standAloneMuonSeedsTask)
60 standalonemuontracking = cms.Sequence(standalonemuontrackingTask)
61 # not commisoned and not relevant in FastSim (?):
62 fastSim.toReplaceWith(standalonemuontrackingTask,standalonemuontrackingTask.copyAndExclude([displacedMuonSeeds,displacedStandAloneMuons]))
63 displacedGlobalMuonTrackingTask = cms.Task(iterDisplcedTrackingTask,displacedGlobalMuons)
64 displacedGlobalMuonTracking = cms.Sequence(displacedGlobalMuonTrackingTask)
65 
66 globalmuontrackingTask = cms.Task(globalMuons,tevMuons,displacedGlobalMuonTrackingTask)
67 globalmuontracking = cms.Sequence(globalmuontrackingTask)
68 # not commisoned and not relevant in FastSim (?):
69 fastSim.toReplaceWith(globalmuontrackingTask,globalmuontrackingTask.copyAndExclude([displacedGlobalMuonTrackingTask]))
70 muontrackingTask = cms.Task(standalonemuontrackingTask,globalmuontrackingTask)
71 muontracking = cms.Sequence(muontrackingTask)
72 # Muon Reconstruction
73 muonrecoTask = cms.Task(muontrackingTask,muonIdProducerTask)
74 muonreco = cms.Sequence(muonrecoTask)
75 # Muon Reconstruction plus Isolation
76 muonreco_plus_isolationTask = cms.Task(muonrecoTask,muIsolationTask)
77 muonreco_plus_isolation = cms.Sequence(muonreco_plus_isolationTask)
78 
79 muonrecoComplete = cms.Sequence(muonreco_plus_isolationTask,muonSelectionTypeTask)
80 
81 
82 # _-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_- #
83 # -_-_-_- Special Sequences for Iterative tracking -_-_-_- #
84 # -_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_ #
85 
86 # We need to split the muon sequence above in two, to be able to run the MuonSeeding in the tracker. So muonrecoComplete will
87 # be run no longer...
88 
89 #from RecoMuon.MuonIdentification.earlyMuons_cfi import earlyMuons
90 
91 muonGlobalRecoTask = cms.Task(globalmuontrackingTask,
92  muonIdProducerTask,
93  muonSelectionTypeTask,
94  muIsolationTask)
95 muonGlobalReco = cms.Sequence(muonGlobalRecoTask)
96 
97 # ... instead, the sequences will be run in the following order:
98 # 1st - standalonemuontracking
99 # 2nd - iterative tracking (def in RecoTracker config)
100 # 3rd - MuonIDProducer with 1&2 as input, with special replacements; the earlyMuons above.
101 # 4th - MuonSeeded tracks, inside-out and outside-in
102 # 5th - Merging of the new TK tracks into the generalTracks collection
103 # 6th - Run the remnant part of the muon sequence (muonGlobalReco)
104 
105 ########################################################
106 # not commisoned and not relevant in FastSim (?):
107 fastSim.toReplaceWith(muonGlobalRecoTask, muonGlobalRecoTask.copyAndExclude([muonreco_with_SET_Task,muonSelectionTypeTask]))