CMS 3D CMS Logo

Functions
customizeHLTforCMSSW Namespace Reference

Functions

def customiseFor2017DtUnpacking (process)
 
def customiseFor21664_forMahiOn (process)
 
def customiseFor24212 (process)
 
def customiseForEcalTestPR22254Default (process)
 
def customiseForEcalTestPR22254thresholdA (process)
 
def customiseForEcalTestPR22254thresholdB (process)
 
def customiseForEcalTestPR22254thresholdC (process)
 
def customiseForPR24339HybridFormatSiStripZS (process)
 For parameter changes in SiStripClusterizerFromRaw for PbPb 2018 data-taking. More...
 
def customiseForUncollapsed (process)
 
def customizeHLTforCMSSW (process, menuType="GRun")
 

Function Documentation

def customizeHLTforCMSSW.customiseFor2017DtUnpacking (   process)
Adapt the HLT to run the legacy DT unpacking
for pre2018 data/MC workflows as the default

Definition at line 65 of file customizeHLTforCMSSW.py.

66  """Adapt the HLT to run the legacy DT unpacking
67  for pre2018 data/MC workflows as the default"""
68 
69  if hasattr(process,'hltMuonDTDigis'):
70  process.hltMuonDTDigis = cms.EDProducer( "DTUnpackingModule",
71  useStandardFEDid = cms.bool( True ),
72  maxFEDid = cms.untracked.int32( 779 ),
73  inputLabel = cms.InputTag( "rawDataCollector" ),
74  minFEDid = cms.untracked.int32( 770 ),
75  dataType = cms.string( "DDU" ),
76  readOutParameters = cms.PSet(
77  localDAQ = cms.untracked.bool( False ),
78  debug = cms.untracked.bool( False ),
79  rosParameters = cms.PSet(
80  localDAQ = cms.untracked.bool( False ),
81  debug = cms.untracked.bool( False ),
82  writeSC = cms.untracked.bool( True ),
83  readDDUIDfromDDU = cms.untracked.bool( True ),
84  readingDDU = cms.untracked.bool( True ),
85  performDataIntegrityMonitor = cms.untracked.bool( False )
86  ),
87  performDataIntegrityMonitor = cms.untracked.bool( False )
88  ),
89  dqmOnly = cms.bool( False )
90  )
91 
92  return process
93 
94 
95 
96 # particleFlowRechitECAL new default value "false" flag to be added
def customiseFor2017DtUnpacking(process)
def customizeHLTforCMSSW.customiseFor21664_forMahiOn (   process)

Definition at line 58 of file customizeHLTforCMSSW.py.

References common.producers_by_type().

59  for producer in producers_by_type(process, "HBHEPhase1Reconstructor"):
60  producer.algorithm.useMahi = cms.bool(True)
61  producer.algorithm.useM2 = cms.bool(False)
62  producer.algorithm.useM3 = cms.bool(False)
63  return process
64 
def customiseFor21664_forMahiOn(process)
def producers_by_type(process, types)
Definition: common.py:6
def customizeHLTforCMSSW.customiseFor24212 (   process)

Definition at line 189 of file customizeHLTforCMSSW.py.

Referenced by customizeHLTforCMSSW().

189 def customiseFor24212(process):
190  for pfName in "hltParticleFlow", "hltParticleFlowForTaus", "hltParticleFlowReg":
191  pf = getattr(process,pfName,None)
192  if pf: # Treatment of tracks in region of bad HCal
193  pf.goodTrackDeadHcal_ptErrRel = cms.double(0.2) # trackRef->ptError()/trackRef->pt() < X
194  pf.goodTrackDeadHcal_chi2n = cms.double(5) # trackRef->normalizedChi2() < X
195  pf.goodTrackDeadHcal_layers = cms.uint32(4) # trackRef->hitPattern().trackerLayersWithMeasurement() >= X
196  pf.goodTrackDeadHcal_validFr = cms.double(0.5) # trackRef->validFraction() > X
197  pf.goodTrackDeadHcal_dxy = cms.double(0.5) # [cm] abs(trackRef->dxy(primaryVertex_.position())) < X
198  pf.goodPixelTrackDeadHcal_minEta = cms.double(2.3) # abs(trackRef->eta()) > X
199  pf.goodPixelTrackDeadHcal_maxPt = cms.double(50.) # trackRef->ptError()/trackRef->pt() < X
200  pf.goodPixelTrackDeadHcal_ptErrRel = cms.double(1.0) # trackRef->ptError()/trackRef->pt() < X
201  pf.goodPixelTrackDeadHcal_chi2n = cms.double(2) # trackRef->normalizedChi2() < X
202  pf.goodPixelTrackDeadHcal_maxLost3Hit = cms.int32(0) # max missing outer hits for a track with 3 valid pixel layers (can set to -1 to reject all these tracks)
203  pf.goodPixelTrackDeadHcal_maxLost4Hit = cms.int32(1) # max missing outer hits for a track with >= 4 valid pixel layers
204  pf.goodPixelTrackDeadHcal_dxy = cms.double(0.02) # [cm] abs(trackRef->dxy(primaryVertex_.position())) < X
205  pf.goodPixelTrackDeadHcal_dz = cms.double(0.05) # [cm] abs(trackRef->dz(primaryVertex_.position())) < X
206  return process
207 
def customizeHLTforCMSSW.customiseForEcalTestPR22254Default (   process)

Definition at line 97 of file customizeHLTforCMSSW.py.

98 
99  for hltParticleFlowRecHitECAL in ['hltParticleFlowRecHitECALUnseeded', 'hltParticleFlowRecHitECALL1Seeded', 'hltParticleFlowRecHitECALForMuonsMF', 'hltParticleFlowRecHitECALForTkMuonsMF']:
100  if hasattr(process,hltParticleFlowRecHitECAL):
101  module = getattr(process,hltParticleFlowRecHitECAL)
102 
103  for producer in module.producers:
104  if hasattr(producer,'srFlags'):
105  producer.srFlags = cms.InputTag("")
106  if hasattr(producer,'qualityTests'):
107  for qualityTest in producer.qualityTests:
108  if hasattr(qualityTest,'thresholds'):
109  qualityTest.applySelectionsToAllCrystals = cms.bool(True)
110 
111  return process
112 
113 
114 
115 #
116 # The three different set of thresholds will be used to study
117 # possible new thresholds of pfrechits and effects on high level objects
118 # The values proposed (A, B, C) are driven by expected noise levels
119 #
120 
121 # Test thresholds for particleFlowRechitECAL ~ 0.5 sigma
def customiseForEcalTestPR22254Default(process)
def customizeHLTforCMSSW.customiseForEcalTestPR22254thresholdA (   process)

Definition at line 122 of file customizeHLTforCMSSW.py.

123  from Configuration.Eras.Modifier_run2_ECAL_2017_cff import run2_ECAL_2017
124  from RecoParticleFlow.PFClusterProducer.particleFlowZeroSuppressionECAL_cff import _particle_flow_zero_suppression_ECAL_2018_A
125 
126  for hltParticleFlowRecHitECAL in ['hltParticleFlowRecHitECALUnseeded', 'hltParticleFlowRecHitECALL1Seeded', 'hltParticleFlowRecHitECALForMuonsMF', 'hltParticleFlowRecHitECALForTkMuonsMF']:
127  if hasattr(process,hltParticleFlowRecHitECAL):
128  module = getattr(process,hltParticleFlowRecHitECAL)
129 
130  for producer in module.producers:
131  if hasattr(producer,'srFlags'):
132  producer.srFlags = cms.InputTag("")
133  if hasattr(producer,'qualityTests'):
134  for qualityTest in producer.qualityTests:
135  if hasattr(qualityTest,'thresholds'):
136  qualityTest.thresholds = _particle_flow_zero_suppression_ECAL_2018_A.thresholds
137  qualityTest.applySelectionsToAllCrystals = cms.bool(True)
138 
139  return process
140 
141 
142 
143 
144 
145 # Test thresholds for particleFlowRechitECAL ~ 1 sigma
def customiseForEcalTestPR22254thresholdA(process)
def customizeHLTforCMSSW.customiseForEcalTestPR22254thresholdB (   process)

Definition at line 146 of file customizeHLTforCMSSW.py.

147  from Configuration.Eras.Modifier_run2_ECAL_2017_cff import run2_ECAL_2017
148  from RecoParticleFlow.PFClusterProducer.particleFlowZeroSuppressionECAL_cff import _particle_flow_zero_suppression_ECAL_2018_B
149 
150  for hltParticleFlowRecHitECAL in ['hltParticleFlowRecHitECALUnseeded', 'hltParticleFlowRecHitECALL1Seeded', 'hltParticleFlowRecHitECALForMuonsMF', 'hltParticleFlowRecHitECALForTkMuonsMF']:
151  if hasattr(process,hltParticleFlowRecHitECAL):
152  module = getattr(process,hltParticleFlowRecHitECAL)
153 
154  for producer in module.producers:
155  if hasattr(producer,'srFlags'):
156  producer.srFlags = cms.InputTag("")
157  if hasattr(producer,'qualityTests'):
158  for qualityTest in producer.qualityTests:
159  if hasattr(qualityTest,'thresholds'):
160  qualityTest.thresholds = _particle_flow_zero_suppression_ECAL_2018_B.thresholds
161  qualityTest.applySelectionsToAllCrystals = cms.bool(True)
162 
163  return process
164 
165 
166 
167 
168 # Test thresholds for particleFlowRechitECAL ~ 2 sigma
def customiseForEcalTestPR22254thresholdB(process)
def customizeHLTforCMSSW.customiseForEcalTestPR22254thresholdC (   process)

Definition at line 169 of file customizeHLTforCMSSW.py.

170  from Configuration.Eras.Modifier_run2_ECAL_2017_cff import run2_ECAL_2017
171  from RecoParticleFlow.PFClusterProducer.particleFlowZeroSuppressionECAL_cff import _particle_flow_zero_suppression_ECAL_2018_C
172 
173  for hltParticleFlowRecHitECAL in ['hltParticleFlowRecHitECALUnseeded', 'hltParticleFlowRecHitECALL1Seeded', 'hltParticleFlowRecHitECALForMuonsMF', 'hltParticleFlowRecHitECALForTkMuonsMF']:
174  if hasattr(process,hltParticleFlowRecHitECAL):
175  module = getattr(process,hltParticleFlowRecHitECAL)
176 
177  for producer in module.producers:
178  if hasattr(producer,'srFlags'):
179  producer.srFlags = cms.InputTag("")
180  if hasattr(producer,'qualityTests'):
181  for qualityTest in producer.qualityTests:
182  if hasattr(qualityTest,'thresholds'):
183  qualityTest.thresholds = _particle_flow_zero_suppression_ECAL_2018_C.thresholds
184  qualityTest.applySelectionsToAllCrystals = cms.bool(True)
185 
186  return process
187 
188 
def customiseForEcalTestPR22254thresholdC(process)
def customizeHLTforCMSSW.customiseForPR24339HybridFormatSiStripZS (   process)

For parameter changes in SiStripClusterizerFromRaw for PbPb 2018 data-taking.

Definition at line 209 of file customizeHLTforCMSSW.py.

References common.producers_by_type().

Referenced by customizeHLTforCMSSW().

210  for producer in producers_by_type(process, "SiStripClusterizerFromRaw"):
211  producer.Algorithms.Use10bitsTruncation = cms.bool( False )
212  producer.HybridZeroSuppressed = cms.bool( False )
213  return process
214 
215 
216 # CMSSW version specific customizations
def customiseForPR24339HybridFormatSiStripZS(process)
For parameter changes in SiStripClusterizerFromRaw for PbPb 2018 data-taking.
def producers_by_type(process, types)
Definition: common.py:6
def customizeHLTforCMSSW.customiseForUncollapsed (   process)

Definition at line 25 of file customizeHLTforCMSSW.py.

References common.producers_by_type().

26  for producer in producers_by_type(process, "PFClusterProducer"):
27  if producer.seedFinder.thresholdsByDetector[1].detector.value() == 'HCAL_ENDCAP':
28  producer.seedFinder.thresholdsByDetector[1].seedingThreshold = _seedingThresholdsHEphase1
29  producer.initialClusteringStep.thresholdsByDetector[1].gatheringThreshold = _thresholdsHEphase1
30  producer.pfClusterBuilder.recHitEnergyNorms[1].recHitEnergyNorm = _thresholdsHEphase1
31  producer.pfClusterBuilder.positionCalc.logWeightDenominatorByDetector[1].logWeightDenominator = _thresholdsHEphase1
32  producer.pfClusterBuilder.allCellsPositionCalc.logWeightDenominatorByDetector[1].logWeightDenominator = _thresholdsHEphase1
33 
34  for producer in producers_by_type(process, "PFMultiDepthClusterProducer"):
35  producer.pfClusterBuilder.allCellsPositionCalc.logWeightDenominatorByDetector[1].logWeightDenominator = _thresholdsHEphase1HCAL
36 
37  for producer in producers_by_type(process, "PFRecHitProducer"):
38  if producer.producers[0].name.value() == 'PFHBHERecHitCreator':
39  producer.producers[0].qualityTests[0].cuts[1].threshold = _thresholdsHEphase1Rec
40 
41  for producer in producers_by_type(process, "CaloTowersCreator"):
42  producer.HcalPhase = cms.int32(1)
43  producer.HESThreshold1 = cms.double(0.1)
44  producer.HESThreshold = cms.double(0.2)
45  producer.HEDThreshold1 = cms.double(0.1)
46  producer.HEDThreshold = cms.double(0.2)
47 
48 
49  #remove collapser from sequence
50  process.hltHbhereco = process.hltHbhePhase1Reco.clone()
51  process.HLTDoLocalHcalSequence = cms.Sequence( process.hltHcalDigis + process.hltHbhereco + process.hltHfprereco + process.hltHfreco + process.hltHoreco )
52  process.HLTStoppedHSCPLocalHcalReco = cms.Sequence( process.hltHcalDigis + process.hltHbhereco )
53 
54 
55  return process
56 
57 
def customiseForUncollapsed(process)
def producers_by_type(process, types)
Definition: common.py:6
def customizeHLTforCMSSW.customizeHLTforCMSSW (   process,
  menuType = "GRun" 
)

Definition at line 217 of file customizeHLTforCMSSW.py.

References customiseFor24212(), and customiseForPR24339HybridFormatSiStripZS().

217 def customizeHLTforCMSSW(process, menuType="GRun"):
218 
219  # add call to action function in proper order: newest last!
220  # process = customiseFor12718(process)
221  process = customiseFor24212(process)
222 
224  return process
225 
def customizeHLTforCMSSW(process, menuType="GRun")
def customiseForPR24339HybridFormatSiStripZS(process)
For parameter changes in SiStripClusterizerFromRaw for PbPb 2018 data-taking.