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  _hcalCustoms25ns(process)
48  return process
49 
52  from Calibration.TkAlCaRecoProducers.PCLHPbeamspot_custom import customise_HPbeamspot as _customise_HPbeamspot
53  _customise_HPbeamspot(process)
54  return process
55 
57  from Calibration.TkAlCaRecoProducers.PCLHPbeamspot_custom import customise_HPbeamspot as _customise_HPbeamspot
58  _customise_HPbeamspot(process)
59  return process
60 
61 
62 ##############################################################################
63 def customisePPData(process):
64  #deprecated process= customiseCommon(process)
65  ##all customisation for data are now deprecated to Reconstruction_Data_cff
66  #left as a place holder to alter production sequences in case of emergencies
67  return process
68 
69 
70 ##############################################################################
71 def customisePPMC(process):
72  #deprecated process=customiseCommon(process)
73  #left as a place holder to alter production sequences in case of emergencies
74  return process
75 
76 ##############################################################################
77 def customiseCosmicData(process):
78  return process
79 
80 
81 ##############################################################################
82 def customiseCosmicMC(process):
83  return process
84 
85 ##############################################################################
86 def customiseVALSKIM(process):
87  print "WARNING"
88  print "this method is outdated, please use RecoTLR.customisePPData"
89  process= customisePPData(process)
90  return process
91 
92 
93 ##############################################################################
94 def customiseExpress(process):
95  process= customisePPData(process)
96  process = _swapOfflineBSwithOnline(process)
97  return process
98 
99 ##############################################################################
100 def customisePrompt(process):
101  process= customisePPData(process)
102  process = _addLumiProducer(process)
103 
104  return process
105 
106 ##############################################################################
107 # Heavy Ions
108 ##############################################################################
109 # keep it in case modification is needed
110 def customiseCommonHI(process):
111  return process
112 
113 ##############################################################################
114 def customiseExpressHI(process):
115  process = customiseCommonHI(process)
116  process = _swapOfflineBSwithOnline(process)
117 
118  return process
119 
120 ##############################################################################
121 def customisePromptHI(process):
122  process = customiseCommonHI(process)
123 
124  process = _addLumiProducer(process)
125 
126  return process
127 
128 ##############################################################################
129 ##############################################################################
130 
137  from SLHCUpgradeSimulations.Configuration.muonCustoms import unganged_me1a_geometry,customise_csc_LocalReco
138  process = unganged_me1a_geometry(process)
139  process = customise_csc_LocalReco(process)
140 
141  if hasattr(process,'valCscTriggerPrimitiveDigis'):
142  #this is not doing anything at the moment
143  process.valCscTriggerPrimitiveDigis.commonParam.gangedME1a = cms.bool(False)
144  if hasattr(process,'valCsctfTrackDigis'):
145  process.valCsctfTrackDigis.gangedME1a = cms.untracked.bool(False)
146 
147  from SLHCUpgradeSimulations.Configuration.postLS1Customs import customise_Reco,customise_RawToDigi,customise_DQM
148  if hasattr(process,'RawToDigi'):
149  process=customise_RawToDigi(process)
150  if hasattr(process,'reconstruction'):
151  process=customise_Reco(process)
152  if hasattr(process,'dqmoffline_step'):
153  process=customise_DQM(process)
154 
155  return process
156 
157 # add stage1
159  process = customiseDataRun2Common(process)
160 
161  from L1Trigger.L1TCommon.customsPostLS1 import customiseL1RecoForStage1
162  process=customiseL1RecoForStage1(process)
163 
164  return process
165 
166 ##############################################################################
167 # common+ "25ns" Use this for data daking starting from runs in 2015C (>= 253256 )
169  process = customiseDataRun2Common_withStage1(process)
170 
171  _hcalCustoms25ns(process)
172 
173  from SLHCUpgradeSimulations.Configuration.postLS1Customs import customise_DQM_25ns
174  if hasattr(process,'dqmoffline_step'):
175  process=customise_DQM_25ns(process)
176  return process
177 
178 # common+50ns. Needed only for runs >= 253000 if taken with 50ns
180  process = customiseDataRun2Common_withStage1(process)
181 
182  process = _overridesFor50ns(process)
183 
184  return process
185 
186 ##############################################################################
187 # keep it in case modification is needed
189  process = customiseDataRun2Common_withStage1(process)
190 
191  process = _overridesFor50ns(process)
192  # HI Specific additional customizations:
193  # from L1Trigger.L1TCommon.customsPostLS1 import customiseSimL1EmulatorForPostLS1_Additional_HI
194  # process = customiseSimL1EmulatorForPostLS1_Additional_HI(process)
195 
196  return process
def customise_DQM_25ns(process)
def _overridesFor50ns(process)
Definition: RecoTLR.py:22
def customise_DQM(process)
Definition: gemCustoms.py:36
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:77
def customise_Reco(process)
Definition: gemCustoms.py:33
def customiseVALSKIM(process)
Definition: RecoTLR.py:86
def customisePPMC(process)
Definition: RecoTLR.py:71
def customiseExpressHI(process)
Definition: RecoTLR.py:114
def _addLumiProducer(process)
Definition: RecoTLR.py:11
def customise_RawToDigi(process)
Definition: gemCustoms.py:30
def customiseRun2CommonHI(process)
keep it in case modification is needed
Definition: RecoTLR.py:188
def customiseDataRun2Common(process)
ALL FUNCTIONS BELOW ARE GOING TO BE REMOVED IN 81X.
Definition: RecoTLR.py:136
def customisePostEra_Run2_2017_express_trackingOnly(process)
Definition: RecoTLR.py:50
def customisePostEra_Run2_2017(process)
Definition: RecoTLR.py:46
def customisePromptHI(process)
Definition: RecoTLR.py:121
def customisePrompt(process)
Definition: RecoTLR.py:100
def customiseDataRun2Common_25ns(process)
common+ "25ns" Use this for data daking starting from runs in 2015C (>= 253256 )
Definition: RecoTLR.py:168
def customiseExpress(process)
Definition: RecoTLR.py:94
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:179
def customisePostEra_Run2_2017_harvesting_trackingOnly(process)
Definition: RecoTLR.py:56
def customisePPData(process)
Definition: RecoTLR.py:63
def customiseDataRun2Common_withStage1(process)
Definition: RecoTLR.py:158
def customiseL1RecoForStage1(process)
def customiseCosmicMC(process)
Definition: RecoTLR.py:82
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:110