The Gaudi Framework  v36r1 (3e2fb5a8)
AlgSequencer.py
Go to the documentation of this file.
1 
14 
15 from Gaudi.Configuration import *
16 from Configurables import ParentAlg, StopperAlg, Prescaler, HelloWorld, TimingAuditor
17 
18 from Configurables import GaudiExamplesCommonConf
19 GaudiExamplesCommonConf()
20 
21 # --------------------------------------------------------------
22 # Testing Sequencers
23 # --------------------------------------------------------------
24 p1 = Prescaler('Prescaler1', PercentPass=50., OutputLevel=WARNING)
25 p2 = Prescaler('Prescaler2', PercentPass=10., OutputLevel=WARNING)
26 h = HelloWorld(OutputLevel=DEBUG)
27 c1 = EventCounter('Counter1')
28 c2 = EventCounter('Counter2')
29 s1 = Sequencer('Sequence1', Members=[p1, h, c1])
30 s2 = Sequencer('Sequence2', Members=[p2, h, c2])
31 top = Sequencer('TopSequence', Members=[s1, s2], StopOverride=True)
32 
33 # -----------------------------------------------------------------
34 # Testing the new GaudiSequencer
35 # -----------------------------------------------------------------
37  'ANDSequence',
38  Members=[HelloWorld('AND'), EventCounter('ANDCounter')],
39  MeasureTime=1)
41  'ORSequence',
42  Members=[HelloWorld('OR'), EventCounter('ORCounter')],
43  MeasureTime=1,
44  ModeOR=1)
45 
46 # -----------------------------------------------------------------
48  TopAlg=[ParentAlg(), StopperAlg(StopCount=20), top, sand, sor],
49  EvtMax=10, # events to be processed (default is 10)
50  EvtSel='NONE', # do not use any event input
51  ExtSvc=['ToolSvc', 'AuditorSvc'],
52  AuditAlgorithms=True)
53 
54 AuditorSvc().Auditors += [TimingAuditor("TIMER")]
Sequencer
ClassName: Sequencer.
Definition: Sequencer.h:35
EventCounter
Definition: EventCounter.h:14
AuditorSvc
Definition: AuditorSvc.h:28
Gaudi.Configuration
Definition: Configuration.py:1
GaudiSequencer
Definition: GaudiSequencer.h:38
ApplicationMgr
Definition: ApplicationMgr.h:57