CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
TrackingSourceConfig_Tier0_cff.py
Go to the documentation of this file.
2 
3 ### load which are the tracks collection 2 be monitored
5 
6 ### load the different flavour of settings of the TrackingMonitor module
8 
9 
10 ### define one EDAnalyzer per each track collection
11 ### following suggestion 2. in
12 ### https://hypernews.cern.ch/HyperNews/CMS/get/sw-develtools/1908/1.html
13 for tracks in selectedTracks :
14  label = 'TrackerCollisionSelectedTrackMonCommon' + str(tracks)
15  locals()[label] = TrackerCollisionTrackMonCommon.clone()
16  locals()[label].TrackProducer = cms.InputTag(tracks)
17  locals()[label].FolderName = cms.string(mainfolderName[tracks])
18  locals()[label].PVFolderName = cms.string(vertexfolderName[tracks])
19  locals()[label].TrackPtMin = trackPtMin[tracks]
20  locals()[label].TrackPtMax = trackPtMax[tracks]
21  locals()[label].TrackPMin = trackPtMin[tracks]
22  locals()[label].TrackPMax = trackPtMax[tracks]
23  locals()[label].doDCAPlots = doPlotsPCA[tracks]
24  locals()[label].doDCAwrtPVPlots = doPlotsPCA[tracks]
25  locals()[label].doDCAwrt000Plots = doPlotsPCA[tracks]
26  locals()[label].doSIPPlots = doPlotsPCA[tracks]
27  locals()[label].numCut = numCutString[tracks]
28  locals()[label].denCut = denCutString[tracks]
29  locals()[label].setLabel(label)
30 
31 
32  label = 'TrackerCollisionSelectedTrackMonMB' + str(tracks)
33  locals()[label] = TrackerCollisionTrackMonMB.clone()
34  locals()[label].TrackProducer = cms.InputTag(tracks)
35  locals()[label].FolderName = cms.string(mainfolderName[tracks])
36  locals()[label].PVFolderName = cms.string(vertexfolderName[tracks])
37  locals()[label].TrackPtMin = trackPtMin[tracks]
38  locals()[label].TrackPtMax = trackPtMax[tracks]
39  locals()[label].TrackPMin = trackPtMin[tracks]
40  locals()[label].TrackPMax = trackPtMax[tracks]
41  locals()[label].doDCAPlots = doPlotsPCA[tracks]
42  locals()[label].doDCAwrtPVPlots = doPlotsPCA[tracks]
43  locals()[label].doDCAwrt000Plots = doPlotsPCA[tracks]
44  locals()[label].doSIPPlots = doPlotsPCA[tracks]
45  locals()[label].numCut = numCutString[tracks]
46  locals()[label].denCut = denCutString[tracks]
47  locals()[label].setLabel(label)
48 
49 
50 #-------------------------------------------------
51 # Tracking Monitor
52 #-------------------------------------------------
53 import DQM.TrackingMonitor.TrackingMonitorSeed_cfi
54 
56 for step in selectedIterTrackingStep :
57  label = 'TrackSeedMon'+str(step)
58  locals()[label] = DQM.TrackingMonitor.TrackingMonitorSeed_cfi.TrackMonSeed.clone(
59  doTrackCandHistos = cms.bool(True)
60  )
61  locals()[label].TrackProducer = cms.InputTag("generalTracks")
62  locals()[label].FolderName = cms.string("Tracking/TrackParameters/generalTracks")
63  locals()[label].SeedProducer = seedInputTag[step]
64  locals()[label].TCProducer = trackCandInputTag[step]
65  locals()[label].AlgoName = cms.string( str(step) )
66  locals()[label].TkSeedSizeBin = trackSeedSizeBin[step]
67  locals()[label].TkSeedSizeMin = trackSeedSizeMin[step]
68  locals()[label].TkSeedSizeMax = trackSeedSizeMax[step]
69  locals()[label].ClusterLabels = clusterLabel[step]
70  if clusterLabel[step] == cms.vstring('Pix') :
71  locals()[label].NClusPxBin = clusterBin[step]
72  locals()[label].NClusPxMax = clusterMax[step]
73  elif clusterLabel[step] == cms.vstring('Strip') or clusterLabel[step] == cms.vstring('Tot') :
74  locals()[label].NClusStrBin = clusterBin[step]
75  locals()[label].NClusStrMax = clusterMax[step]
76 
77 # DQM Services
78 dqmInfoTracking = cms.EDAnalyzer("DQMEventInfo",
79  subSystemFolder = cms.untracked.string('Tracking')
80 )
81 
82 # LogMessageMonitor ####
83 ### load which are the module to monitor
85 
86 ### load the different flavour of settings of the LogMessageMonitor module
88 
89 for module in selectedModules :
90  label = str(module)+'LogMessageMonCommon'
91  locals()[label] = LogMessageMonCommon.clone()
92  locals()[label].pluginsMonName = pluginsMonName[module]
93  locals()[label].modules = modulesLabel[module]
94  locals()[label].categories = categories[module]
95  locals()[label].setLabel(label)
96 
97  label = str(module)+'LogMessageMonMB'
98  locals()[label] = LogMessageMonMB.clone()
99  locals()[label].pluginsMonName = pluginsMonName[module]
100  locals()[label].modules = modulesLabel[module]
101  locals()[label].categories = categories[module]
102  locals()[label].setLabel(label)
103 
104 
105 # dEdx monitor ####
106 ### load which dedx
108 
109 ### load the different flavour of settings of the dEdxAnalyzer module
111 
112 
113 # temporary patch in order to have BXlumi
115 
116 # temporary test in order to temporary produce the "goodPrimaryVertexCollection"
117 # define with a new name if changes are necessary, otherwise simply include
118 # it from CommonTools/ParticleFlow/python/goodOfflinePrimaryVertices_cfi.py
119 # uncomment when necessary
120 from PhysicsTools.SelectorUtils.pvSelector_cfi import pvSelector
121 from CommonTools.ParticleFlow.goodOfflinePrimaryVertices_cfi import goodOfflinePrimaryVertices
122 trackingDQMgoodOfflinePrimaryVertices = goodOfflinePrimaryVertices.clone()
123 trackingDQMgoodOfflinePrimaryVertices.filterParams = pvSelector.clone( minNdof = cms.double(4.0), maxZ = cms.double(24.0) )
124 trackingDQMgoodOfflinePrimaryVertices.src=cms.InputTag('offlinePrimaryVertices')
125 trackingDQMgoodOfflinePrimaryVertices.filter = cms.bool(False)
126 
127 # Sequence
128 TrackingDQMSourceTier0 = cms.Sequence()
129 # dEdx monitoring
130 TrackingDQMSourceTier0 += dedxHarmonicSequence * dEdxMonCommon * dEdxHitMonCommon
131 # # temporary patch in order to have BXlumi
132 # * lumiProducer
133 # track collections
134 for tracks in selectedTracks :
135  if tracks != 'generalTracks':
136  TrackingDQMSourceTier0 += sequenceName[tracks]
137  label = 'TrackerCollisionSelectedTrackMonCommon' + str(tracks)
138  TrackingDQMSourceTier0 += cms.Sequence(locals()[label])
139 # seeding monitoring
140 for step in selectedIterTrackingStep :
141  label = 'TrackSeedMon'+str(step)
142  TrackingDQMSourceTier0 += cms.Sequence(locals()[label])
143 # MessageLog
144 for module in selectedModules :
145  label = str(module)+'LogMessageMonCommon'
146  TrackingDQMSourceTier0 += cms.Sequence(locals()[label])
147 TrackingDQMSourceTier0 += dqmInfoTracking
148 
149 
150 TrackingDQMSourceTier0Common = cms.Sequence()
151 # dEdx monitoring
152 TrackingDQMSourceTier0Common += (dedxHarmonicSequence * dEdxMonCommon * dEdxHitMonCommon)
153 ## monitor track collections
154 for tracks in selectedTracks :
155  if tracks != 'generalTracks':
156  TrackingDQMSourceTier0Common+=sequenceName[tracks]
157  label = 'TrackerCollisionSelectedTrackMonCommon' + str(tracks)
158  TrackingDQMSourceTier0Common += cms.Sequence(locals()[label])
159 # seeding monitoring
160 for step in selectedIterTrackingStep :
161  label = 'TrackSeedMon'+str(step)
162  TrackingDQMSourceTier0Common += cms.Sequence(locals()[label])
163 # MessageLog
164 for module in selectedModules :
165  label = str(module)+'LogMessageMonCommon'
166  TrackingDQMSourceTier0Common += cms.Sequence(locals()[label])
167 TrackingDQMSourceTier0Common += dqmInfoTracking
168 
169 TrackingDQMSourceTier0MinBias = cms.Sequence()
170 # dEdx monitoring
171 TrackingDQMSourceTier0MinBias += dedxHarmonicSequence * dEdxMonCommon * dEdxHitMonCommon
172 # * lumiProducer
173 # * trackingDQMgoodOfflinePrimaryVertices
174 # monitor track collections
175 for tracks in selectedTracks :
176  if tracks != 'generalTracks':
177  TrackingDQMSourceTier0MinBias += sequenceName[tracks]
178  label = 'TrackerCollisionSelectedTrackMonMB' + str(tracks)
179  TrackingDQMSourceTier0MinBias += cms.Sequence(locals()[label])
180 # seeding monitoring
181 for step in selectedIterTrackingStep :
182  label = 'TrackSeedMon'+str(step)
183  TrackingDQMSourceTier0MinBias += cms.Sequence(locals()[label])
184 # MessageLog
185 for module in selectedModules :
186  label = str(module)+'LogMessageMonMB'
187  TrackingDQMSourceTier0MinBias += cms.Sequence(locals()[label])
188 TrackingDQMSourceTier0MinBias += dqmInfoTracking
189 
load which dedx
load the different flavour of settings of the dEdxAnalyzer module
load which are the tracks collection 2 be monitored
load the different flavour of settings of the LogMessageMonitor module
load which are the module to monitor
load the different flavour of settings of the TrackingMonitor module