ATLAS Offline Software
PixelGeoModelConfig.py
Go to the documentation of this file.
1 # Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
2 from AthenaConfiguration.AccumulatorCache import AccumulatorCache
3 
4 
5 def PixelGeoModelCfg(flags):
6  from AtlasGeoModel.GeometryDBConfig import InDetGeometryDBSvcCfg
7  db = InDetGeometryDBSvcCfg(flags)
8 
9  from AtlasGeoModel.GeoModelConfig import GeoModelCfg
10  acc = GeoModelCfg(flags)
11  geoModelSvc = acc.getPrimary()
12 
13  from AthenaConfiguration.ComponentFactory import CompFactory
14  pixelDetectorTool = CompFactory.PixelDetectorTool("PixelDetectorTool")
15  pixelDetectorTool.GeometryDBSvc = db.getPrimary()
16  pixelDetectorTool.BCM_Tool = CompFactory.InDetDD.BCM_Builder()
17  pixelDetectorTool.BLM_Tool = CompFactory.InDetDD.BLM_Builder()
18  pixelDetectorTool.useDynamicAlignFolders = flags.GeoModel.Align.Dynamic
19  geoModelSvc.DetectorTools += [ pixelDetectorTool ]
20  acc.merge(db)
21  return acc
22 
23 
24 def PixelAlignmentCfg(flags):
25  from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
26  acc = ComponentAccumulator()
27  if flags.GeoModel.Align.LegacyConditionsAccess: # revert to old style CondHandle in case of simulation
28  from IOVDbSvc.IOVDbSvcConfig import addFoldersSplitOnline
29  if flags.GeoModel.Align.Dynamic:
30  acc.merge(addFoldersSplitOnline(flags, "INDET",
31  ["/Indet/Onl/AlignL1/ID", "/Indet/Onl/AlignL2/PIX"],
32  ["/Indet/AlignL1/ID", "/Indet/AlignL2/PIX"]))
33  acc.merge(addFoldersSplitOnline(flags, "INDET", "/Indet/Onl/AlignL3", "/Indet/AlignL3"))
34  else:
35  acc.merge(addFoldersSplitOnline(flags, "INDET", "/Indet/Onl/Align", "/Indet/Align"))
36  acc.merge(addFoldersSplitOnline(flags, "INDET", "/Indet/Onl/IBLDist", "/Indet/IBLDist"))
37  else:
38  from PixelConditionsAlgorithms.PixelConditionsConfig import PixelAlignCondAlgCfg
39  acc.merge(PixelAlignCondAlgCfg(flags))
40  return acc
41 
42 
43 @AccumulatorCache
45  # main GeoModel config
46  acc = PixelGeoModelCfg(flags)
47  acc.merge(PixelAlignmentCfg(flags))
48  return acc
49 
50 
51 @AccumulatorCache
53  # main GeoModel config
54  acc = PixelGeoModelCfg(flags)
55  acc.merge(PixelAlignmentCfg(flags))
56  from PixelConditionsAlgorithms.PixelConditionsConfig import PixelDetectorElementCondAlgCfg
57  acc.merge(PixelDetectorElementCondAlgCfg(flags))
58  return acc
PixelConditionsConfig.PixelAlignCondAlgCfg
def PixelAlignCondAlgCfg(flags, name="PixelAlignCondAlg", **kwargs)
Definition: PixelConditionsConfig.py:82
python.JetAnalysisCommon.ComponentAccumulator
ComponentAccumulator
Definition: JetAnalysisCommon.py:302
python.GeometryDBConfig.InDetGeometryDBSvcCfg
def InDetGeometryDBSvcCfg(flags)
Definition: GeometryDBConfig.py:7
PixelGeoModelConfig.PixelAlignmentCfg
def PixelAlignmentCfg(flags)
Definition: PixelGeoModelConfig.py:24
PixelGeoModelConfig.PixelSimulationGeometryCfg
def PixelSimulationGeometryCfg(flags)
Definition: PixelGeoModelConfig.py:44
PixelGeoModelConfig.PixelGeoModelCfg
def PixelGeoModelCfg(flags)
Definition: PixelGeoModelConfig.py:5
PixelConditionsConfig.PixelDetectorElementCondAlgCfg
def PixelDetectorElementCondAlgCfg(flags, name="PixelDetectorElementCondAlg", **kwargs)
Definition: PixelConditionsConfig.py:228
PixelGeoModelConfig.PixelReadoutGeometryCfg
def PixelReadoutGeometryCfg(flags)
Definition: PixelGeoModelConfig.py:52
python.IOVDbSvcConfig.addFoldersSplitOnline
def addFoldersSplitOnline(flags, detDb, onlineFolders, offlineFolders, className=None, extensible=False, addMCString='_OFL', splitMC=False, tag=None, forceDb=None, modifiers='')
Definition: IOVDbSvcConfig.py:153
python.GeoModelConfig.GeoModelCfg
def GeoModelCfg(flags)
Definition: GeoModelConfig.py:16