CMS 3D CMS Logo

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
muonValidationHeavyIons_cff.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 
5 
6 # MuonAssociation labels; hit-by-hit matching only,MuonAssociator
7 #
8 import SimMuon.MCTruth.MuonAssociatorByHits_cfi
9 hiMABH = SimMuon.MCTruth.MuonAssociatorByHits_cfi.muonAssociatorByHits.clone(
10 # DEFAULTS ###################################
11 # EfficiencyCut_track = cms.double(0.),
12 # PurityCut_track = cms.double(0.),
13 # EfficiencyCut_muon = cms.double(0.),
14 # PurityCut_muon = cms.double(0.),
15 # includeZeroHitMuons = cms.bool(True),
16 # acceptOneStubMatchings = cms.bool(False),
17 
18  tpTag = 'cutsTpMuons',
19  #acceptOneStubMatchings = True # this was the OLD setting
20  PurityCut_track = 0.75,
21  PurityCut_muon = 0.75
22  #EfficiencyCut_track = 0.5 # maybe this could be added
23  #EfficiencyCut_muon = 0.5 # maybe this could be added
24  #includeZeroHitMuons = False # maybe this could be added
25 )
26 
27 
28 # sim to tracker tracks,
29 tpToTkMuonAssociationHI = hiMABH.clone(
30  tracksTag = 'cutsRecoTrkMuons',
31  UseTracker = True,
32  UseMuon = False
33 )
34 # sim to sta, and sta:updatedAtVtx
35 tpToStaMuonAssociationHI = hiMABH.clone(
36  tracksTag = 'standAloneMuons',
37  UseTracker = False,
38  UseMuon = True
39 )
40 tpToStaUpdMuonAssociationHI = hiMABH.clone(
41  tracksTag = 'standAloneMuons:UpdatedAtVtx',
42  UseTracker = False,
43  UseMuon = True
44 )
45 # sim to glb track
46 tpToGlbMuonAssociationHI = hiMABH.clone(
47  tracksTag = 'globalMuons',
48  UseTracker = True,
49  UseMuon = True
50 )
51 
52 # Muon association sequences
53 # (some are commented out until timing is addressed)
54 hiMuonAssociation_seq = cms.Sequence(
55  tpToTkMuonAssociationHI+
56  tpToStaMuonAssociationHI+
57  tpToStaUpdMuonAssociationHI+
58  tpToGlbMuonAssociationHI
59  )
60 
61 #----------------------------------------
62 
64 
65 import Validation.RecoMuon.MuonTrackValidator_cfi
66 MTVhi = Validation.RecoMuon.MuonTrackValidator_cfi.muonTrackValidator.clone()
67 MTVhi.label_tp_effic = cms.InputTag("cutsTpMuons")
68 MTVhi.label_tp_fake = cms.InputTag("cutsTpMuons")
69 MTVhi.maxPt = cms.double(100)
70 
71 # MuonTrackValidator parameters
72 trkMuonTrackVMuonAssocHI = MTVhi.clone(
73  associatormap = 'tpToTkMuonAssociationHI',
74  label = ['cutsRecoTrkMuons'],
75  muonHistoParameters = trkMuonHistoParameters
76 )
77 glbMuonTrackVMuonAssocHI = MTVhi.clone(
78  associatormap = 'tpToGlbMuonAssociationHI',
79  label = ['globalMuons'],
80  muonHistoParameters = glbMuonHistoParameters
81 )
82 staMuonTrackVMuonAssocHI = MTVhi.clone(
83  associatormap = 'tpToStaMuonAssociationHI',
84  label = ('standAloneMuons',),
85  muonHistoParameters = staMuonHistoParameters
86 )
87 staUpdMuonTrackVMuonAssocHI = MTVhi.clone(
88  associatormap = 'tpToStaUpdMuonAssociationHI',
89  label = ('standAloneMuons:UpdatedAtVtx',),
90  muonHistoParameters = staUpdMuonHistoParameters
91 )
92 
93 # Muon validation sequences
94 hiMuonValidation_seq = cms.Sequence(
95  trkMuonTrackVMuonAssocHI+
96  staMuonTrackVMuonAssocHI+
97  staUpdMuonTrackVMuonAssocHI+
98  glbMuonTrackVMuonAssocHI
99  )
100 
101 # HI muon prevalidation
102 hiRecoMuonPrevalidation = cms.Sequence(
103  cutsRecoTrkMuons
104  * cutsTpMuons
105  * hiMuonAssociation_seq
106 )
107 
108 # HI muon validation sequence
109 hiRecoMuonValidation = cms.Sequence( hiMuonValidation_seq )