ATLAS Offline Software
testTrigR2ToR3NavGraphConversionV2.py
Go to the documentation of this file.
1 #!/usr/bin/env python
2 #
3 # Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
4 
5 import sys
6 
7 # Set the Athena configuration flags
8 from AthenaConfiguration.AllConfigFlags import initConfigFlags
9 flags = initConfigFlags()
10 
11 flags.Input.Files=["/cvmfs/atlas-nightlies.cern.ch/repo/data/data-art/Tier0ChainTests/data18_13TeV.00357772.physics_Main.recon.AOD.r13286/AOD.27654050._000557.pool.root.1"]
12 # BELOW: alternative test AOD file
13 # flags.Input.Files=["/cvmfs/atlas-nightlies.cern.ch/repo/data/data-art/DerivationFrameworkART/mc20_13TeV.410470.PhPy8EG_A14_ttbar_hdamp258p75_nonallhad.recon.AOD.e6337_s3681_r13167/AOD.27162646._000001.pool.root.1"]
14 # can browse config for this file here:
15 flags.Detector.GeometryLAr=True
16 flags.Detector.GeometryTile=True
17 flags.Exec.MaxEvents = 20
18 flags.Exec.SkipEvents = 0
19 flags.Trigger.doEDMVersionConversion=True
20 flags.fillFromArgs()
21 flags.Concurrency.NumThreads=1
22 flags.lock()
23 
24 # Initialize configuration object, add accumulator, merge, and run.
25 from AthenaConfiguration.MainServicesConfig import MainServicesCfg
26 from AthenaConfiguration.ComponentFactory import CompFactory
27 
28 from AthenaPoolCnvSvc.PoolReadConfig import PoolReadCfg
29 cfg = MainServicesCfg(flags)
30 cfg.merge(PoolReadCfg(flags))
31 
32 from AthenaServices.MetaDataSvcConfig import MetaDataSvcCfg
33 cfg.merge(MetaDataSvcCfg(flags))
34 
35 confSvc = CompFactory.TrigConf.xAODConfigSvc("xAODConfigSvc")
36 cfg.addService(confSvc)
37 from AthenaCommon.Constants import DEBUG
38 
39 from DerivationFrameworkPhys.TriggerListsHelper import TriggerListsHelper
40 triggerListsHelper = TriggerListsHelper(flags)
41 chains = triggerListsHelper.Run2TriggerNamesNoTau + triggerListsHelper.Run2TriggerNamesTau
42 
43 from TrigNavTools.NavConverterConfig import NavConverterCfg
44 cfg.merge(NavConverterCfg(flags, chainsList=chains, runTheChecker=True))
45 
46 # input EDM needs calo det descrition for conversion (uff)
47 from LArGeoAlgsNV.LArGMConfig import LArGMCfg
48 from TileGeoModel.TileGMConfig import TileGMCfg
49 cfg.merge(LArGMCfg(flags))
50 cfg.merge(TileGMCfg(flags))
51 
52 # enable to get the navigation graphs *.dot files
53 # from TrigValAlgs.TrigValAlgsConfig import TrigEDMCheckerCfg
54 # cfg.merge(TrigEDMCheckerCfg(flags, doDumpAll=False))
55 # cfg.getEventAlgo("TrigEDMChecker").doDumpTrigCompsiteNavigation=True
56 
57 msg = cfg.getService('MessageSvc');
58 msg.verboseLimit=0 # this is option for verbose log
59 msg.debugLimit=0
60 msg.infoLimit=0
61 msg.warningLimit=0
62 msg.Format='% F%35W%C% F%9W%e%7W%R%T %0W%M'
63 cfg.printConfig(withDetails=True, summariseProps=False) # set True for exhaustive info
64 sc = cfg.run()
65 sys.exit(0 if sc.isSuccess() else 1)
python.MainServicesConfig.MainServicesCfg
def MainServicesCfg(flags, LoopMgr='AthenaEventLoopMgr')
Definition: MainServicesConfig.py:260
Constants
some useful constants -------------------------------------------------—
LArGMConfig.LArGMCfg
def LArGMCfg(flags)
Definition: LArGMConfig.py:8
python.MetaDataSvcConfig.MetaDataSvcCfg
def MetaDataSvcCfg(flags, toolNames=[], tools=[])
Definition: MetaDataSvcConfig.py:6
python.AllConfigFlags.initConfigFlags
def initConfigFlags()
Definition: AllConfigFlags.py:19
python.PoolReadConfig.PoolReadCfg
def PoolReadCfg(flags)
Definition: PoolReadConfig.py:69
python.NavConverterConfig.NavConverterCfg
def NavConverterCfg(flags, chainsList=[], runTheChecker=False)
Definition: NavConverterConfig.py:12
TileGMConfig.TileGMCfg
def TileGMCfg(flags)
Definition: TileGMConfig.py:7