15 from AthenaMonitoring
import AthMonitorCfgHelper
16 monConfig = AthMonitorCfgHelper(flags,
'TRTMonitoring')
18 from AthenaConfiguration.ComponentFactory
import CompFactory
19 alg = monConfig.addAlgorithm(CompFactory.TRTMonitoringAlg,
'TRTMonitoringAlg')
21 from InDetConfig.InDetTrackSelectionToolConfig
import InDetTrackSelectionTool_LoosePrimary_Cfg
23 alg.TrackSelectionTool = trkSel
25 from TrigConfigSvc.TriggerConfigAccess
import getHLTMonitoringAccess
27 chains =
getMinBiasChains(monAccess,
'HLT_noalg_L1TRT_FILLED|HLT_mb_excl_1trk5_pt1_hi_FgapAC5_L1TRT_VjTE20|HLT_noalg_L1TRT_VjTE50')
29 ref_chains = [
'HLT_mb_sptrk_L1ZDC_XOR_VjTE200',
'HLT_mb_sptrk_L1ZDC_1XOR5_VjTE200',
'HLT_mb_sptrk_L11ZDC_A_1ZDC_C_VjTE200'
30 'HLT_mb_sptrk_hi_FgapC5_L1VjTE200',
'HLT_mb_sptrk_hi_FgapA5_L1VjTE200',
'HLT_noalg_L1RD0_FILLED',
'HLT_mb_sptrk_L1VjTE50']
32 log.info(f
'Monitoring {len(chains)} L1TRT chain(s)')
33 log.debug([name
for name, _
in chains])
35 alg.triggerList = [name
for name, _
in chains]
36 alg.refTriggerList = ref_chains
38 for chain, group
in chains:
39 hiTRTGroup = monConfig.addGroup(alg, f
'{chain}', topPath=f
'HLT/MinBiasMon/{group}/L1TRT/{chain}/')
42 hiTRTGroup.defineHistogram(
'n_trk', title=
'Track multiplicity;N_{trk};Events / 1', xbins=20, xmin=-0.5, xmax=19.5)
43 hiTRTGroup.defineHistogram(
'lead_trk_pT', title=
'Leading track p_{T};p_{T}^{lead} [GeV];Events / 100 MeV', xbins=40, xmin=0, xmax=4)
46 hiTRTGroup.defineHistogram(f
'effPassed,n_trk;{chain}_eff_ntrk', type=
'TEfficiency',
47 title=
'L1 TRT efficiency;N_{trk};Efficiency', xbins=20, xmin=-0.5, xmax=19.5)
48 hiTRTGroup.defineHistogram(f
'effPassed,lead_trk_pT;{chain}_eff_pT', type=
'TEfficiency',
49 title=
'L1 TRT efficiency;p_{T}^{lead} [GeV];Efficiency', xbins=40, xmin=0, xmax=4)
51 return monConfig.result()