Skip to content

Commit

Permalink
Merge pull request #36031 from missirol/devel_hltCustomPatatrackAlCaP…
Browse files Browse the repository at this point in the history
…aths_v2

improvement of a workaround in `customizeHLTforPatatrack`
  • Loading branch information
cmsbuild committed Nov 8, 2021
2 parents 628abcd + 2ae342b commit 8d204b0
Showing 1 changed file with 12 additions and 22 deletions.
34 changes: 12 additions & 22 deletions HLTrigger/Configuration/python/customizeHLTforPatatrack.py
Original file line number Diff line number Diff line change
Expand Up @@ -237,29 +237,19 @@ def customisePixelLocalReconstruction(process):


# workaround for AlCa paths
for AlCaPathName in ['AlCa_LumiPixelsCounts_Random_v1', 'AlCa_LumiPixelsCounts_ZeroBias_v1']:
if AlCaPathName in process.__dict__:
AlCaPath = getattr(process, AlCaPathName)
# replace hltSiPixelDigis+hltSiPixelClusters with HLTDoLocalPixelSequence
hasSiPixelDigis, hasSiPixelClusters = False, False
for (itemLabel, itemName) in AlCaPath.directDependencies():
if itemLabel != 'modules': continue
if itemName == 'hltSiPixelDigis': hasSiPixelDigis = True
elif itemName == 'hltSiPixelClusters': hasSiPixelClusters = True
if hasSiPixelDigis and hasSiPixelClusters:
AlCaPath.remove(process.hltSiPixelClusters)
AlCaPath.replace(process.hltSiPixelDigis, process.HLTDoLocalPixelSequence)

if 'AlCa_LumiPixelsCounts_Random_v1' in process.__dict__:
# redefine the path to use the HLTDoLocalPixelSequence
process.AlCa_LumiPixelsCounts_Random_v1 = cms.Path(
process.HLTBeginSequenceRandom +
process.hltScalersRawToDigi +
process.hltPreAlCaLumiPixelsCountsRandom +
process.hltPixelTrackerHVOn +
process.HLTDoLocalPixelSequence +
process.hltAlcaPixelClusterCounts +
process.HLTEndSequence )

if 'AlCa_LumiPixelsCounts_ZeroBias_v1' in process.__dict__:
# redefine the path to use the HLTDoLocalPixelSequence
process.AlCa_LumiPixelsCounts_ZeroBias_v1 = cms.Path(
process.HLTBeginSequence +
process.hltScalersRawToDigi +
process.hltL1sZeroBias +
process.hltPreAlCaLumiPixelsCountsZeroBias +
process.hltPixelTrackerHVOn +
process.HLTDoLocalPixelSequence +
process.hltAlcaPixelClusterCounts +
process.HLTEndSequence )

# done
return process
Expand Down

0 comments on commit 8d204b0

Please sign in to comment.