4 from AthenaConfiguration.ComponentAccumulator
import ComponentAccumulator
5 from AthenaConfiguration.ComponentFactory
import CompFactory
6 acc = ComponentAccumulator()
7 acc.setPrivateTools(CompFactory.ActsTrk.MaterialTrackRecorderTool(name, **kwargs))
12 from AthenaConfiguration.ComponentAccumulator
import ComponentAccumulator
13 from AthenaConfiguration.ComponentFactory
import CompFactory
15 acc = ComponentAccumulator()
18 actionAcc = ComponentAccumulator()
21 actionAcc.setPrivateTools(actions)
22 MaterialTrackRecorderAction = acc.popToolsAndMerge(actionAcc)
25 from G4AtlasServices.G4AtlasUserActionConfig
import getDefaultActions
26 defaultActions = acc.popToolsAndMerge(getDefaultActions(configFlags))
29 actionList = (defaultActions + MaterialTrackRecorderAction)
31 kwargs.setdefault(
"UserActionTools",actionList)
32 acc.addService(CompFactory.G4UA.UserActionSvc(name,**kwargs), primary =
True)
37 name="MaterialTrackWriter",
38 FileName="material-tracks.root",
39 OutStream="ACTSMATERIALWRITER",
41 from AthenaConfiguration.ComponentAccumulator
import ComponentAccumulator
42 from AthenaConfiguration.ComponentFactory
import CompFactory
43 acc = ComponentAccumulator()
44 kwargs.setdefault(
"OutStream", OutStream)
45 kwargs.setdefault(
"useTrackingGeometry",
True)
47 from MuonConfig.MuonConfigUtils
import setupHistSvcCfg
48 acc.merge(setupHistSvcCfg(configFlags, outFile = FileName, outStream=kwargs[
"OutStream"]))
50 acc.addEventAlgo(CompFactory.ActsTrk.MaterialTrackWriter(name, **kwargs), primary =
True)
55 from AthenaConfiguration.ComponentAccumulator
import ComponentAccumulator
56 from AthenaConfiguration.ComponentFactory
import CompFactory
57 acc = ComponentAccumulator()
59 acc.addEventAlgo(CompFactory.ActsTrk.MaterialTrackReader(name, **kwargs), primary =
True)
64 from AthenaConfiguration.ComponentAccumulator
import ComponentAccumulator
65 from AthenaConfiguration.ComponentFactory
import CompFactory
66 acc = ComponentAccumulator()
67 acc.setPrivateTools(CompFactory.ActsTrk.RootMaterialWriterTool(name, **kwargs))
71 name="MaterialMapping",
74 OutputMappedMaterialTracks="OuputMappedMaterialTracks",
75 OutputUnmappedMaterialTracks="OutputUnmappedMaterialTracks",
78 from AthenaConfiguration.ComponentAccumulator
import ComponentAccumulator
79 from AthenaConfiguration.ComponentFactory
import CompFactory
80 acc = ComponentAccumulator()
83 from ActsConfig.ActsGeometryConfig
import ActsTrackingGeometrySvcCfg
84 acc.merge( ActsTrackingGeometrySvcCfg(configFlags))
87 kwargs.setdefault(
"MaterialMapWriters", mapwriters)
89 kwargs.setdefault(
"MappedMaterialTrackCollectionKey", OutputMappedMaterialTracks)
90 kwargs.setdefault(
"UnmappedMaterialTrackCollectionKey", OutputUnmappedMaterialTracks)
94 acc.addEventAlgo(CompFactory.ActsTrk.MaterialMapping(name, **kwargs), primary =
True)
97 from ActsConfig.ActsMaterialConfig
import MaterialTrackWriterCfg
99 name=
"MappedMaterialTrackWriter",
100 FileName=
"material-tracks-mapped.root",
101 OutStream=
"ACTSMAPPEDMATERIALWRITER",
102 StoreSurface=StoreSurfInfo,
103 MaterialTrackCollectionKey=OutputMappedMaterialTracks))
105 name=
"UnmappedMaterialTrackWriter",
106 FileName=
"material-tracks-unmapped.root",
107 OutStream=
"ACTSUNMAPPEDMATERIALWRITER",
108 StoreSurface=StoreSurfInfo,
109 MaterialTrackCollectionKey=OutputUnmappedMaterialTracks))
116 OutputMaterialTracks="OutputMaterialTracks",
117 name="MaterialValidation", **kwargs) :
118 from AthenaConfiguration.ComponentAccumulator
import ComponentAccumulator
119 from AthenaConfiguration.ComponentFactory
import CompFactory
120 acc = ComponentAccumulator()
123 from ActsConfig.ActsGeometryConfig
import ActsTrackingGeometrySvcCfg
124 acc.merge( ActsTrackingGeometrySvcCfg(configFlags))
126 kwargs.setdefault(
"MaterialTrackCollectionKey", OutputMaterialTracks)
128 acc.addEventAlgo(CompFactory.ActsTrk.MaterialValidation(name, **kwargs), primary =
True)
130 from ActsConfig.ActsMaterialConfig
import MaterialTrackWriterCfg
132 FileName=
"material-tracks-validation.root",
133 MaterialTrackCollectionKey=OutputMaterialTracks))
MaterialMappingCfg(configFlags, name="MaterialMapping", StoreTracks=False, StoreSurfInfo=False, OutputMappedMaterialTracks="OuputMappedMaterialTracks", OutputUnmappedMaterialTracks="OutputUnmappedMaterialTracks", **kwargs)