File indexing completed on 2024-04-06 12:30:41
0001 import FWCore.ParameterSet.Config as cms
0002 import sys
0003
0004 from SimMuon.CSCDigitizer.cscChamberMasker_cfi import cscChamberMasker as _cscChamberMasker
0005
0006 def appendCSCChamberMaskerAtUnpacking(process):
0007
0008 if hasattr(process,'muonCSCDigis') :
0009
0010 sys.stderr.write("[appendCSCChamberMasker] : Found muonCSCDigis, applying filter\n")
0011
0012 process.preCSCDigis = process.muonCSCDigis.clone()
0013 process.muonCSCDigis = _cscChamberMasker.clone()
0014
0015 process.muonCSCDigis.stripDigiTag = cms.InputTag("preCSCDigis", "MuonCSCStripDigi")
0016 process.muonCSCDigis.wireDigiTag = cms.InputTag("preCSCDigis", "MuonCSCWireDigi")
0017 process.muonCSCDigis.comparatorDigiTag = cms.InputTag("preCSCDigis", "MuonCSCComparatorDigi")
0018 process.muonCSCDigis.rpcDigiTag = cms.InputTag("preCSCDigis", "MuonCSCRPCDigi")
0019 process.muonCSCDigis.alctDigiTag = cms.InputTag("preCSCDigis", "MuonCSCALCTDigi")
0020 process.muonCSCDigis.clctDigiTag = cms.InputTag("preCSCDigis", "MuonCSCCLCTDigi")
0021
0022 process.RawToDigiTask.add(process.preCSCDigis)
0023
0024 if hasattr(process,"RandomNumberGeneratorService") :
0025 process.RandomNumberGeneratorService.muonCSCDigis = cms.PSet(
0026 initialSeed = cms.untracked.uint32(789342)
0027 )
0028 else :
0029 process.RandomNumberGeneratorService = cms.Service(
0030 "RandomNumberGeneratorService",
0031 muonCSCDigis = cms.PSet(initialSeed = cms.untracked.uint32(789342))
0032 )
0033
0034 return process
0035
0036 def appendCSCChamberMaskerAtHLT(process):
0037
0038 if hasattr(process,'hltMuonCSCDigis') :
0039
0040 sys.stderr.write("[appendCSCChamberMasker] : Found hltMuonCSCDigis, applying filter\n")
0041
0042 process.preHltCSCDigis = process.hltMuonCSCDigis.clone()
0043 process.hltMuonCSCDigis = _cscChamberMasker.clone()
0044
0045 process.hltMuonCSCDigis.stripDigiTag = cms.InputTag("preHltCSCDigis", "MuonCSCStripDigi")
0046 process.hltMuonCSCDigis.wireDigiTag = cms.InputTag("preHltCSCDigis", "MuonCSCWireDigi")
0047 process.hltMuonCSCDigis.comparatorDigiTag = cms.InputTag("preHltCSCDigis", "MuonCSCComparatorDigi")
0048 process.hltMuonCSCDigis.rpcDigiTag = cms.InputTag("preHltCSCDigis", "MuonCSCRPCDigi")
0049 process.hltMuonCSCDigis.alctDigiTag = cms.InputTag("preHltCSCDigis", "MuonCSCALCTDigi")
0050 process.hltMuonCSCDigis.clctDigiTag = cms.InputTag("preHltCSCDigis", "MuonCSCCLCTDigi")
0051
0052
0053 process.filteredHltCSCDigiSequence = cms.Sequence(process.preHltCSCDigis + process.hltMuonCSCDigis)
0054 process.HLTMuonLocalRecoSequence.replace(process.hltMuonCSCDigis, process.filteredHltCSCDigiSequence)
0055
0056 if hasattr(process,"RandomNumberGeneratorService") :
0057 process.RandomNumberGeneratorService.hltMuonCSCDigis = cms.PSet(
0058 initialSeed = cms.untracked.uint32(789342)
0059 )
0060 else :
0061 process.RandomNumberGeneratorService = cms.Service(
0062 "RandomNumberGeneratorService",
0063 hltMuonCSCDigis = cms.PSet(initialSeed = cms.untracked.uint32(789342))
0064 )
0065
0066 return process