ATLAS Offline Software
Trigger
TrigMonitoring
TrigBphysMonitoring
python
TrigBphysMonitorAlgorithm.py
Go to the documentation of this file.
1
#
2
# Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3
#
4
5
def
TrigBphysMonConfig
(inputFlags):
6
'''Function to configures some algorithms in the monitoring system.'''
7
8
# The following class will make a sequence, configure algorithms, and link
9
# them to GenericMonitoringTools
10
from
AthenaMonitoring
import
AthMonitorCfgHelper
11
helper = AthMonitorCfgHelper(inputFlags,
'TrigBphysAthMonitorCfg'
)
12
13
from
TrigBphysMonitoring.TrigBphysMonitoringConfig
import
TrigBphysMonAlgBuilder
14
monAlgCfg = TrigBphysMonAlgBuilder( helper, useMonGroups =
True
)
15
16
# build monitor and book histograms
17
monAlgCfg.configure()
18
19
return
helper.result()
20
21
22
if
__name__==
'__main__'
:
23
# Set the Athena configuration flags
24
from
AthenaConfiguration.AllConfigFlags
import
initConfigFlags
25
nightly =
'/cvmfs/atlas-nightlies.cern.ch/repo/data/data-art/CommonInputs/'
26
file =
'data16_13TeV.00311321.physics_Main.recon.AOD.r9264/AOD.11038520._000001.pool.root.1'
27
28
flags =
initConfigFlags
()
29
flags.Input.Files = [nightly+file]
30
flags.Input.isMC =
False
31
flags.Output.HISTFileName =
'TrigBphysMonitorOutput.root'
32
33
flags.lock()
34
35
# Initialize configuration object, add accumulator, merge, and run.
36
from
AthenaConfiguration.MainServicesConfig
import
MainServicesCfg
37
from
AthenaPoolCnvSvc.PoolReadConfig
import
PoolReadCfg
38
cfg =
MainServicesCfg
(flags)
39
cfg.merge(
PoolReadCfg
(flags))
40
41
trigBphysMonitorAcc =
TrigBphysMonConfig
(flags)
42
cfg.merge(trigBphysMonitorAcc)
43
44
# If you want to turn on more detailed messages ...
45
#trigBphysMonitorAcc.getEventAlgo('TrigBphysMonAlg').OutputLevel = 2 # DEBUG
46
cfg.printConfig(withDetails=
True
)
# set True for exhaustive info
47
48
cfg.run()
#use cfg.run(20) to only run on first 20 events
49
python.MainServicesConfig.MainServicesCfg
def MainServicesCfg(flags, LoopMgr='AthenaEventLoopMgr')
Definition:
MainServicesConfig.py:260
python.AllConfigFlags.initConfigFlags
def initConfigFlags()
Definition:
AllConfigFlags.py:19
TrigBphysMonitorAlgorithm.TrigBphysMonConfig
def TrigBphysMonConfig(inputFlags)
Definition:
TrigBphysMonitorAlgorithm.py:5
python.PoolReadConfig.PoolReadCfg
def PoolReadCfg(flags)
Definition:
PoolReadConfig.py:69
Generated on Sun Dec 22 2024 21:20:43 for ATLAS Offline Software by
1.8.18