ATLAS Offline Software
Loading...
Searching...
No Matches
ISF_ServicesCoreConfig.py
Go to the documentation of this file.
1"""ComponentAccumulator core ISF_Service configuration
2Provides local configuration to be imported without circular dependencies
3Complements ISF_ServicesConfig
4
5Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
6"""
7from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
8from AthenaConfiguration.ComponentFactory import CompFactory
10from SubDetectorEnvelopes.SubDetectorEnvelopesConfig import EnvelopeDefSvcCfg
11from ISF_Tools.ISF_ToolsConfig import ParticleKillerToolCfg
12
13
14def ISFEnvelopeDefSvcCfg(flags, name="ISF_ISFEnvelopeDefSvc", **kwargs):
15 # ATLAS common envlope definitions
16 result = ComponentAccumulator()
17 kwargs.setdefault("ATLASEnvelopeDefSvc", result.getPrimaryAndMerge(EnvelopeDefSvcCfg(flags)))
18 result.addService(CompFactory.ISF.ISFEnvelopeDefSvc(name, **kwargs), primary = True)
19 return result
20
21
22def GeoIDSvcCfg(flags, name="ISF_GeoIDSvc", **kwargs):
23 result = ComponentAccumulator()
24 # with ISF volume definitions
25 kwargs.setdefault("EnvelopeDefSvc", result.getPrimaryAndMerge(ISFEnvelopeDefSvcCfg(flags)))
26 result.addService(CompFactory.ISF.GeoIDSvc(name, **kwargs), primary = True)
27 return result
28
29
30def ATLFAST_EnvelopeDefSvcCfg(flags, name="ISF_ATLFAST_EnvelopeDefSvc", **kwargs):
31 result = ComponentAccumulator()
32 # ATLAS common envlope definitions
33 kwargs.setdefault("ISFEnvelopeDefSvc", result.getPrimaryAndMerge(ISFEnvelopeDefSvcCfg(flags)))
34 kwargs.setdefault("InDetMaxExtentZ", 3549.5*mm)
35 result.addService(CompFactory.ISF.ATLFAST_EnvelopeDefSvc(name, **kwargs), primary = True)
36 return result
37
38
39def ATLFAST_GeoIDSvcCfg(flags, name="ISF_ATLFAST_GeoIDSvc", **kwargs):
40 result = ComponentAccumulator()
41 kwargs.setdefault("EnvelopeDefSvc", result.getPrimaryAndMerge(ATLFAST_EnvelopeDefSvcCfg(flags)))
42 result.addService(CompFactory.ISF.GeoIDSvc(name, **kwargs), primary = True)
43 return result
44
45
46# previously in LegacySimServicesConfig
47def ParticleKillerSvcCfg(flags, name="ISF_ParticleKillerSvc", **kwargs):
48 result = ComponentAccumulator()
49 kwargs.setdefault("Identifier", "ParticleKiller")
50 tool = result.popToolsAndMerge(ParticleKillerToolCfg(flags))
51 kwargs.setdefault("SimulatorTool", tool)
52 result.addService(CompFactory.ISF.LegacySimSvc(name, **kwargs), primary = True)
53 return result
ATLFAST_GeoIDSvcCfg(flags, name="ISF_ATLFAST_GeoIDSvc", **kwargs)
ATLFAST_EnvelopeDefSvcCfg(flags, name="ISF_ATLFAST_EnvelopeDefSvc", **kwargs)
ParticleKillerSvcCfg(flags, name="ISF_ParticleKillerSvc", **kwargs)
ISFEnvelopeDefSvcCfg(flags, name="ISF_ISFEnvelopeDefSvc", **kwargs)
GeoIDSvcCfg(flags, name="ISF_GeoIDSvc", **kwargs)