ATLAS Offline Software
Loading...
Searching...
No Matches
run_hypo_mult.py
Go to the documentation of this file.
1#!/usr/bin/env python
2# Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3
4if __name__ == '__main__':
5
6 from add_subsystems import add_subsystems
7
8 from AthenaConfiguration.AllConfigFlags import initConfigFlags
9 flags = initConfigFlags()
10 parser = flags.getArgumentParser()
11
12 parser.add_argument(
13 "-ifex",
14 "--doCaloInput",
15 action="store_true",
16 dest="doCaloInput",
17 help="Decoding L1Calo inputs",
18 default=False,
19 required=False)
20
21 parser.add_argument(
22 "--dump",
23 action="store_true",
24 help="Write out dumps",
25 default=False)
26
27 parser.add_argument(
28 "--dumpTerse",
29 action="store_true",
30 help="Write out dumps: tersely",
31 default=False)
32
33
34 from AthenaConfiguration.TestDefaults import defaultTestFiles, defaultGeometryTags, defaultConditionsTags
35 flags.Input.Files = defaultTestFiles.RAW_RUN3_DATA24
36 flags.GeoModel.AtlasVersion = defaultGeometryTags.RUN3
37 flags.IOVDb.GlobalTag = defaultConditionsTags.RUN3_DATA24
38
39 flags.Output.AODFileName = 'AOD.pool.root'
40 flags.Concurrency.NumThreads = 1
41 flags.Concurrency.NumConcurrentEvents = 1
42 flags.Trigger.doLVL1 = True
43
44 flags.Scheduler.ShowDataDeps = True
45 flags.Scheduler.CheckDependencies = True
46 flags.Scheduler.ShowDataFlow = True
47 flags.Trigger.EDMVersion = 3
48 flags.Trigger.enableL1CaloPhase1 = True
49
50 # Enable only calo for this test
51 from AthenaConfiguration.DetectorConfigFlags import setupDetectorFlags
52
53 setupDetectorFlags(flags, ['LAr','Tile','MBTS'], toggle_geometry=True)
54
55 args = flags.fillFromArgs(parser=parser)
56 flags.lock()
57 flags.dump()
58
59 from AthenaConfiguration.MainServicesConfig import MainServicesCfg
60 acc = MainServicesCfg(flags)
61
62
63
67
68 from AthenaConfiguration.Enums import Format
69 if flags.Input.Format == Format.POOL:
70 from AthenaPoolCnvSvc.PoolReadConfig import PoolReadCfg
71 acc.merge(PoolReadCfg(flags))
72 print('NOT setting up eFex')
73 else:
74 print('setting up eFex')
75 subsystems = ('eFex',)
76 acc.merge(add_subsystems(flags, subsystems, args, OutputLevel=flags.Exec.OutputLevel))
77
78 from TriggerJobOpts.TriggerByteStreamConfig import ByteStreamReadCfg
79 acc.merge(ByteStreamReadCfg(flags))
80
81 from TrigCaloRec.TrigCaloRecConfig import hltCaloCellSeedlessMakerCfg
82 acc.merge(hltCaloCellSeedlessMakerCfg(flags, roisKey=''))
83
84 # add in the Algorithm to be run
85 from GlobalSimAlgCfg_hypo_mult import GlobalSimulationAlgCfg
86 acc.merge(GlobalSimulationAlgCfg(flags, dump=True))
87
88 if acc.run().isFailure():
89 import sys
90 sys.exit(1)
91
92
void print(char *figname, TCanvas *c1)