The Gaudi Framework  master (37c0b60a)
AutoLoadUnmetDataInputs.py
Go to the documentation of this file.
1 #!/usr/bin/env gaudirun.py
2 
12 """
13 Find and attribute unmet data inputs as outputs to a Data Loader algorithm.
14 """
15 
16 from Configurables import (
17  AvalancheSchedulerSvc,
18  CPUCruncher,
19  CPUCrunchSvc,
20  HiveSlimEventLoopMgr,
21  HiveWhiteBoard,
22 )
23 from Gaudi.Configuration import *
24 
25 # metaconfig
26 evtslots = 1
27 evtMax = 3
28 algosInFlight = 1
29 
30 whiteboard = HiveWhiteBoard("EventDataSvc", EventSlots=evtslots, OutputLevel=INFO)
31 
32 slimeventloopmgr = HiveSlimEventLoopMgr(SchedulerName="AvalancheSchedulerSvc")
33 
34 AvalancheSchedulerSvc(
35  ThreadPoolSize=algosInFlight, CheckDependencies=True, DataLoaderAlg="AlgA"
36 )
37 
38 CPUCrunchSvc(shortCalib=True)
39 
40 # Assemble the data flow graph
41 a1 = CPUCruncher("AlgA", Loader=True, OutputLevel=VERBOSE)
42 
43 a2 = CPUCruncher("AlgB", OutputLevel=VERBOSE)
44 a2.inpKeys = ["/Event/A1"]
45 
46 a3 = CPUCruncher("AlgC", OutputLevel=VERBOSE)
47 a3.inpKeys = ["/Event/A2"]
48 
49 for a in [a1, a2, a3]:
50  a.avgRuntime = 0.01
51 
53  EvtMax=evtMax,
54  EvtSel="NONE",
55  ExtSvc=[whiteboard],
56  EventLoop=slimeventloopmgr,
57  TopAlg=[a1, a2, a3],
58  MessageSvcType="InertMessageSvc",
59  OutputLevel=DEBUG,
60 )
Gaudi.Configuration
Definition: Configuration.py:1
ApplicationMgr
Definition: ApplicationMgr.h:57