ATLAS Offline Software
WriteAthenaPool.py
Go to the documentation of this file.
1 # Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
2 
3 
17 
18 
19 from OutputStreamAthenaPool.CreateOutputStreams import AthenaPoolOutputStream
20 
21 
22 __all__ = [ 'AthenaPoolOutputStream' ]
23 
25  """ Helper method to configure Athena to write out POOL files """
26 
27  from AthenaCommon.Logging import logging
28  msg = logging.getLogger( 'configureWriteAthenaPool' )
29  msg.debug( "Configuring Athena for writing POOL files..." )
30 
31  # Load the basic services
32  import AthenaPoolCnvSvc.AthenaPool # noqa: F401
33 
34  from AthenaCommon.AppMgr import ServiceMgr as svcMgr
35  # Switch off splitting by setting default SplitLevel to 0
36  svcMgr.AthenaPoolCnvSvc.PoolAttributes += [ "DEFAULT_SPLITLEVEL ='0'" ]
37 
38  # Set as default the member-wise streaming, ROOT default
39  svcMgr.AthenaPoolCnvSvc.PoolAttributes += [ "STREAM_MEMBER_WISE = '1'" ]
40 
41  # Increase default BasketSize to 32K, ROOT default (but overwritten by POOL)
42  svcMgr.AthenaPoolCnvSvc.PoolAttributes += [ "DEFAULT_BUFFERSIZE = '32000'" ]
43 
44  # Set POOLContainerForm(DataHeaderForm) split level to 0
45  svcMgr.AthenaPoolCnvSvc.PoolAttributes += [ "ContainerName = 'TTree=POOLContainerForm(DataHeaderForm)'; CONTAINER_SPLITLEVEL = '0'" ]
46 
47  svcMgr.AthenaPoolCnvSvc.TopLevelContainerName = ""
48  svcMgr.AthenaPoolCnvSvc.SubLevelBranchName = "<type>/<key>"
49 
50  msg.debug( "Configuring Athena for writing POOL files... [DONE]" )
51  return
52 
53 
55 
56 
57 del _configureWriteAthenaPool
python.WriteAthenaPool._configureWriteAthenaPool
def _configureWriteAthenaPool()
Definition: WriteAthenaPool.py:24