CMS 3D CMS Logo

RecoTLR.py
Go to the documentation of this file.
1 import FWCore.ParameterSet.Config as cms
2 
3 ##############################################################################
4 # common utilities
5 ##############################################################################
7  from RecoVertex.BeamSpotProducer.BeamSpotOnline_cfi import onlineBeamSpotProducer
8  process.offlineBeamSpot = onlineBeamSpotProducer.clone()
9  return process
10 
11 def _addLumiProducer(process):
12  if not hasattr(process,'lumiProducer'):
13  #unscheduled..
14  from RecoLuminosity.LumiProducer.lumiProducer_cff import lumiProducer,LumiDBService
15  process.lumiProducer=lumiProducer
16  #if it's scheduled
17  if hasattr(process, 'reconstruction_step'):
18  process.reconstruction_step+=process.lumiProducer
19 
20  return process
21 
22 def _overridesFor50ns(process):
23  process.bunchSpacingProducer.bunchSpacingOverride = cms.uint32(50)
24  process.bunchSpacingProducer.overrideBunchSpacing = cms.bool(True)
25 
26  return process
27 
28 ##############################################################################
29 # post-era customizations
30 # these are here instead of generating Data-specific eras
31 ##############################################################################
32 def _hcalCustoms25ns(process):
33  import RecoLocalCalo.HcalRecAlgos.RemoveAddSevLevel as HcalRemoveAddSevLevel
34  HcalRemoveAddSevLevel.AddFlag(process.hcalRecAlgos,"HFDigiTime",8)
35  HcalRemoveAddSevLevel.AddFlag(process.hcalRecAlgos,"HBHEFlatNoise",8)
36  return process
37 
39  _hcalCustoms25ns(process)
40  return process
41 
43  _hcalCustoms25ns(process)
44  return process
45 
47  import RecoLocalCalo.HcalRecAlgos.RemoveAddSevLevel as HcalRemoveAddSevLevel
48  HcalRemoveAddSevLevel.AddFlag(process.hcalRecAlgos,"HBHEFlatNoise",8)
49  HcalRemoveAddSevLevel.RemoveFlag(process.hcalRecAlgos,"HFDigiTime")
50  return process
51 
54  from Calibration.TkAlCaRecoProducers.PCLHPbeamspot_custom import customise_HPbeamspot as _customise_HPbeamspot
55  _customise_HPbeamspot(process)
56  return process
57 
59  from Calibration.TkAlCaRecoProducers.PCLHPbeamspot_custom import customise_HPbeamspot as _customise_HPbeamspot
60  _customise_HPbeamspot(process)
61  return process
62 
65  return process
66 
69  return process
70 
71 # 2018 equivalents
73  #start with a repeat of 2017
75  return process
76 
78  #start with a repeat of 2017
80  return process
81 
83  #start with a repeat of 2017
85  return process
86 
87 
88 ##############################################################################
89 def customisePPData(process):
90  #deprecated process= customiseCommon(process)
91  ##all customisation for data are now deprecated to Reconstruction_Data_cff
92  #left as a place holder to alter production sequences in case of emergencies
93  return process
94 
95 
96 ##############################################################################
97 def customisePPMC(process):
98  #deprecated process=customiseCommon(process)
99  #left as a place holder to alter production sequences in case of emergencies
100  return process
101 
102 ##############################################################################
103 def customiseCosmicData(process):
104  return process
105 
106 
107 ##############################################################################
108 def customiseCosmicMC(process):
109  return process
110 
111 ##############################################################################
112 def customiseVALSKIM(process):
113  print "WARNING"
114  print "this method is outdated, please use RecoTLR.customisePPData"
115  process= customisePPData(process)
116  return process
117 
118 
119 ##############################################################################
120 def customiseExpress(process):
121  process= customisePPData(process)
122  process = _swapOfflineBSwithOnline(process)
123  return process
124 
125 ##############################################################################
126 def customisePrompt(process):
127  process= customisePPData(process)
128  process = _addLumiProducer(process)
129 
130  return process
131 
132 ##############################################################################
133 # Heavy Ions
134 ##############################################################################
135 # keep it in case modification is needed
136 def customiseCommonHI(process):
137  return process
138 
139 ##############################################################################
140 def customiseExpressHI(process):
141  process = customiseCommonHI(process)
142  process = _swapOfflineBSwithOnline(process)
143 
144  return process
145 
146 ##############################################################################
147 def customisePromptHI(process):
148  process = customiseCommonHI(process)
149 
150  process = _addLumiProducer(process)
151 
152  return process
153 
154 ##############################################################################
155 ##############################################################################
156 
163  from SLHCUpgradeSimulations.Configuration.muonCustoms import unganged_me1a_geometry,customise_csc_LocalReco
164  process = unganged_me1a_geometry(process)
165  process = customise_csc_LocalReco(process)
166 
167  if hasattr(process,'valCscTriggerPrimitiveDigis'):
168  #this is not doing anything at the moment
169  process.valCscTriggerPrimitiveDigis.commonParam.gangedME1a = cms.bool(False)
170  if hasattr(process,'valCsctfTrackDigis'):
171  process.valCsctfTrackDigis.gangedME1a = cms.untracked.bool(False)
172 
173  from SLHCUpgradeSimulations.Configuration.postLS1Customs import customise_Reco,customise_RawToDigi,customise_DQM
174  if hasattr(process,'RawToDigi'):
175  process=customise_RawToDigi(process)
176  if hasattr(process,'reconstruction'):
177  process=customise_Reco(process)
178  if hasattr(process,'dqmoffline_step'):
179  process=customise_DQM(process)
180 
181  return process
182 
183 # add stage1
185  process = customiseDataRun2Common(process)
186 
187  from L1Trigger.L1TCommon.customsPostLS1 import customiseL1RecoForStage1
188  process=customiseL1RecoForStage1(process)
189 
190  return process
191 
192 ##############################################################################
193 # common+ "25ns" Use this for data daking starting from runs in 2015C (>= 253256 )
195  process = customiseDataRun2Common_withStage1(process)
196 
197  _hcalCustoms25ns(process)
198 
199  from SLHCUpgradeSimulations.Configuration.postLS1Customs import customise_DQM_25ns
200  if hasattr(process,'dqmoffline_step'):
201  process=customise_DQM_25ns(process)
202  return process
203 
204 # common+50ns. Needed only for runs >= 253000 if taken with 50ns
206  process = customiseDataRun2Common_withStage1(process)
207 
208  process = _overridesFor50ns(process)
209 
210  return process
211 
212 ##############################################################################
213 # keep it in case modification is needed
215  process = customiseDataRun2Common_withStage1(process)
216 
217  process = _overridesFor50ns(process)
218  # HI Specific additional customizations:
219  # from L1Trigger.L1TCommon.customsPostLS1 import customiseSimL1EmulatorForPostLS1_Additional_HI
220  # process = customiseSimL1EmulatorForPostLS1_Additional_HI(process)
221 
222  return process
def customise_DQM_25ns(process)
def customisePostEra_Run2_2017_ppRef(process)
Definition: RecoTLR.py:67
def _overridesFor50ns(process)
Definition: RecoTLR.py:22
def customise_Reco(process)
def customisePostEra_Run2_2017_pp_on_XeXe(process)
Definition: RecoTLR.py:63
def _hcalCustoms25ns(process)
post-era customizations these are here instead of generating Data-specific eras
Definition: RecoTLR.py:32
def customise_csc_LocalReco(process)
Definition: muonCustoms.py:207
def customiseCosmicData(process)
Definition: RecoTLR.py:103
def customiseVALSKIM(process)
Definition: RecoTLR.py:112
def customisePPMC(process)
Definition: RecoTLR.py:97
def customiseExpressHI(process)
Definition: RecoTLR.py:140
def customisePostEra_Run2_2018_express_trackingOnly(process)
Definition: RecoTLR.py:77
def customise_DQM(process)
def _addLumiProducer(process)
Definition: RecoTLR.py:11
def customiseRun2CommonHI(process)
keep it in case modification is needed
Definition: RecoTLR.py:214
def customise_RawToDigi(process)
def customiseDataRun2Common(process)
ALL FUNCTIONS BELOW ARE GOING TO BE REMOVED IN 81X.
Definition: RecoTLR.py:162
def customisePostEra_Run2_2018_harvesting_trackingOnly(process)
Definition: RecoTLR.py:82
def customisePostEra_Run2_2017_express_trackingOnly(process)
Definition: RecoTLR.py:52
def customisePostEra_Run2_2017(process)
Definition: RecoTLR.py:46
def customisePromptHI(process)
Definition: RecoTLR.py:147
def customisePrompt(process)
Definition: RecoTLR.py:126
def customiseDataRun2Common_25ns(process)
common+ "25ns" Use this for data daking starting from runs in 2015C (>= 253256 )
Definition: RecoTLR.py:194
def customiseExpress(process)
Definition: RecoTLR.py:120
def customisePostEra_Run2_25ns(process)
Definition: RecoTLR.py:38
def unganged_me1a_geometry(process)
Definition: muonCustoms.py:4
def customiseDataRun2Common_50nsRunsAfter253000(process)
Definition: RecoTLR.py:205
def customisePostEra_Run2_2017_harvesting_trackingOnly(process)
Definition: RecoTLR.py:58
def customisePPData(process)
Definition: RecoTLR.py:89
def customisePostEra_Run2_2018(process)
Definition: RecoTLR.py:72
def customiseDataRun2Common_withStage1(process)
Definition: RecoTLR.py:184
def customiseL1RecoForStage1(process)
def customiseCosmicMC(process)
Definition: RecoTLR.py:108
def _swapOfflineBSwithOnline(process)
common utilities
Definition: RecoTLR.py:6
def customisePostEra_Run2_2016(process)
Definition: RecoTLR.py:42
def customiseCommonHI(process)
Heavy Ions.
Definition: RecoTLR.py:136