The Gaudi Framework  v29r0 (ff2e7097)
InertMessageSvc.py
Go to the documentation of this file.
1 #!/usr/bin/env gaudirun.py
2 
3 # Just hammer the logger with a lot of messages
4 
5 from Gaudi.Configuration import *
6 from Configurables import HiveWhiteBoard, HiveSlimEventLoopMgr, ForwardSchedulerSvc, CPUCruncher
7 
8 verbosity = VERBOSE
9 
10 InertMessageSvc(OutputLevel=verbosity)
11 TBBMessageSvc(OutputLevel=verbosity)
12 
13 # metaconfig
14 evtslots = 10
15 evtMax = 50
16 cardinality = 20
17 algosInFlight = 20
18 
19 whiteboard = HiveWhiteBoard("EventDataSvc",
20  EventSlots=evtslots)
21 
22 slimeventloopmgr = HiveSlimEventLoopMgr(OutputLevel=verbosity)
23 
24 scheduler = ForwardSchedulerSvc(MaxEventsInFlight=evtslots,
25  MaxAlgosInFlight=algosInFlight,
26  OutputLevel=verbosity,
27  AlgosDependencies=[[], []])
28 
29 a1 = CPUCruncher("A1",
30  DataOutputs=['/Event/a1'],
31  varRuntime=.1,
32  avgRuntime=.5)
33 a2 = CPUCruncher("A2",
34  DataInputs=[],
35  DataOutputs=['/Event/a2'])
36 
37 for algo in [a1, a2]:
38  algo.Cardinality = cardinality
39  algo.shortCalib = True
40  algo.OutputLevel = verbosity
41 
42 ApplicationMgr(EvtMax=evtMax,
43  EvtSel='NONE',
44  ExtSvc=[whiteboard],
45  EventLoop=slimeventloopmgr,
46  TopAlg=[a1, a2],
47  MessageSvcType="InertMessageSvc")
Thread safe extension to the standard MessageSvc.
A class that implements a search for prime numbers.
Definition: CPUCruncher.h:19
The SchedulerSvc implements the IScheduler interface.
Data service base class.
The Application Manager class.