CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Functions
reco_TLR_42X Namespace Reference

Functions

def customiseCommon
 
def customiseCommonHI
 
def customiseCosmicData
 
def customiseCosmicMC
 
def customiseExpress
 
def customiseExpressHI
 
def customisePPData
 
def customisePPMC
 
def customisePrompt
 
def customisePromptHI
 
def customiseVALSKIM
 
def memorySavingTracking
 

Function Documentation

def reco_TLR_42X.customiseCommon (   process)

Definition at line 140 of file reco_TLR_42X.py.

References memorySavingTracking().

Referenced by customisePPData(), and customisePPMC().

141 def customiseCommon(process):
142 
143  process = memorySavingTracking(process)
144 
145  return (process)
146 
def memorySavingTracking
Definition: reco_TLR_42X.py:3
def reco_TLR_42X.customiseCommonHI (   process)

Definition at line 213 of file reco_TLR_42X.py.

Referenced by customiseExpressHI(), and customisePromptHI().

214 def customiseCommonHI(process):
215 
216  ###############################################################################################
217  ####
218  #### Top level replaces for handling strange scenarios of early HI collisions
219  ####
220 
221  ## Offline Silicon Tracker Zero Suppression
222  process.siStripZeroSuppression.Algorithms.CommonModeNoiseSubtractionMode = cms.string("IteratedMedian")
223  process.siStripZeroSuppression.Algorithms.CutToAvoidSignal = cms.double(2.0)
224  process.siStripZeroSuppression.Algorithms.Iterations = cms.int32(3)
225  process.siStripZeroSuppression.storeCM = cms.bool(True)
226 
227 
228  ###
229  ### end of top level replacements
230  ###
231  ###############################################################################################
232 
233  return process
def customiseCommonHI
def reco_TLR_42X.customiseCosmicData (   process)

Definition at line 181 of file reco_TLR_42X.py.

182 def customiseCosmicData(process):
183 
184  return process
def customiseCosmicData
def reco_TLR_42X.customiseCosmicMC (   process)

Definition at line 186 of file reco_TLR_42X.py.

187 def customiseCosmicMC(process):
188 
189  return process
def customiseCosmicMC
def reco_TLR_42X.customiseExpress (   process)

Definition at line 197 of file reco_TLR_42X.py.

References customisePPData().

198 def customiseExpress(process):
199  process= customisePPData(process)
200 
202  process.offlineBeamSpot = RecoVertex.BeamSpotProducer.BeamSpotOnline_cfi.onlineBeamSpotProducer.clone()
203 
204  return process
def customiseExpress
def reco_TLR_42X.customiseExpressHI (   process)

Definition at line 235 of file reco_TLR_42X.py.

References customiseCommonHI().

236 def customiseExpressHI(process):
237  process= customiseCommonHI(process)
238 
240  process.offlineBeamSpot = RecoVertex.BeamSpotProducer.BeamSpotOnline_cfi.onlineBeamSpotProducer.clone()
241 
242  return process
def customiseCommonHI
def customiseExpressHI
def reco_TLR_42X.customisePPData (   process)

Definition at line 148 of file reco_TLR_42X.py.

References customiseCommon().

Referenced by customiseExpress(), customisePrompt(), and customiseVALSKIM().

149 def customisePPData(process):
150  process= customiseCommon(process)
151 
152  ## particle flow HF cleaning
153  process.particleFlowRecHitHCAL.LongShortFibre_Cut = 30.
154  process.particleFlowRecHitHCAL.ApplyPulseDPG = True
155 
156  ## HF cleaning for data only
157  process.hcalRecAlgos.SeverityLevels[3].RecHitFlags.remove("HFDigiTime")
158  process.hcalRecAlgos.SeverityLevels[4].RecHitFlags.append("HFDigiTime")
159 
160  ##beam-halo-id for data only
161  process.CSCHaloData.ExpectedBX = cms.int32(3)
162 
163  ## hcal hit flagging
164  process.hfreco.PETstat.flagsToSkip = 2
165  process.hfreco.S8S1stat.flagsToSkip = 18
166  process.hfreco.S9S1stat.flagsToSkip = 26
167 
168  ##Ecal time bias correction
169  process.ecalGlobalUncalibRecHit.doEBtimeCorrection = True
170  process.ecalGlobalUncalibRecHit.doEEtimeCorrection = True
171 
172  return process
173 
def reco_TLR_42X.customisePPMC (   process)

Definition at line 175 of file reco_TLR_42X.py.

References customiseCommon().

176 def customisePPMC(process):
177  process=customiseCommon(process)
178 
179  return process
def reco_TLR_42X.customisePrompt (   process)

Definition at line 206 of file reco_TLR_42X.py.

References customisePPData().

207 def customisePrompt(process):
208  process= customisePPData(process)
209  return process
def reco_TLR_42X.customisePromptHI (   process)

Definition at line 244 of file reco_TLR_42X.py.

References customiseCommonHI().

245 def customisePromptHI(process):
246  process= customiseCommonHI(process)
247 
249  process.offlineBeamSpot = RecoVertex.BeamSpotProducer.BeamSpotOnline_cfi.onlineBeamSpotProducer.clone()
250 
251  return process
def customiseCommonHI
def customisePromptHI
def reco_TLR_42X.customiseVALSKIM (   process)

Definition at line 191 of file reco_TLR_42X.py.

References customisePPData().

192 def customiseVALSKIM(process):
193  process= customisePPData(process)
194  process.reconstruction.remove(process.lumiProducer)
195  return process
def customiseVALSKIM
def reco_TLR_42X.memorySavingTracking (   process)

Definition at line 3 of file reco_TLR_42X.py.

References relativeConstraints.keys.

Referenced by customiseCommon().

3 
4 def memorySavingTracking(process):
5  toRemove={}
6  #list of modules in iterative tracking
7  ## remove rekeying of clusters refs from track producer
8  trackProducers=['preFilterZeroStepTracks',
9  'preFilterStepOneTracks',
10  'secWithMaterialTracks',
11  'thWithMaterialTracks',
12  'fourthWithMaterialTracks',
13  'fifthWithMaterialTracks',
14  ]
15 
16  for tp in trackProducers:
17  m=getattr(process,tp)
18  if hasattr(m,"clusterRemovalInfo"):
19  #print "removing cluter rekeying from",tp
20  delattr(m,"clusterRemovalInfo")
21 
22  measurementTrackers=['MeasurementTracker',
23  'newMeasurementTracker',
24  'secMeasurementTracker',
25  'thMeasurementTracker',
26  'fourthMeasurementTracker',
27  'fifthMeasurementTracker',
28  ]
29 
30  # list of measurement tracker, component names
31  ## create the clusterRef to skip creators (MT+'ToSkip')
32  for mt in measurementTrackers:
33  es=getattr(process,mt)
34  ## modify MT to point to the full cluster list
35  #if es.pixelClusterProducer.value() == 'siPixelClusters':
36  # continue
37 
38  #old trackclusterremoval module
39  removalModule=es.pixelClusterProducer.value()
40 
41  if (removalModule != 'siPixelClusters'):
42  es.skipClusters = cms.InputTag(removalModule)
43  es.pixelClusterProducer = 'siPixelClusters'
44  es.stripClusterProducer = 'siStripClusters'
45  #print mt,es.skipClusters,es.pixelClusterProducer,es.stripClusterProducer
46  tcremoval = getattr(process,removalModule)
47  #print removalModule,"turned to using new scheme"
48  tcremoval.clusterLessSolution= cms.bool(True)
49  tcremoval.stripClusters = 'siStripClusters'
50  tcremoval.pixelClusters = 'siPixelClusters'
51  skipTrackQualityFilter=False
52  if (skipTrackQualityFilter):
53  tcremoval.TrackQuality = cms.string('highPurity')
54  #remove the QualityFilter module from the path
55  toRemove[tcremoval.trajectories.value()]=True
56  qf=getattr(process,tcremoval.trajectories.value())
57  tcremoval.trajectories = qf.recTracks
58  #else:
59  #print mt,'no cluster to skip',es.pixelClusterProducer,es.stripClusterProducer
60 
61  patternRecoModules=[
62  'fifthTrackCandidates',
63  'fourthTrackCandidates',
64  'newTrackCandidateMaker',
65  'secTrackCandidates',
66  'stepOneTrackCandidateMaker',
67  'thTrackCandidates'
68  ]
69 
70  for ckfm in patternRecoModules:
71  ckf=getattr(process,ckfm)
72  builder=getattr(process,ckf.TrajectoryBuilder.value())
73  mtn= builder.MeasurementTrackerName.value()
74  if mtn!='':
75  #make it look at the central MT
76  builder.MeasurementTrackerName=''
77  mt=getattr(process,mtn)
78  # transfer the cluster removal from the MT to the builder
79  builder.clustersToSkip = mt.skipClusters
80  #print "setting",ckf.TrajectoryBuilder.value(),"via",ckfm,"to look at central MT"
81  #print "removing MT:",mtn
82  delattr(process,mtn)
83  #else:
84  #print ckfm,"untouched"
85 
86  #all seeding layers should point to the same rechits collections
87  for esp in process.es_producers_().keys():
88  es = getattr(process,esp)
89  if es._TypedParameterizable__type != 'SeedingLayersESProducer':
90  continue
91  for pm in es.parameters_().keys():
92  p=getattr(es,pm)
93  if p.pythonTypeName() == 'cms.PSet':
94  if hasattr(p,'HitProducer'):
95  #print "pixel",pm,p
96  #pixel case
97  if p.HitProducer != 'siPixelRecHits':
98  toRemove[p.HitProducer.value()]=True
99  skip=getattr(process,p.HitProducer.value()).src
100  p.HitProducer = 'siPixelRecHits'
101  #and set the skipping
102  p.skipClusters = cms.InputTag(skip.value())
103  #print esp,"modified for new skipping"
104  #print esp,pm,p
105 
106  if hasattr(p,'matchedRecHits'):
107  #print "strip",pm,p
108  #strip case
109  ## rename the collection
110  if p.matchedRecHits.moduleLabel != 'siStripMatchedRecHits':
111  toRemove[p.matchedRecHits.moduleLabel]=True
112  skip=getattr(process,p.matchedRecHits.moduleLabel).ClusterProducer
113  p.matchedRecHits.setModuleLabel('siStripMatchedRecHits')
114  #and set the skipping
115  p.skipClusters = cms.InputTag(skip.value())
116  #print esp,pm,p
117 
118 
119  for edp in process.producers_():
120  p=getattr(process,edp)
121  if hasattr(p,'ClusterCheckPSet'):
122  #print "resetting cluster check for",edp
123  p.ClusterCheckPSet.PixelClusterCollectionLabel = 'siPixelClusters'
124  p.ClusterCheckPSet.ClusterCollectionLabel = 'siStripClusters'
125 
126  #force useless module to be removed
127  toRemove['secStripRecHits']=True
128  toRemove['fourthPixelRecHits']=True
129  toRemove['fifthPixelRecHits']=True
130 
131  for tr in toRemove:
132  if hasattr(process,tr):
133  #print "removing",tr
134  process.reconstruction_step.remove(getattr(process,tr))
135 
136  delattr(process.newCombinedSeeds,'clusterRemovalInfos')
137 
138  return (process)
139 
def memorySavingTracking
Definition: reco_TLR_42X.py:3