 |
ATLAS Offline Software
|
◆ configureCondTag()
def MuonConfigUtils.configureCondTag |
( |
|
flags | ) |
|
Definition at line 19 of file MuonConfigUtils.py.
20 if not flags.GeoModel.AtlasVersion:
21 raise ValueError(
"No ATLAS version is configured")
23 from AthenaConfiguration.Enums
import LHCPeriod
24 from AthenaConfiguration.TestDefaults
import defaultConditionsTags
25 if flags.GeoModel.Run == LHCPeriod.Run2:
26 flags.IOVDb.GlobalTag = defaultConditionsTags.RUN2_MC
if flags.Input.isMC
else defaultConditionsTags.RUN2_DATA
27 elif flags.GeoModel.Run == LHCPeriod.Run3:
28 flags.IOVDb.GlobalTag = defaultConditionsTags.RUN3_MC
if flags.Input.isMC
else defaultConditionsTags.RUN3_DATA
29 elif flags.GeoModel.Run == LHCPeriod.Run4:
30 flags.IOVDb.GlobalTag = defaultConditionsTags.RUN4_MC
32 raise ValueError(f
"Invalid run period {flags.GeoModel.Run}")
◆ executeTest()
def MuonConfigUtils.executeTest |
( |
|
cfg | ) |
|
Definition at line 15 of file MuonConfigUtils.py.
16 cfg.printConfig(withDetails=
True, summariseProps=
True)
17 if not cfg.run().isSuccess():
exit(1)
◆ setupHistSvcCfg()
def MuonConfigUtils.setupHistSvcCfg |
( |
|
flags, |
|
|
str |
outFile, |
|
|
str |
outStream |
|
) |
| |
Configuration snippet to setup the THistSvc.
Definition at line 5 of file MuonConfigUtils.py.
6 from AthenaConfiguration.ComponentAccumulator
import ComponentAccumulator
8 if len(outFile) == 0:
return result
9 from AthenaConfiguration.ComponentFactory
import CompFactory
10 histSvc = CompFactory.THistSvc(Output=[f
"{outStream} DATAFILE='{outFile}', OPT='RECREATE'"])
11 print(f
"Regiter new stream {outStream} piped to {outFile}")
12 result.addService(histSvc, primary=
True)
◆ SetupMuonStandaloneCA()
def MuonConfigUtils.SetupMuonStandaloneCA |
( |
|
flags | ) |
|
Definition at line 79 of file MuonConfigUtils.py.
82 from AthenaConfiguration.MainServicesConfig
import MainServicesCfg
84 msgService = cfg.getService(
'MessageSvc')
85 msgService.Format =
"S:%s E:%e % F%128W%S%7W%R%T %0W%M"
86 msgService.debugLimit = 2147483647
87 msgService.verboseLimit = 2147483647
88 msgService.infoLimit = 2147483647
91 from AthenaConfiguration.Enums
import Format
92 if flags.Input.Format
is Format.POOL:
93 from AthenaPoolCnvSvc.PoolReadConfig
import PoolReadCfg
95 elif flags.Input.Format == Format.BS:
96 from ByteStreamCnvSvc.ByteStreamConfig
import ByteStreamReadCfg
100 if (
"TruthEvents" in flags.Input.Collections):
101 from xAODTruthCnv.RedoTruthLinksConfig
import RedoTruthLinksAlgCfg
103 elif (
"TruthEvent" in flags.Input.Collections):
104 from xAODTruthCnv.xAODTruthCnvConfig
import GEN_AOD2xAODCfg
108 from MuonConfig.MuonGeometryConfig
import MuonGeoModelCfg
110 from MuonConfig.MuonGeometryConfig
import MuonIdHelperSvcCfg
◆ SetupMuonStandaloneConfigFlags()
def MuonConfigUtils.SetupMuonStandaloneConfigFlags |
( |
| ) |
|
Setup flags necessary for Muon standalone.
Definition at line 34 of file MuonConfigUtils.py.
36 Setup flags necessary for Muon standalone.
38 from AthenaConfiguration.AllConfigFlags
import initConfigFlags
40 flags.Detector.GeometryMDT =
True
41 flags.Detector.GeometryTGC =
True
43 flags.Detector.GeometryRPC =
True
45 flags.Detector.GeometryCalo =
False
46 flags.Detector.GeometryID =
False
49 flags.Muon.makePRDs =
False
51 flags.Exec.MaxEvents = 20
52 flags.Scheduler.ShowDataDeps =
True
53 flags.Scheduler.CheckDependencies =
True
54 flags.Scheduler.ShowDataFlow =
True
55 flags.Scheduler.ShowControlFlow =
True
56 flags.Concurrency.NumThreads = 1
57 flags.Concurrency.NumConcurrentEvents = 1
62 if flags.Input.Files == [
'_ATHENA_GENERIC_INPUTFILE_NAME_']
or len(flags.Input.Files) == 0:
64 from AthenaConfiguration.TestDefaults
import defaultTestFiles
65 flags.Input.Files = defaultTestFiles.ESD_RUN3_MC
69 from AthenaConfiguration.DetectorConfigFlags
import setupDetectorFlags
72 if flags.Output.ESDFileName ==
'':
73 flags.Output.ESDFileName=
'newESD.pool.root'
76 flags.dump(evaluate =
True)
◆ SetupMuonStandaloneOutput()
def MuonConfigUtils.SetupMuonStandaloneOutput |
( |
|
cfg, |
|
|
|
flags, |
|
|
|
itemsToRecord |
|
) |
| |
Definition at line 115 of file MuonConfigUtils.py.
117 from OutputStreamAthenaPool.OutputStreamConfig
import OutputStreamCfg, outputStreamName
121 outstream.ForceRead =
True
124 from TrkEventCnvTools.TrkEventCnvToolsConfig
import (
125 TrkEventCnvSuperToolCfg)
def OutputStreamCfg(flags, streamName, ItemList=None, MetadataItemList=None, disableEventTag=False, trigNavThinningSvc=None, takeItemsFromInput=False, extendProvenanceRecord=True, keepProvenanceTagsRegEx=None, AcceptAlgs=None, HelperTools=None)
def MuonIdHelperSvcCfg(flags)
def GEN_AOD2xAODCfg(flags, name="GEN_AOD2xAOD", **kwargs)
def ByteStreamReadCfg(flags, type_names=None)
def RedoTruthLinksAlgCfg(flags)
def MuonGeoModelCfg(flags)
def MainServicesCfg(flags, LoopMgr='AthenaEventLoopMgr')
def SetupMuonStandaloneConfigFlags()
void print(char *figname, TCanvas *c1)
def configureCondTag(flags)
def SetupMuonStandaloneCA(flags)
def SetupMuonStandaloneOutput(cfg, flags, itemsToRecord)
def setupDetectorFlags(flags, custom_list=None, use_metadata=False, toggle_geometry=False, validate_only=False, keep_beampipe=False)
def setupHistSvcCfg(flags, str outFile, str outStream)
Configuration snippet to setup the THistSvc.