6 This test defines its own version of the Dev_pp_run3_v1 menu and the corresponding PEB/DS configuration, 
    7 and executes several chains testing various types of Partial Event Building and Data Scouting 
   10 from TrigEDMConfig 
import DataScoutingInfo
 
   11 from TrigEDMConfig.TriggerEDM 
import AllowedOutputFormats
 
   12 from TriggerMenuMT.HLT.Menu 
import Dev_pp_run3_v1, EventBuildingInfo, StreamInfo
 
   13 from TriggerMenuMT.HLT.Config.Utility.ChainDefInMenu 
import ChainProp
 
   14 from TriggerMenuMT.HLT.CommonSequences 
import EventBuildingSequences
 
   15 from TrigPartialEventBuilding.TrigPartialEventBuildingConfig 
import StaticPEBInfoWriterToolCfg, RoIPEBInfoWriterToolCfg
 
   16 from libpyeformat_helper 
import SubDetector, SourceIdentifier
 
   17 from AthenaCommon.Logging 
import logging
 
   18 log = logging.getLogger(
'dataScoutingTest')
 
   21 EventBuildingInfo._PartialEventBuildingIdentifiers |= {
'TestPEBOne'       : 
False,
 
   23                                                        'TestPEBThree'     : 
True,
 
   25                                                        'ElectronDSTest'   : 
False,
 
   26                                                        'ElectronDSPEBTest': 
False}
 
   28 DataScoutingInfo._DataScoutingIdentifiers[
'ElectronDSTest'] = 3
 
   29 DataScoutingInfo._DataScoutingIdentifiers[
'ElectronDSPEBTest'] = 3
 
   30 DataScoutingInfo.TruncationThresholds[3] = 5*(1024**2) 
 
   33 AllowedOutputFormats.extend(DataScoutingInfo.getAllDataScoutingIdentifiers())
 
   37     log.debug(
'Executing myMenu')
 
   39     from TriggerMenuMT.HLT.Menu.SignatureDicts 
import ChainStore
 
   43         ChainProp(name=
'HLT_e3_etcut_ElectronDSPEBTest_L1eEM5', stream=[
'ElectronDSPEBTest'], groups=[
'RATE:Test',
'BW:Other']),
 
   46         ChainProp(name=
'HLT_e5_etcut_ElectronDSTest_L1eEM5', stream=[
'ElectronDSTest'], groups=[
'RATE:Test',
'BW:Other']),
 
   49         ChainProp(name=
'HLT_e7_etcut_TestPEBOne_L1eEM5', stream=[
'TestPEBOne'], groups=[
'RATE:Test',
'BW:Other']),
 
   52         ChainProp(name=
'HLT_e10_etcut_TestPEBThree_L1eEM5', stream=[
'TestPEBThree'], groups=[
'RATE:Test',
'BW:Other']),
 
   55         ChainProp(name=
'HLT_e12_etcut_L1eEM5', stream=[
'Main'], groups=[
'RATE:SingleElectron', 
'BW:Electron']),
 
   60         ChainProp(name=
'HLT_mu6_TestPEBTwo_L1MU5VF', stream=[
'TestPEBTwo'], groups=[
'RATE:Test',
'BW:Other']),
 
   63         ChainProp(name=
'HLT_mu6_TestPEBFour_L1MU5VF', stream=[
'TestPEBFour'], groups=[
'RATE:Test',
'BW:Other']),
 
   66         ChainProp(name=
'HLT_2mu6_L12MU5VF', stream=[
'Main'], groups=[
'RATE:SingleMuon', 
'BW:Muon']),
 
   70 Dev_pp_run3_v1.setupMenu = myMenu
 
   74     log.debug(
'Executing myPebInfoWriterToolCfg')
 
   77     HLT_ROB = SourceIdentifier(SubDetector.TDAQ_HLT, DataScoutingInfo.getFullHLTResultID())
 
   80     if 'TestPEBOne' == eventBuildType:
 
   85             ROBs = [0x42002e, 0x420060, 0x420064, 
 
   88     elif 'TestPEBTwo' == eventBuildType:
 
   93             subDets = [SubDetector.MUON_RPC_BARREL_A_SIDE,
 
   94                        SubDetector.MUON_RPC_BARREL_C_SIDE] ) 
 
   96     elif 'TestPEBThree' == eventBuildType:
 
  105             regSelDets = [
'All'],
 
  108     elif 'TestPEBFour' == eventBuildType:
 
  115             regSelDets = [
'MDT', 
'CSC', 
'RPC', 
'TGC', 
'MM', 
'sTGC']) 
 
  117     elif 'ElectronDSTest' == eventBuildType:
 
  122             ROBs = [SourceIdentifier(SubDetector.TDAQ_HLT,
 
  123                                      DataScoutingInfo.getDataScoutingResultID(eventBuildType))])
 
  125     elif 'ElectronDSPEBTest' == eventBuildType:
 
  131             ROBs = [SourceIdentifier(SubDetector.TDAQ_HLT,
 
  132                                      DataScoutingInfo.getDataScoutingResultID(eventBuildType))],
 
  135             regSelDets = [
'Pixel', 
'SCT', 
'TRT', 
'TTEM', 
'TTHEC', 
'FCALEM', 
'FCALHAD'])
 
  139         log.error(
'PEBInfoWriterTool configuration is missing for event building identifier \'%s\'', eventBuildType)
 
  143 EventBuildingSequences.pebInfoWriterToolCfg = myPebInfoWriterToolCfg
 
  148     StreamInfo.StreamInfo(
'Main',               
'physics',      
True, 
True),
 
  149     StreamInfo.StreamInfo(
'TestPEBOne',         
'physics',      
True, 
False),
 
  150     StreamInfo.StreamInfo(
'TestPEBTwo',         
'calibration',  
True, 
False),
 
  151     StreamInfo.StreamInfo(
'TestPEBThree',       
'physics',      
True, 
False),
 
  152     StreamInfo.StreamInfo(
'TestPEBFour',        
'calibration',  
True, 
False),
 
  153     StreamInfo.StreamInfo(
'ElectronDSTest',     
'physics',      
True, 
False),
 
  154     StreamInfo.StreamInfo(
'ElectronDSPEBTest',  
'physics',      
True, 
False),
 
  157 StreamInfo._all_streams = myAllStreams
 
  160     from TriggerJobOpts 
import runHLT
 
  162     runHLT.set_flags(flags)
 
  163     flags.Trigger.triggerMenuSetup = 
'Dev_pp_run3_v1' 
  164     flags.Trigger.enabledSignatures = [
'Egamma',
'Muon']
 
  165     flags.Trigger.doLVL1 = 
True 
  167     flags.Trigger.ExtraEDMList = [
 
  168             (
'xAOD::TrigElectronContainer#HLT_FastElectrons',                      
'BS ESD AODFULL ElectronDSTest ElectronDSPEBTest', 
'Egamma'),
 
  169             (
'xAOD::TrigElectronAuxContainer#HLT_FastElectronsAux.',               
'BS ESD AODFULL ElectronDSTest ElectronDSPEBTest', 
'Egamma'),
 
  170             (
'xAOD::TrackParticleContainer#HLT_IDTrack_Electron_FTF',              
'BS ESD AODFULL ElectronDSTest ElectronDSPEBTest', 
'Egamma'),
 
  171             (
'xAOD::TrackParticleAuxContainer#HLT_IDTrack_Electron_FTFAux.',       
'BS ESD AODFULL ElectronDSTest ElectronDSPEBTest', 
'Egamma'),
 
  172             (
'xAOD::TrackParticleContainer#HLT_IDTrack_Electron_IDTrig',           
'BS ESD AODFULL ElectronDSTest ElectronDSPEBTest', 
'Egamma'),
 
  173             (
'xAOD::TrackParticleAuxContainer#HLT_IDTrack_Electron_IDTrigAux.',    
'BS ESD AODFULL ElectronDSTest ElectronDSPEBTest', 
'Egamma'),
 
  174             (
'xAOD::TrackParticleContainer#HLT_IDTrack_Electron_GSF',              
'BS ESD AODFULL ElectronDSTest ElectronDSPEBTest', 
'Egamma'),
 
  175             (
'xAOD::TrackParticleAuxContainer#HLT_IDTrack_Electron_GSFAux.',       
'BS ESD AODFULL ElectronDSTest ElectronDSPEBTest', 
'Egamma'),
 
  176             (
'xAOD::CaloClusterContainer#HLT_CaloEMClusters_Electron',             
'BS ESD AODFULL ElectronDSTest ElectronDSPEBTest', 
'Egamma'),
 
  177             (
'xAOD::CaloClusterTrigAuxContainer#HLT_CaloEMClusters_ElectronAux.',  
'BS ESD AODFULL ElectronDSTest ElectronDSPEBTest', 
'Egamma'),
 
  178             (
'xAOD::ElectronContainer#HLT_egamma_Electrons',                       
'BS ESD AODFULL ElectronDSTest ElectronDSPEBTest', 
'Egamma'),
 
  179             (
'xAOD::ElectronAuxContainer#HLT_egamma_ElectronsAux.',                
'BS ESD AODFULL ElectronDSTest ElectronDSPEBTest', 
'Egamma'),
 
  180             (
'xAOD::ElectronContainer#HLT_egamma_Electrons_GSF',                   
'BS ESD AODFULL ElectronDSTest ElectronDSPEBTest', 
'Egamma'),
 
  181             (
'xAOD::ElectronAuxContainer#HLT_egamma_Electrons_GSFAux.',            
'BS ESD AODFULL ElectronDSTest ElectronDSPEBTest', 
'Egamma'),
 
  184     acc = runHLT.runHLTCfg(flags, checkMT=
False)