Beispiel #1
0
def L1TReEmulFromRAWsimTP(process):
    L1TReEmulFromRAW(process)
    if stage2L1Trigger.isChosen():
        # TwinMux
        process.simTwinMuxDigis.RPC_Source = cms.InputTag('muonRPCDigis')
        process.simTwinMuxDigis.DTDigi_Source = cms.InputTag(
            'simDtTriggerPrimitiveDigis')
        process.simTwinMuxDigis.DTThetaDigi_Source = cms.InputTag(
            'simDtTriggerPrimitiveDigis')
        # BMTF
        process.simBmtfDigis.DTDigi_Source = cms.InputTag('simTwinMuxDigis')
        process.simBmtfDigis.DTDigi_Theta_Source = cms.InputTag(
            'simDtTriggerPrimitiveDigis')
        # OMTF
        process.simOmtfDigis.srcRPC = cms.InputTag('muonRPCDigis')
        process.simOmtfDigis.srcCSC = cms.InputTag(
            'simCscTriggerPrimitiveDigis')
        process.simOmtfDigis.srcDTPh = cms.InputTag(
            'simDtTriggerPrimitiveDigis')
        process.simOmtfDigis.srcDTTh = cms.InputTag(
            'simDtTriggerPrimitiveDigis')
        # EMTF
        process.simEmtfDigis.CSCInput = cms.InputTag(
            'simCscTriggerPrimitiveDigis')
        process.simEmtfDigis.RPCInput = cms.InputTag('muonRPCDigis')
        # Layer1
        process.simCaloStage2Layer1Digis.ecalToken = cms.InputTag(
            "simEcalTriggerPrimitiveDigis")
        process.simCaloStage2Layer1Digis.hcalToken = cms.InputTag(
            'simHcalTriggerPrimitiveDigis')
    return process
Beispiel #2
0
def L1TReEmulMCFromRAW(process):
    L1TReEmulFromRAW(process)
    if stage2L1Trigger.isChosen():
        process.simEmtfDigis.CSCInput = cms.InputTag(
            'simCscTriggerPrimitiveDigis', 'MPCSORTED')
        process.simOmtfDigis.srcCSC = cms.InputTag(
            'simCscTriggerPrimitiveDigis', 'MPCSORTED')
    return process
Beispiel #3
0
def L1TReEmulMCFromRAWSimCalTP(process):
    L1TReEmulMCFromRAW(process)
    if stage2L1Trigger.isChosen():
        process.simCaloStage2Layer1Digis.ecalToken = cms.InputTag(
            "simEcalTriggerPrimitiveDigis")
        process.simCaloStage2Layer1Digis.hcalToken = cms.InputTag(
            'simHcalTriggerPrimitiveDigis')
    return process
Beispiel #4
0
def L1TReEmulFromRAW2015(process):
    process.load('L1Trigger.Configuration.SimL1Emulator_cff')
    process.load('L1Trigger.Configuration.CaloTriggerPrimitives_cff')
    process.simEcalTriggerPrimitiveDigis.Label = 'ecalDigis'
    process.simHcalTriggerPrimitiveDigis.inputLabel = cms.VInputTag(
        cms.InputTag('hcalDigis'), cms.InputTag('hcalDigis'))
    process.L1TReEmul = cms.Sequence(process.simEcalTriggerPrimitiveDigis *
                                     process.simHcalTriggerPrimitiveDigis *
                                     process.SimL1Emulator)
    process.simDtTriggerPrimitiveDigis.digiTag = 'muonDTDigis'
    process.simCscTriggerPrimitiveDigis.CSCComparatorDigiProducer = cms.InputTag(
        'muonCSCDigis', 'MuonCSCComparatorDigi')
    process.simCscTriggerPrimitiveDigis.CSCWireDigiProducer = cms.InputTag(
        'muonCSCDigis', 'MuonCSCWireDigi')

    if stage2L1Trigger.isChosen():
        process.simTwinMuxDigis.RPC_Source = cms.InputTag('muonRPCDigis')
        # When available, this will switch to TwinMux input Digis:
        process.simTwinMuxDigis.DTDigi_Source = cms.InputTag("dttfDigis")
        process.simTwinMuxDigis.DTThetaDigi_Source = cms.InputTag("dttfDigis")
        process.simOmtfDigis.srcRPC = cms.InputTag('muonRPCDigis')
        process.simBmtfDigis.DTDigi_Source = cms.InputTag("simTwinMuxDigis")
        process.simBmtfDigis.DTDigi_Theta_Source = cms.InputTag("dttfDigis")
        process.simEmtfDigis.CSCInput = cms.InputTag("csctfDigis")
        process.simEmtfDigis.RPCInput = cms.InputTag('muonRPCDigis')
        process.simOmtfDigis.srcCSC = cms.InputTag("csctfDigis")
        process.simCaloStage2Layer1Digis.ecalToken = cms.InputTag(
            "ecalDigis:EcalTriggerPrimitives")
        process.L1TReEmulPath = cms.Path(process.L1TReEmul)
        process.schedule.append(process.L1TReEmulPath)
        print "L1TReEmul sequence:  "
        print process.L1TReEmul
        print process.schedule
        # quiet warning abouts missing Stage-2 payloads, since they won't reliably exist in 2015 data.
        if hasattr(process, "caloStage2Digis"):
            process.caloStage2Digis.MinFeds = cms.uint32(0)
        if hasattr(process, "gmtStage2Digis"):
            process.gmtStage2Digis.MinFeds = cms.uint32(0)
        if hasattr(process, "gtStage2Digis"):
            process.gtStage2Digis.MinFeds = cms.uint32(0)
        return process
    else:
        process.simRctDigis.ecalDigis = cms.VInputTag(
            'simEcalTriggerPrimitiveDigis')
        process.simRctDigis.hcalDigis = cms.VInputTag(
            'simHcalTriggerPrimitiveDigis')
        process.simRpcTriggerDigis.label = 'muonRPCDigis'
        process.simRpcTechTrigDigis.RPCDigiLabel = 'muonRPCDigis'
        process.L1TReEmulPath = cms.Path(process.L1TReEmul)
        process.schedule.append(process.L1TReEmulPath)
        print "L1TReEmul sequence:  "
        print process.L1TReEmul
        print process.schedule
        return process
Beispiel #5
0
def L1TReEmulMCFrom90xRAWSimHcalTP(process):
    L1TReEmulMCFromRAW(process)
    if stage2L1Trigger.isChosen():
        process.simHcalTriggerPrimitiveDigis.inputLabel = cms.VInputTag(
            cms.InputTag('simHcalUnsuppressedDigis'),
            cms.InputTag('simHcalUnsuppressedDigis'))
        process.simHcalTriggerPrimitiveDigis.inputUpgradeLabel = cms.VInputTag(
            cms.InputTag('simHcalUnsuppressedDigis:HBHEQIE11DigiCollection'),
            cms.InputTag('simHcalUnsuppressedDigis:HFQIE10DigiCollection'))
        process.simCaloStage2Layer1Digis.hcalToken = cms.InputTag(
            'simHcalTriggerPrimitiveDigis')
    return process
Beispiel #6
0
def L1TReEmulFromRAW(process):
    process.load('L1Trigger.Configuration.SimL1Emulator_cff')
    process.load('L1Trigger.Configuration.CaloTriggerPrimitives_cff')
    process.simEcalTriggerPrimitiveDigis.Label = 'ecalDigis'
    process.simHcalTriggerPrimitiveDigis.inputLabel = cms.VInputTag(
        cms.InputTag('hcalDigis'), cms.InputTag('hcalDigis'))
    process.simCscTriggerPrimitiveDigis.CSCComparatorDigiProducer = cms.InputTag(
        'muonCSCDigis', 'MuonCSCComparatorDigi')
    process.simCscTriggerPrimitiveDigis.CSCWireDigiProducer = cms.InputTag(
        'muonCSCDigis', 'MuonCSCWireDigi')
    process.L1TReEmul = cms.Sequence(process.simEcalTriggerPrimitiveDigis *
                                     process.simHcalTriggerPrimitiveDigis *
                                     process.SimL1Emulator)
    if stage2L1Trigger.isChosen():
        #cutlist=['simDtTriggerPrimitiveDigis','simCscTriggerPrimitiveDigis']
        #for b in cutlist:
        #    process.SimL1Emulator.remove(getattr(process,b))
        # TwinMux
        process.simTwinMuxDigis.RPC_Source = cms.InputTag('muonRPCDigis')
        process.simTwinMuxDigis.DTDigi_Source = cms.InputTag('bmtfDigis')
        process.simTwinMuxDigis.DTThetaDigi_Source = cms.InputTag('bmtfDigis')
        # BMTF
        process.simBmtfDigis.DTDigi_Source = cms.InputTag('bmtfDigis')
        process.simBmtfDigis.DTDigi_Theta_Source = cms.InputTag('bmtfDigis')
        # OMTF
        process.simOmtfDigis.srcRPC = cms.InputTag('muonRPCDigis')
        process.simOmtfDigis.srcCSC = cms.InputTag('csctfDigis')
        process.simOmtfDigis.srcDTPh = cms.InputTag('bmtfDigis')
        process.simOmtfDigis.srcDTTh = cms.InputTag('bmtfDigis')
        # EMTF
        process.simEmtfDigis.CSCInput = cms.InputTag('emtfStage2Digis')
        process.simEmtfDigis.RPCInput = cms.InputTag('muonRPCDigis')
        # Calo Layer1
        process.simCaloStage2Layer1Digis.ecalToken = cms.InputTag(
            'ecalDigis:EcalTriggerPrimitives')
        process.simCaloStage2Layer1Digis.hcalToken = cms.InputTag('hcalDigis:')
        process.L1TReEmulPath = cms.Path(process.L1TReEmul)
        process.schedule.append(process.L1TReEmulPath)
        print "L1TReEmulPath sequence:  "
        print process.L1TReEmulPath
        print process.schedule
        return process
    else:
        process.simRctDigis.ecalDigis = cms.VInputTag(
            cms.InputTag('ecalDigis:EcalTriggerPrimitives'))
        process.simRctDigis.hcalDigis = cms.VInputTag('hcalDigis:')
        process.simRpcTriggerDigis.label = 'muonRPCDigis'
        process.L1TReEmulPath = cms.Path(process.L1TReEmul)
        process.schedule.append(process.L1TReEmulPath)
        print "L1TReEmul sequence:  "
        print process.L1TReEmul
        print process.schedule
        return process
Beispiel #7
0
def L1TReEmulMCFrom90xRAWSimHcalTP(process):
    L1TReEmulMCFromRAW(process)
    if stage2L1Trigger.isChosen():
            process.simHcalTriggerPrimitiveDigis.inputLabel = cms.VInputTag(
                cms.InputTag('simHcalUnsuppressedDigis'),
                cms.InputTag('simHcalUnsuppressedDigis')
            )
            process.simHcalTriggerPrimitiveDigis.inputUpgradeLabel = cms.VInputTag(
                cms.InputTag('simHcalUnsuppressedDigis:HBHEQIE11DigiCollection'),
                cms.InputTag('simHcalUnsuppressedDigis:HFQIE10DigiCollection')
            )
            process.simCaloStage2Layer1Digis.hcalToken = cms.InputTag('simHcalTriggerPrimitiveDigis')
    return process
Beispiel #8
0
def L1TReEmulFromRAW2015(process):
    process.load('L1Trigger.Configuration.SimL1Emulator_cff')
    process.load('L1Trigger.Configuration.CaloTriggerPrimitives_cff')
    process.simEcalTriggerPrimitiveDigis.Label = 'ecalDigis'
    process.simHcalTriggerPrimitiveDigis.inputLabel = cms.VInputTag(
        cms.InputTag('hcalDigis'),
        cms.InputTag('hcalDigis')
    )
    process.L1TReEmul = cms.Sequence(process.simEcalTriggerPrimitiveDigis * process.simHcalTriggerPrimitiveDigis * process.SimL1Emulator)
    process.simDtTriggerPrimitiveDigis.digiTag = 'muonDTDigis'  
    process.simCscTriggerPrimitiveDigis.CSCComparatorDigiProducer = cms.InputTag( 'muonCSCDigis', 'MuonCSCComparatorDigi')
    process.simCscTriggerPrimitiveDigis.CSCWireDigiProducer       = cms.InputTag( 'muonCSCDigis', 'MuonCSCWireDigi' )  

    if stage2L1Trigger.isChosen():
        process.simTwinMuxDigis.RPC_Source         = cms.InputTag('muonRPCDigis')
        # When available, this will switch to TwinMux input Digis:
        process.simTwinMuxDigis.DTDigi_Source      = cms.InputTag("dttfDigis")
        process.simTwinMuxDigis.DTThetaDigi_Source = cms.InputTag("dttfDigis")
        process.simOmtfDigis.srcRPC                = cms.InputTag('muonRPCDigis')
        process.simBmtfDigis.DTDigi_Source         = cms.InputTag("simTwinMuxDigis")
        process.simBmtfDigis.DTDigi_Theta_Source   = cms.InputTag("dttfDigis")
        process.simEmtfDigis.CSCInput              = cms.InputTag("csctfDigis")
        process.simEmtfDigis.RPCInput              = cms.InputTag('muonRPCDigis')
        process.simOmtfDigis.srcCSC                = cms.InputTag("csctfDigis")
        process.simCaloStage2Layer1Digis.ecalToken = cms.InputTag("ecalDigis:EcalTriggerPrimitives")
        process.L1TReEmulPath = cms.Path(process.L1TReEmul)    
        process.schedule.append(process.L1TReEmulPath)
        print "L1TReEmul sequence:  "
        print process.L1TReEmul
        print process.schedule
        # quiet warning abouts missing Stage-2 payloads, since they won't reliably exist in 2015 data.
        if hasattr(process, "caloStage2Digis"):
            process.caloStage2Digis.MinFeds = cms.uint32(0)
        if hasattr(process, "gmtStage2Digis"):
            process.gmtStage2Digis.MinFeds = cms.uint32(0)
        if hasattr(process, "gtStage2Digis"):
            process.gtStage2Digis.MinFeds = cms.uint32(0)            
        return process
    else:
        process.simRctDigis.ecalDigis = cms.VInputTag('simEcalTriggerPrimitiveDigis')
        process.simRctDigis.hcalDigis = cms.VInputTag('simHcalTriggerPrimitiveDigis')
        process.simRpcTriggerDigis.label = 'muonRPCDigis'
        process.simRpcTechTrigDigis.RPCDigiLabel  = 'muonRPCDigis'
        process.L1TReEmulPath = cms.Path(process.L1TReEmul)    
        process.schedule.append(process.L1TReEmulPath)
        print "L1TReEmul sequence:  "
        print process.L1TReEmul
        print process.schedule
        return process
Beispiel #9
0
def L1TReEmulFromRAW(process):
    process.load('L1Trigger.Configuration.SimL1Emulator_cff')
    process.load('L1Trigger.Configuration.CaloTriggerPrimitives_cff')
    process.simEcalTriggerPrimitiveDigis.Label = 'ecalDigis'
    process.simHcalTriggerPrimitiveDigis.inputLabel = cms.VInputTag(
        cms.InputTag('hcalDigis'),
        cms.InputTag('hcalDigis')
    )
    process.simCscTriggerPrimitiveDigis.CSCComparatorDigiProducer = cms.InputTag( 'muonCSCDigis', 'MuonCSCComparatorDigi')
    process.simCscTriggerPrimitiveDigis.CSCWireDigiProducer       = cms.InputTag( 'muonCSCDigis', 'MuonCSCWireDigi' )  
    process.L1TReEmul = cms.Sequence(process.simEcalTriggerPrimitiveDigis * process.simHcalTriggerPrimitiveDigis * process.SimL1Emulator)
    if stage2L1Trigger.isChosen():
        #cutlist=['simDtTriggerPrimitiveDigis','simCscTriggerPrimitiveDigis']
        #for b in cutlist:
        #    process.SimL1Emulator.remove(getattr(process,b))
        # TwinMux
        process.simTwinMuxDigis.RPC_Source         = cms.InputTag('muonRPCDigis')
        process.simTwinMuxDigis.DTDigi_Source      = cms.InputTag('bmtfDigis')
        process.simTwinMuxDigis.DTThetaDigi_Source = cms.InputTag('bmtfDigis')
        # BMTF
        process.simBmtfDigis.DTDigi_Source         = cms.InputTag('bmtfDigis')
        process.simBmtfDigis.DTDigi_Theta_Source   = cms.InputTag('bmtfDigis')
        # OMTF
        process.simOmtfDigis.srcRPC                = cms.InputTag('muonRPCDigis')
        process.simOmtfDigis.srcCSC                = cms.InputTag('csctfDigis')
        process.simOmtfDigis.srcDTPh               = cms.InputTag('bmtfDigis')
        process.simOmtfDigis.srcDTTh               = cms.InputTag('bmtfDigis')
        # EMTF
        process.simEmtfDigis.CSCInput              = cms.InputTag('emtfStage2Digis')
        process.simEmtfDigis.RPCInput              = cms.InputTag('muonRPCDigis')
        # Calo Layer1
        process.simCaloStage2Layer1Digis.ecalToken = cms.InputTag('ecalDigis:EcalTriggerPrimitives')
        process.simCaloStage2Layer1Digis.hcalToken = cms.InputTag('hcalDigis:')
        process.L1TReEmulPath = cms.Path(process.L1TReEmul)    
        process.schedule.append(process.L1TReEmulPath)
        print "L1TReEmulPath sequence:  "
        print process.L1TReEmulPath
        print process.schedule
        return process
    else:
        process.simRctDigis.ecalDigis = cms.VInputTag( cms.InputTag( 'ecalDigis:EcalTriggerPrimitives' ) )
        process.simRctDigis.hcalDigis = cms.VInputTag('hcalDigis:')
        process.simRpcTriggerDigis.label         = 'muonRPCDigis'
        process.L1TReEmulPath = cms.Path(process.L1TReEmul)    
        process.schedule.append(process.L1TReEmulPath)
        print "L1TReEmul sequence:  "
        print process.L1TReEmul
        print process.schedule
        return process
def modifySimL1EmulatorForReEmulation(SimL1Emulator_object, subsys=[]):

    if not stage2L1Trigger.isChosen():
        #        if 'ECAL' not in subsys:
        #            digiSeq_object.remove(simEcalTriggerPrimitiveDigis)
        #        if 'HCAL' not in subsys:
        #            digiSeq_object.remove(simHcalTriggerPrimitiveDigis)
        if 'RCT' not in subsys:
            SimL1Emulator_object.remove(simRctDigis)
        if 'GCT' not in subsys:
            SimL1Emulator_object.remove(simGctDigis)
        if 'CSC' not in subsys:
            SimL1Emulator_object.remove(simCscTriggerPrimitiveDigis)
        if 'DT' not in subsys:
            SimL1Emulator_object.remove(simDtTriggerPrimitiveDigis)
        if 'CSCTF1' not in subsys:
            SimL1Emulator_object.remove(simCsctfTrackDigis)
        if 'CSCTF2' not in subsys:
            SimL1Emulator_object.remove(simCsctfDigis)
        if 'DTTF' not in subsys:
            SimL1Emulator_object.remove(simDttfDigis)
        if 'RPCTF' not in subsys:
            SimL1Emulator_object.remove(simRpcTriggerDigis)
        if 'GMT' not in subsys:
            SimL1Emulator_object.remove(simGmtDigis)
        if 'GT' not in subsys:
            SimL1Emulator_object.remove(simGtDigis)

    if stage1L1Trigger.isChosen():
        if 'S1CALOL2' not in subsys:
            SimL1Emulator_object.remove(simRctUpgradeFormatDigis)
            SimL1Emulator_object.remove(simCaloStage1Digis)
            SimL1Emulator_object.remove(simCaloStage1FinalDigis)
            SimL1Emulator_object.remove(simCaloStage1LegacyFormatDigis)

    if stage1L1Trigger.isChosen():
        if 'CALOL1' not in subsys:
            SimL1Emulator_object.remove(simCaloStage2Layer1Digis)
        if 'CALOL2' not in subsys:
            SimL1Emulator_object.remove(simCaloStage2Digis)
def modifySimL1EmulatorForReEmulation(SimL1Emulator_object, subsys=[]):

    if not stage2L1Trigger.isChosen():
#        if 'ECAL' not in subsys:
#            digiSeq_object.remove(simEcalTriggerPrimitiveDigis)
#        if 'HCAL' not in subsys:
#            digiSeq_object.remove(simHcalTriggerPrimitiveDigis)
        if 'RCT' not in subsys:
            SimL1Emulator_object.remove(simRctDigis)
        if 'GCT' not in subsys:
            SimL1Emulator_object.remove(simGctDigis)
        if 'CSC' not in subsys:
            SimL1Emulator_object.remove(simCscTriggerPrimitiveDigis)
        if 'DT' not in subsys:
            SimL1Emulator_object.remove(simDtTriggerPrimitiveDigis)
        if 'CSCTF1' not in subsys:
            SimL1Emulator_object.remove(simCsctfTrackDigis)
        if 'CSCTF2' not in subsys:
            SimL1Emulator_object.remove(simCsctfDigis)
        if 'DTTF' not in subsys:
            SimL1Emulator_object.remove(simDttfDigis)
        if 'RPCTF' not in subsys:
            SimL1Emulator_object.remove(simRpcTriggerDigis)
        if 'GMT' not in subsys:
            SimL1Emulator_object.remove(simGmtDigis)
        if 'GT' not in subsys:
            SimL1Emulator_object.remove(simGtDigis)

    if stage1L1Trigger.isChosen():
        if 'S1CALOL2' not in subsys:
            SimL1Emulator_object.remove(simRctUpgradeFormatDigis)
            SimL1Emulator_object.remove(simCaloStage1Digis)
            SimL1Emulator_object.remove(simCaloStage1FinalDigis)
            SimL1Emulator_object.remove(simCaloStage1LegacyFormatDigis)

    if stage1L1Trigger.isChosen():
        if 'CALOL1' not in subsys:
            SimL1Emulator_object.remove(simCaloStage2Layer1Digis)
        if 'CALOL2' not in subsys:
            SimL1Emulator_object.remove(simCaloStage2Digis)
Beispiel #12
0
def L1TReEmulFromRAWsimTP(process):
    L1TReEmulFromRAW(process)
    if stage2L1Trigger.isChosen():
        # TwinMux
        process.simTwinMuxDigis.RPC_Source         = cms.InputTag('muonRPCDigis')
        process.simTwinMuxDigis.DTDigi_Source      = cms.InputTag('simDtTriggerPrimitiveDigis')
        process.simTwinMuxDigis.DTThetaDigi_Source = cms.InputTag('simDtTriggerPrimitiveDigis')
        # BMTF
        process.simBmtfDigis.DTDigi_Source         = cms.InputTag('simTwinMuxDigis')
        process.simBmtfDigis.DTDigi_Theta_Source   = cms.InputTag('simDtTriggerPrimitiveDigis')
        # OMTF
        process.simOmtfDigis.srcRPC                = cms.InputTag('muonRPCDigis')
        process.simOmtfDigis.srcCSC                = cms.InputTag('simCscTriggerPrimitiveDigis')
        process.simOmtfDigis.srcDTPh               = cms.InputTag('simDtTriggerPrimitiveDigis')
        process.simOmtfDigis.srcDTTh               = cms.InputTag('simDtTriggerPrimitiveDigis')
        # EMTF
        process.simEmtfDigis.CSCInput              = cms.InputTag('simCscTriggerPrimitiveDigis')
        process.simEmtfDigis.RPCInput              = cms.InputTag('muonRPCDigis')
        # Layer1
        process.simCaloStage2Layer1Digis.ecalToken = cms.InputTag("simEcalTriggerPrimitiveDigis")
        process.simCaloStage2Layer1Digis.hcalToken = cms.InputTag('simHcalTriggerPrimitiveDigis')
    return process
Beispiel #13
0
def unpack_stage2():
    global L1TRawToDigi_Stage2
    global bmtfDigis, emtfStage2Digis, caloStage2Digis, gmtStage2Digis, gtStage2Digis,L1TRawToDigi_Stage2    
    from EventFilter.L1TRawToDigi.bmtfDigis_cfi import bmtfDigis 
    from EventFilter.L1TRawToDigi.emtfStage2Digis_cfi import emtfStage2Digis
    from EventFilter.L1TRawToDigi.caloStage2Digis_cfi import caloStage2Digis
    from EventFilter.L1TRawToDigi.gmtStage2Digis_cfi import gmtStage2Digis
    from EventFilter.L1TRawToDigi.gtStage2Digis_cfi import gtStage2Digis
    L1TRawToDigi_Stage2 = cms.Sequence(bmtfDigis + emtfStage2Digis + caloStage2Digis + gmtStage2Digis + gtStage2Digis)
    
#
# Legacy Trigger:
#
from Configuration.Eras.Modifier_stage1L1Trigger_cff import stage1L1Trigger
from Configuration.Eras.Modifier_stage2L1Trigger_cff import stage2L1Trigger
if not (stage1L1Trigger.isChosen() or stage2L1Trigger.isChosen()):
    print "L1TRawToDigi Sequence configured for Run1 (Legacy) trigger. "
    unpack_legacy()
    L1TRawToDigi = cms.Sequence(L1TRawToDigi_Legacy);

#
# Stage-1 Trigger
#
if stage1L1Trigger.isChosen() and not stage2L1Trigger.isChosen():
    print "L1TRawToDigi Sequence configured for Stage-1 (2015) trigger. "    
    unpack_stage1()
    L1TRawToDigi = cms.Sequence(L1TRawToDigi_Stage1)

#
# Stage-2 Trigger:  fow now, unpack Stage 1 and Stage 2 (in case both available)
#
Beispiel #14
0
#
# The intention is that this file should shrink with time as conditions are added to GT.
#

import FWCore.ParameterSet.Config as cms

#
# Legacy Trigger:  No Hacks Needed
#
from Configuration.Eras.Modifier_stage1L1Trigger_cff import stage1L1Trigger
from Configuration.Eras.Modifier_stage2L1Trigger_cff import stage2L1Trigger
#if not (stage1L1Trigger.isChosen() or stage2L1Trigger.isChosen()):
#    print "L1TMuon conditions configured for Run1 (Legacy) trigger. "
# 

#
# Stage-1 Trigger:  No Hacks Needed
#
#if stage1L1Trigger.isChosen() and not stage2L1Trigger.isChosen():
#    print "L1TMuon Conditions configured for Stage-1 (2015) trigger. "    

#
# Stage-2 Trigger
#
if stage2L1Trigger.isChosen():
    print "L1TMuon Conditions configured for Stage-2 (2016) trigger. "
    from L1Trigger.L1TMuonBarrel.fakeBmtfParams_cff import *
    from L1Trigger.L1TMuonOverlap.fakeOmtfParams_cff import *
    from L1Trigger.L1TMuonEndCap.fakeEmtfParams_cff import *
    from L1Trigger.L1TMuon.fakeGmtParams_cff import *
def getSubsystemsToEmulate(subsys):

    if not stage2L1Trigger.isChosen():
        if 'ECAL' in subsys:
            subsys.append('RCT')
        if 'HCAL' in subsys:
            subsys.append('RCT')
        if 'RCT' in subsys:
            subsys.append('GCT')
        if 'GCT' in subsys:
            subsys.append('GT')
        if 'CSC' in subsys:
            subsys.append('CSCTF1')
        if 'DT' in subsys:
            subsys.append('DTTF')
        if 'DTTF' in subsys:
            subsys.append('CSCTF2')
            subsys.append('GMT')
        if 'CSCTF' in subsys:
            subsys.append('CSCTF1')
            subsys.append('CSCTF2')
            subsys.append('GMT')
        if 'CSCTF2' in subsys:
            subsys.append('GMT')
        if 'RPCTF' in subsys:
            subsys.append('GMT')
        if 'GMT' in subsys:
            subsys.append('GT')

    if stage1L1Trigger.isChosen():
        if 'ECAL' in subsys:
            subsys.append('RCT')
        if 'HCAL' in subsys:
            subsys.append('RCT')
        if 'RCT' in subsys:
            subsys.append('S1CALOL2')
        if 'S1CALOL2' in subsys:
            subsys.append('GT')
        if 'CSC' in subsys:
            subsys.append('CSCTF1')
        if 'DT' in subsys:
            subsys.append('DTTF')
        if 'DTTF' in subsys:
            subsys.append('CSCTF2')
            subsys.append('GMT')
        if 'CSCTF' in subsys:
            subsys.append('CSCTF1')
            subsys.append('CSCTF2')
            subsys.append('GMT')
        if 'CSCTF2' in subsys:
            subsys.append('GMT')
        if 'RPCTF' in subsys:
            subsys.append('GMT')
        if 'GMT' in subsys:
            subsys.append('GT')

    if stage2L1Trigger.isChosen():
        if 'ECAL' in subsys:
            subsys.append('CALOL1')
        if 'HCAL' in subsys:
            subsys.append('CALOL1')
        if 'CALOL1' in subsys:
            subsys.append('CALOL2')
        if 'CALOL2' in subsys:
            subsys.append('GT')
        if 'CSC' in subsys:
            subsys.append('EMTF')
            subsys.append('OMTF')
        if 'DT' in subsys:
            subsys.append('BMTF')
            subsys.append('OMTF')
        if 'RPC' in subsys:
            subsys.append('BMTF')
            subsys.append('EMTF')
            subsys.append('OMTF')
        if 'BMTF' in subsys:
            subsys.append('GMT')
        if 'EMTF' in subsys:
            subsys.append('GMT')
        if 'OMTF' in subsys:
            subsys.append('GMT')
        if 'GMT' in subsys:
            subsys.append('GT')

    out = []
    for sys in subsys:
        if sys not in out:
            out.append(sys)

    return out
Beispiel #16
0
# The intention is that this file should shrink with time as conditions are added to GT.
#

import FWCore.ParameterSet.Config as cms
import sys
#
# Legacy Trigger:  No Hacks Needed
#
from Configuration.Eras.Modifier_stage1L1Trigger_cff import stage1L1Trigger
from Configuration.Eras.Modifier_stage2L1Trigger_cff import stage2L1Trigger
#if not (stage1L1Trigger.isChosen() or stage2L1Trigger.isChosen()):
#    sys.stderr.write("L1TMuon conditions configured for Run1 (Legacy) trigger. \n")
#

#
# Stage-1 Trigger:  No Hacks Needed
#
#if stage1L1Trigger.isChosen() and not stage2L1Trigger.isChosen():
#    sys.stderr.write("L1TMuon Conditions configured for Stage-1 (2015) trigger. \n")

#
# Stage-2 Trigger
#
if stage2L1Trigger.isChosen():
    sys.stderr.write(
        "L1TMuon Conditions configured for Stage-2 (2016) trigger. \n")
    from L1Trigger.L1TMuonBarrel.fakeBmtfParams_cff import *
    from L1Trigger.L1TMuonOverlap.fakeOmtfParams_cff import *
    from L1Trigger.L1TMuonEndCap.fakeEmtfParams_cff import *
    from L1Trigger.L1TMuon.fakeGmtParams_cff import *
Beispiel #17
0
def L1TReEmulFromRAW2015simCaloTP(process):
    L1TReEmulFromRAW2015(process)
    if stage2L1Trigger.isChosen():
        process.simCaloStage2Layer1Digis.ecalToken = cms.InputTag(
            "simEcalTriggerPrimitiveDigis")
    return process
Beispiel #18
0
from __future__ import print_function
import FWCore.ParameterSet.Config as cms

## L1REPACK FULL:  Re-Emulate all of L1 and repack into RAW


from Configuration.Eras.Modifier_stage2L1Trigger_cff import stage2L1Trigger
if not (stage2L1Trigger.isChosen()):
    print("L1T WARN:  L1REPACK:Full2015Data only supports Stage 2 eras for now.")
    print("L1T WARN:  Use a legacy version of L1REPACK for now.")
else:
    print("L1T INFO:  L1REPACK:Full2015Data will unpack all L1T inputs, re-emulated (Stage-2), and pack uGT, uGMT, and Calo Stage-2 output.")

    # First, Unpack all inputs to L1:
    import EventFilter.DTTFRawToDigi.dttfunpacker_cfi
    unpackDttf = EventFilter.DTTFRawToDigi.dttfunpacker_cfi.dttfunpacker.clone(
        DTTF_FED_Source = cms.InputTag( 'rawDataCollector', processName=cms.InputTag.skipCurrentProcess()))    

    import EventFilter.CSCTFRawToDigi.csctfunpacker_cfi
    unpackCsctf = EventFilter.CSCTFRawToDigi.csctfunpacker_cfi.csctfunpacker.clone(
        producer = cms.InputTag( 'rawDataCollector', processName=cms.InputTag.skipCurrentProcess()))    

    import EventFilter.CSCRawToDigi.cscUnpacker_cfi
    unpackCSC = EventFilter.CSCRawToDigi.cscUnpacker_cfi.muonCSCDigis.clone(
        InputObjects = cms.InputTag( 'rawDataCollector', processName=cms.InputTag.skipCurrentProcess()))

    import EventFilter.DTRawToDigi.dtunpacker_cfi
    unpackDT = EventFilter.DTRawToDigi.dtunpacker_cfi.muonDTDigis.clone(
        inputLabel = cms.InputTag( 'rawDataCollector', processName=cms.InputTag.skipCurrentProcess()))

    import EventFilter.RPCRawToDigi.rpcUnpacker_cfi
Beispiel #19
0
simDtTriggerPrimitiveDigis.digiTag = 'simMuonDTDigis'
#simDtTriggerPrimitiveDigis.debug = cms.untracked.bool(True)

# - CSC TP emulator
from L1Trigger.CSCCommonTrigger.CSCCommonTrigger_cfi import *
import L1Trigger.CSCTriggerPrimitives.cscTriggerPrimitiveDigis_cfi
simCscTriggerPrimitiveDigis = L1Trigger.CSCTriggerPrimitives.cscTriggerPrimitiveDigis_cfi.cscTriggerPrimitiveDigis.clone()
simCscTriggerPrimitiveDigis.CSCComparatorDigiProducer = cms.InputTag( 'simMuonCSCDigis', 'MuonCSCComparatorDigi' )
simCscTriggerPrimitiveDigis.CSCWireDigiProducer       = cms.InputTag( 'simMuonCSCDigis', 'MuonCSCWireDigi' )

SimL1TMuonCommon = cms.Sequence(simDtTriggerPrimitiveDigis + simCscTriggerPrimitiveDigis)

#
# Legacy Trigger:
#
if not (stage2L1Trigger.isChosen() or phase2_common.isChosen()):
    print "L1TMuon Sequence configured for Legacy trigger (Run1 and Run 2015)."
#
# - CSC Track Finder emulator
#
    import L1Trigger.CSCTrackFinder.csctfTrackDigis_cfi
    simCsctfTrackDigis = L1Trigger.CSCTrackFinder.csctfTrackDigis_cfi.csctfTrackDigis.clone()
    simCsctfTrackDigis.SectorReceiverInput = cms.untracked.InputTag( 'simCscTriggerPrimitiveDigis', 'MPCSORTED' )
    simCsctfTrackDigis.DTproducer = 'simDtTriggerPrimitiveDigis'
    import L1Trigger.CSCTrackFinder.csctfDigis_cfi
    simCsctfDigis = L1Trigger.CSCTrackFinder.csctfDigis_cfi.csctfDigis.clone()
    simCsctfDigis.CSCTrackProducer = 'simCsctfTrackDigis'
#
# - DT Track Finder emulator
# 
    import L1Trigger.DTTrackFinder.dttfDigis_cfi
from Configuration.Eras.Modifier_pA_2016_cff import pA_2016


#
# Legacy Trigger:  No Hacks Needed
#
from Configuration.Eras.Modifier_stage1L1Trigger_cff import stage1L1Trigger
from Configuration.Eras.Modifier_stage2L1Trigger_cff import stage2L1Trigger
#if not (stage1L1Trigger.isChosen() or stage2L1Trigger.isChosen()):
#    sys.stderr.write("L1TCalorimeter conditions configured for Run1 (Legacy) trigger. \n")
# 

#
# Stage-1 Trigger
#
if stage1L1Trigger.isChosen() and not stage2L1Trigger.isChosen():
    # Switch between HI and PP calo configuration:
    if (run2_HI_specific.isChosen()):
        from L1Trigger.L1TCalorimeter.caloConfigStage1HI_cfi import *
    else:
        from L1Trigger.L1TCalorimeter.caloConfigStage1PP_cfi import *
    # Override Calo Scales:
    from L1Trigger.L1TCalorimeter.caloScalesStage1_cff import *
    # CaloParams is in the DB for Stage-1

#
# Stage-2 Trigger
#
if stage2L1Trigger.isChosen():
    if pA_2016.isChosen():
        from L1Trigger.L1TCalorimeter.caloStage2Params_2016_v3_3_1_HI_cfi import *    
Beispiel #21
0
import FWCore.ParameterSet.Config as cms

#
# Legacy Trigger:
#
from Configuration.Eras.Modifier_stage1L1Trigger_cff import stage1L1Trigger
from Configuration.Eras.Modifier_stage2L1Trigger_cff import stage2L1Trigger
if not (stage1L1Trigger.isChosen() or stage2L1Trigger.isChosen()):
    print "L1TCalorimeter Sequence configured for Run1 (Legacy) trigger. "
    # -  RCT (Regional Calorimeter Trigger) emulator
    import L1Trigger.RegionalCaloTrigger.rctDigis_cfi
    simRctDigis = L1Trigger.RegionalCaloTrigger.rctDigis_cfi.rctDigis.clone()
    simRctDigis.ecalDigis = cms.VInputTag(
        cms.InputTag('simEcalTriggerPrimitiveDigis'))
    simRctDigis.hcalDigis = cms.VInputTag(
        cms.InputTag('simHcalTriggerPrimitiveDigis'))
    # - GCT (Global Calorimeter Trigger) emulator
    import L1Trigger.GlobalCaloTrigger.gctDigis_cfi
    simGctDigis = L1Trigger.GlobalCaloTrigger.gctDigis_cfi.gctDigis.clone()
    simGctDigis.inputLabel = 'simRctDigis'
    SimL1TCalorimeter = cms.Sequence(simRctDigis + simGctDigis)

#
# Stage-1 Trigger
#
if stage1L1Trigger.isChosen() and not stage2L1Trigger.isChosen():
    print "L1TCalorimeter Sequence configured for Stage-1 (2015) trigger. "
    #
    # -  RCT (Regional Calorimeter Trigger) emulator
    #
    import L1Trigger.RegionalCaloTrigger.rctDigis_cfi
Beispiel #22
0
import FWCore.ParameterSet.Config as cms

#
# Legacy Trigger:
#
from Configuration.Eras.Modifier_stage1L1Trigger_cff import stage1L1Trigger
from Configuration.Eras.Modifier_stage2L1Trigger_cff import stage2L1Trigger
from Configuration.Eras.Modifier_phase2_common_cff import phase2_common
if not (stage1L1Trigger.isChosen() or stage2L1Trigger.isChosen() or phase2_common.isChosen()):
    print "L1TCalorimeter Sequence configured for Run1 (Legacy) trigger. "
# -  RCT (Regional Calorimeter Trigger) emulator
    import L1Trigger.RegionalCaloTrigger.rctDigis_cfi
    simRctDigis = L1Trigger.RegionalCaloTrigger.rctDigis_cfi.rctDigis.clone()
    simRctDigis.ecalDigis = cms.VInputTag( cms.InputTag( 'simEcalTriggerPrimitiveDigis' ) )
    simRctDigis.hcalDigis = cms.VInputTag( cms.InputTag( 'simHcalTriggerPrimitiveDigis' ) )
# - GCT (Global Calorimeter Trigger) emulator
    import L1Trigger.GlobalCaloTrigger.gctDigis_cfi
    simGctDigis = L1Trigger.GlobalCaloTrigger.gctDigis_cfi.gctDigis.clone()
    simGctDigis.inputLabel = 'simRctDigis'
    SimL1TCalorimeter = cms.Sequence(simRctDigis + simGctDigis)

#
# Stage-1 Trigger
#
if stage1L1Trigger.isChosen() and not stage2L1Trigger.isChosen():
    print "L1TCalorimeter Sequence configured for Stage-1 (2015) trigger. "    
#
# -  RCT (Regional Calorimeter Trigger) emulator
#
    import L1Trigger.RegionalCaloTrigger.rctDigis_cfi
    simRctDigis = L1Trigger.RegionalCaloTrigger.rctDigis_cfi.rctDigis.clone()
import FWCore.ParameterSet.Config as cms

from Configuration.StandardSequences.SimL1Emulator_cff import *

# Modifications for DataMixer input:
simDtTriggerPrimitiveDigis.digiTag = 'mixData'
simCscTriggerPrimitiveDigis.CSCComparatorDigiProducer = cms.InputTag("mixData","MuonCSCComparatorDigisDM")
simCscTriggerPrimitiveDigis.CSCWireDigiProducer = cms.InputTag("mixData","MuonCSCWireDigisDM")
#
#
simRpcTechTrigDigis.RPCDigiLabel = 'mixData'
#
simHcalTechTrigDigis.ttpDigiCollection = "DMHcalTTPDigis"
#

from Configuration.Eras.Modifier_stage2L1Trigger_cff import stage2L1Trigger
if not stage2L1Trigger.isChosen():
    simRpcTriggerDigis.label = 'mixData'
    simRctDigis.hcalDigis=cms.VInputTag(cms.InputTag("DMHcalTriggerPrimitiveDigis"))   
    simRctDigis.ecalDigis=cms.VInputTag(cms.InputTag("DMEcalTriggerPrimitiveDigis"))   
else:
    #seems likely that this code does not support 2015 MC...
    simTwinMuxDigis.RPC_Source = cms.InputTag('mixData')
    simOmtfDigis.srcRPC = cms.InputTag('mixData')
    simCaloStage2Layer1Digis.ecalToken = cms.InputTag("DMEcalTriggerPrimitiveDigis")
    simCaloStage2Layer1Digis.hcalToken = cms.InputTag("DMHcalTriggerPrimitiveDigis")
Beispiel #24
0
def L1TReEmulMCFromRAWSimEcalTP(process):
    L1TReEmulMCFromRAW(process)
    if stage2L1Trigger.isChosen():
            process.simCaloStage2Layer1Digis.ecalToken = cms.InputTag("simEcalTriggerPrimitiveDigis")
    return process
Beispiel #25
0
def L1TReEmulFromRAWsimHcalTP(process):
    L1TReEmulFromRAW(process)
    if stage2L1Trigger.isChosen():
            process.simCaloStage2Layer1Digis.hcalToken = cms.InputTag('simHcalTriggerPrimitiveDigis')
    return process
def getSubsystemsToEmulate(subsys):

    if not stage2L1Trigger.isChosen():
        if 'ECAL' in subsys:
            subsys.append('RCT')
        if 'HCAL' in subsys:
            subsys.append('RCT')
        if 'RCT' in subsys:
            subsys.append('GCT')
        if 'GCT' in subsys:
            subsys.append('GT')
        if 'CSC' in subsys:
            subsys.append('CSCTF1')
        if 'DT' in subsys:
            subsys.append('DTTF')
        if 'DTTF' in subsys:
            subsys.append('CSCTF2')
            subsys.append('GMT')
        if 'CSCTF' in subsys:
            subsys.append('CSCTF1')
            subsys.append('CSCTF2')
            subsys.append('GMT')
        if 'CSCTF2' in subsys:
            subsys.append('GMT')
        if 'RPCTF' in subsys:
            subsys.append('GMT')
        if 'GMT' in subsys:
            subsys.append('GT')

    if stage1L1Trigger.isChosen():
        if 'ECAL' in subsys:
            subsys.append('RCT')
        if 'HCAL' in subsys:
            subsys.append('RCT')
        if 'RCT' in subsys:
            subsys.append('S1CALOL2')
        if 'S1CALOL2' in subsys:
            subsys.append('GT')
        if 'CSC' in subsys:
            subsys.append('CSCTF1')
        if 'DT' in subsys:
            subsys.append('DTTF')
        if 'DTTF' in subsys:
            subsys.append('CSCTF2')
            subsys.append('GMT')
        if 'CSCTF' in subsys:
            subsys.append('CSCTF1')
            subsys.append('CSCTF2')
            subsys.append('GMT')
        if 'CSCTF2' in subsys:
            subsys.append('GMT')
        if 'RPCTF' in subsys:
            subsys.append('GMT')
        if 'GMT' in subsys:
            subsys.append('GT')

    if stage2L1Trigger.isChosen():
        if 'ECAL' in subsys:
            subsys.append('CALOL1')
        if 'HCAL' in subsys:
            subsys.append('CALOL1')
        if 'CALOL1' in subsys:
            subsys.append('CALOL2')
        if 'CALOL2' in subsys:
            subsys.append('GT')
        if 'CSC' in subsys:
            subsys.append('EMTF')
            subsys.append('OMTF')
        if 'DT' in subsys:
            subsys.append('BMTF')
            subsys.append('OMTF')
        if 'RPC' in subsys:
            subsys.append('BMTF')
            subsys.append('EMTF')
            subsys.append('OMTF')
        if 'BMTF' in subsys:
            subsys.append('GMT')
        if 'EMTF' in subsys:
            subsys.append('GMT')
        if 'OMTF' in subsys:
            subsys.append('GMT')
        if 'GMT' in subsys:
            subsys.append('GT')

    out = []
    for sys in subsys:
        if sys not in out:
            out.append(sys)

    return out
Beispiel #27
0
def L1TReEmulMCFromRAW2015(process):
    L1TReEmulFromRAW2015(process)
    if stage2L1Trigger.isChosen():
            process.simEmtfDigis.CSCInput           = cms.InputTag('simCscTriggerPrimitiveDigis','MPCSORTED')
            process.simOmtfDigis.srcCSC             = cms.InputTag('simCscTriggerPrimitiveDigis','MPCSORTED')
    return process