ATLAS Offline Software
Loading...
Searching...
No Matches
AthenaPoolTestWriteDoubleSelector.py
Go to the documentation of this file.
14import AthenaCommon.AtlasUnixGeneratorJob
15
16
17from AthenaCommon.AlgSequence import AlgSequence
18topSequence = AlgSequence()
19
20
21from AthenaCommon.AppMgr import ServiceMgr as svcMgr
22
23
24from AthenaCommon.AppMgr import theApp
25
26#--------------------------------------------------------------
27# Load POOL support
28#--------------------------------------------------------------
29import AthenaPoolCnvSvc.WriteAthenaPool
30
31#--------------------------------------------------------------
32# Event related parameters
33#--------------------------------------------------------------
34theApp.EvtMax = 5
35
36#--------------------------------------------------------------
37# Event related parameters
38#--------------------------------------------------------------
39# Set the following when reading back to adjust the run/event numbers
40# (don't forget ApplicationMgr.EvtMax)
41svcMgr.EventSelector.RunNumber = 1
42svcMgr.EventSelector.EventsPerRun = 0x10000000000
43svcMgr.EventSelector.FirstEvent = 0x100000000
44svcMgr.EventSelector.EventsPerLB = 1
45svcMgr.EventSelector.FirstLB = 1
46svcMgr.EventSelector.InitialTimeStamp = 0
47svcMgr.EventSelector.TimeStampInterval = 5
48theApp.EvtMax = 2
49
50svcMgr.EventSelector.OutputLevel = DEBUG
51
52#--------------------------------------------------------------
53# Application: AthenaPoolTest options
54#--------------------------------------------------------------
55
56# Load "user algorithm" top algorithms to be run, and the libraries that house them
57from AthenaPoolTest.AthenaPoolTestConf import AthenaPoolTestDataWriter
58topSequence += AthenaPoolTestDataWriter( "AthenaPoolTestDataWriter" )
59AthenaPoolTestDataWriter.OutputLevel = DEBUG
60
61#--------------------------------------------------------------
62# Output options
63#--------------------------------------------------------------
64# ItemList:
65include( "EventAthenaPool/EventAthenaPoolItemList_joboptions.py" )
66include( "AthenaPoolTestAthenaPool/AthenaPoolTestAthenaPoolItemList_joboptions.py" )
67
68# Stream's output file
69from AthenaPoolCnvSvc.WriteAthenaPool import AthenaPoolOutputStream
70
71# Stream1
72Stream1 = AthenaPoolOutputStream( "Stream1", noTag=True )
73Stream1.OutputFile = "SimplePoolFile1.root"
74# List of DO's to write out
75Stream1.ItemList += fullItemList
76
77# Stream2
78Stream2 = AthenaPoolOutputStream( "Stream2", noTag=True )
79Stream2.OutputFile = "SimplePoolFile2.root"
80# List of DO's to write out
81Stream2.ItemList += fullItemList
82
83# Remove dumm_A from Stream1
84Stream1.ItemList = [ o for o in Stream1.ItemList if not o in 'dummy_A#*' ]
85Stream1.ItemList = [ o for o in Stream1.ItemList if not o in 'IAthenaPoolTestCollection#*' ]
86
87# Remove dumm_E from Stream2
88Stream2.ItemList = [ o for o in Stream2.ItemList if not o in 'dummy_E#*' ]
89Stream2.ItemList = [ o for o in Stream2.ItemList if not o in 'AthenaPoolTestMatrix#*' ]
90
91printfunc ("Stream1.ItemList ",Stream1.ItemList)
92printfunc ("Stream2.ItemList ",Stream2.ItemList)
93
94# Change output file catalog to avoid collisions.
95from PoolSvc import PoolSvcConf
96PoolSvc = PoolSvcConf.PoolSvc()
97PoolSvc.WriteCatalog = 'file:AthenaPoolTestWriteDoubleSelector_catalog.xml'
98
99#--------------------------------------------------------------
100# Set output level threshold (2=DEBUG, 3=INFO, 4=WARNING, 5=ERROR, 6=FATAL )
101#--------------------------------------------------------------
102svcMgr.MessageSvc.OutputLevel = WARNING
103svcMgr.MessageSvc.debugLimit = 100000
104
105from AthenaServices import AthenaServicesConf
106AthenaEventLoopMgr = AthenaServicesConf.AthenaEventLoopMgr()
107AthenaEventLoopMgr.OutputLevel = INFO
108
109# No stats printout
110include( "AthenaPoolTest/NoStats_jobOptions.py" )
111
112#==============================================================
113#
114# End of job options file
115#
116
Test Algorithm POOL I/O tests, writes AthenaPoolData objects to the transient store.