4Dump the ACTS tracking geometry to a file.
7from AthenaCommon.Logging
import log
8from argparse
import ArgumentParser
9from AthenaConfiguration.AllConfigFlags
import initConfigFlags
11parser = ArgumentParser(
"RunActsWriteTrackingGeometry.py")
14 "--verboseAccumulators",
17 help=
"Print full details of the AlgSequence",
24 help=
"Dump the StoreGate(s) each event iteration",
30 help=
"The geometry tag to use. If not specified, the default RUN4 tag will be used.",
36 help=
"Also dump the material assigned to the geometry to a Json material map",
38args = parser.parse_args()
40flags = initConfigFlags()
42flags.Input.isMC =
True
45from AthenaConfiguration.TestDefaults
import defaultGeometryTags, defaultConditionsTags
47flags.GeoModel.AtlasVersion = args.geometrytag
if args.geometrytag
else defaultGeometryTags.RUN4
48flags.IOVDb.GlobalTag = defaultConditionsTags.RUN4_MC
50flags.Detector.GeometryBpipe =
False
51flags.Detector.GeometryHGTD =
False
52flags.Detector.GeometryITkPixel =
False
53flags.Detector.GeometryITkStrip =
False
54flags.Detector.GeometryCalo =
False
55from MuonGeoModelTestR4.testGeoModel
import MuonPhaseIITestDefaults
56flags.GeoModel.SQLiteDBFullPath = MuonPhaseIITestDefaults.GEODB_R4
57flags.GeoModel.SQLiteDB =
False
58flags.Detector.GeometryMuon =
False
59flags.Muon.trackGeometryMaterialMap=
"/cvmfs/atlas-nightlies.cern.ch/repo/data/data-art/MuonGeomRTT/material-maps.root"
61flags.GeoModel.Align.Dynamic =
False
62flags.Acts.TrackingGeometry.UseBlueprint =
True
63flags.Acts.TrackingGeometry.KeepGoingOnMaterialMergeFailure =
True
64flags.Acts.TrackingGeometry.ITkHgtdMaterialSource =
"Default"
65flags.Acts.TrackingGeometry.ITkHgtdMaterialSource =
"material-maps-itk-hgtd-ATLAS-P2-RUN4-05-00-00.json"
66flags.Acts.TrackingGeometry.ITkHgtdMaterialMapPath =
"."
69flags.Concurrency.NumThreads = 1
70flags.Concurrency.NumConcurrentEvents = 1
75log.debug(
"Lock config flags now.")
77from AthenaConfiguration.MainServicesConfig
import MainServicesCfg
79cfg = MainServicesCfg(flags)
81if args.verboseAccumulators:
82 cfg.printConfig(withDetails=
True)
83if args.verboseStoreGate:
84 cfg.getService(
"StoreGateSvc").Dump =
True
86from ActsConfig.ActsGeometryConfig
import ActsWriteTrackingGeometryCfg
88cfg.merge(ActsWriteTrackingGeometryCfg(flags, name=
"ActsWriteTrackingGeometry"))
89if args.dumpMaterialJson:
90 from ActsConfig.ActsMaterialConfig
import MaterialJsonDumpCfg
91 cfg.merge(MaterialJsonDumpCfg(flags, FileName=
"material-maps"))
94cfg.printConfig(withDetails=
True, summariseProps=
True)