ATLAS Offline Software
InDetTestPixelLayerConfig.py
Go to the documentation of this file.
1 # Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
2 # Configuration of InDetTestPixelLayer package
3 from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
4 from AthenaConfiguration.ComponentFactory import CompFactory
5 
6 
7 def InDetTestPixelLayerToolCfg(flags, name="InDetTestPixelLayerTool", **kwargs):
8  if flags.Detector.GeometryITk:
9  name = name.replace("InDet", "ITk")
10  return ITkTestPixelLayerToolCfg(flags, name, **kwargs)
11 
12  result = ComponentAccumulator()
13 
14  if 'PixelSummaryTool' not in kwargs:
15  from PixelConditionsTools.PixelConditionsSummaryConfig import (
16  PixelConditionsSummaryCfg)
17  kwargs.setdefault("PixelSummaryTool", result.popToolsAndMerge(
19 
20  if "PixelDetElStatus" not in kwargs and not flags.Common.isOnline:
21  from PixelReadoutGeometry.PixelReadoutGeometryConfig import (
22  PixelReadoutManagerCfg)
23  result.merge(PixelReadoutManagerCfg(flags))
24  from PixelConditionsAlgorithms.PixelConditionsConfig import (
25  PixelDetectorElementStatusAlgCfg)
26  result.merge(PixelDetectorElementStatusAlgCfg(flags))
27  kwargs.setdefault("PixelDetElStatus", "PixelDetectorElementStatus")
28 
29  if 'Extrapolator' not in kwargs:
30  from TrkConfig.AtlasExtrapolatorConfig import InDetExtrapolatorCfg
31  kwargs.setdefault("Extrapolator", result.popToolsAndMerge(
32  InDetExtrapolatorCfg(flags)))
33 
34  kwargs.setdefault("CheckActiveAreas", flags.InDet.checkDeadElementsOnTrack)
35  kwargs.setdefault("CheckDeadRegions", flags.InDet.checkDeadElementsOnTrack)
36  kwargs.setdefault("CheckDisabledFEs", flags.InDet.checkDeadElementsOnTrack)
37 
38  result.setPrivateTools(
39  CompFactory.InDet.InDetTestPixelLayerTool(name, **kwargs))
40  return result
41 
42 
44  flags, name="InDetTestPixelLayerToolInner", **kwargs):
45  if flags.Detector.GeometryITk:
46  name = name.replace("InDet", "ITk")
47  return ITkTestPixelLayerToolInnerCfg(flags, name, **kwargs)
48 
49  kwargs.setdefault("CheckActiveAreas", False)
50  kwargs.setdefault("CheckDeadRegions", False)
51  kwargs.setdefault("CheckDisabledFEs", False)
52  # To allow for extrapolation up to B-layer = next-to-innermost
53  kwargs.setdefault("OuterRadius", 100.)
54  return InDetTestPixelLayerToolCfg(flags, name, **kwargs)
55 
56 
58  flags, name="CombinedMuonPixelLayerToolDefault", **kwargs):
59  result = ComponentAccumulator()
60 
61  if 'Extrapolator' not in kwargs:
62  from TrkConfig.AtlasExtrapolatorConfig import AtlasExtrapolatorCfg
63  kwargs.setdefault("Extrapolator", result.popToolsAndMerge(
64  AtlasExtrapolatorCfg(flags)))
65 
66  result.setPrivateTools(result.popToolsAndMerge(
67  InDetTestPixelLayerToolCfg(flags, name, **kwargs)))
68  return result
69 
70 
72  flags, name="InDetTrigTestPixelLayerTool", **kwargs):
73  kwargs.setdefault("CheckActiveAreas", True)
74  kwargs.setdefault("CheckDeadRegions", True)
75  kwargs.setdefault("PixelDetElStatus", "")
76  return InDetTestPixelLayerToolCfg(flags, name, **kwargs)
77 
78 
80  flags, name="InDetTrigTestPixelLayerToolInner", **kwargs):
81  kwargs.setdefault("CheckActiveAreas", True)
82  kwargs.setdefault("PixelDetElStatus", "")
83  return InDetTestPixelLayerToolInnerCfg(flags, name, **kwargs)
84 
85 
87  flags, name="CombinedMuonPixelLayerToolDefault", **kwargs):
88  result = ComponentAccumulator()
89 
90  if 'Extrapolator' not in kwargs:
91  from TrkConfig.AtlasExtrapolatorConfig import AtlasExtrapolatorCfg
92  kwargs.setdefault("Extrapolator", result.popToolsAndMerge(
93  AtlasExtrapolatorCfg(flags)))
94 
95  result.setPrivateTools(result.popToolsAndMerge(
96  InDetTrigTestPixelLayerToolCfg(flags, name, **kwargs)))
97  return result
98 
99 
100 def ITkTestPixelLayerToolCfg(flags, name="ITkTestPixelLayerTool", **kwargs):
101  result = ComponentAccumulator()
102  if 'PixelSummaryTool' not in kwargs:
103  from PixelConditionsTools.ITkPixelConditionsSummaryConfig import (
104  ITkPixelConditionsSummaryCfg)
105  kwargs.setdefault("PixelSummaryTool", result.popToolsAndMerge(
107 
108  if 'Extrapolator' not in kwargs:
109  from TrkConfig.AtlasExtrapolatorConfig import AtlasExtrapolatorCfg
110  kwargs.setdefault("Extrapolator", result.popToolsAndMerge(
111  AtlasExtrapolatorCfg(flags)))
112 
113  kwargs.setdefault("CheckActiveAreas", flags.ITk.checkDeadPixelsOnTrack)
114  kwargs.setdefault("CheckDeadRegions", flags.ITk.checkDeadPixelsOnTrack)
115  kwargs.setdefault("CheckDisabledFEs", flags.ITk.checkDeadPixelsOnTrack)
116  # Outer pixel detector radius, to allow for extrapolation up to outermost
117  # layer if needed
118  kwargs.setdefault("OuterRadius", 350.)
119 
120  result.setPrivateTools(
121  CompFactory.InDet.InDetTestPixelLayerTool(name, **kwargs))
122  return result
123 
124 
126  flags, name="ITkTestPixelLayerInnerTool", **kwargs):
127  kwargs.setdefault("CheckActiveAreas", False)
128  kwargs.setdefault("CheckDeadRegions", False)
129  kwargs.setdefault("CheckDisabledFEs", False)
130  # To allow for extrapolation up to next-to-innermost layer
131  kwargs.setdefault("OuterRadius", 130.)
132  return ITkTestPixelLayerToolCfg(flags, name, **kwargs)
python.JetAnalysisCommon.ComponentAccumulator
ComponentAccumulator
Definition: JetAnalysisCommon.py:302
python.InDetTestPixelLayerConfig.InDetTrigTestPixelLayerToolCfg
def InDetTrigTestPixelLayerToolCfg(flags, name="InDetTrigTestPixelLayerTool", **kwargs)
Definition: InDetTestPixelLayerConfig.py:71
PixelConditionsSummaryConfig.PixelConditionsSummaryCfg
def PixelConditionsSummaryCfg(flags, name="PixelConditionsSummary", **kwargs)
Definition: PixelConditionsSummaryConfig.py:17
python.InDetTestPixelLayerConfig.InDetTestPixelLayerToolCfg
def InDetTestPixelLayerToolCfg(flags, name="InDetTestPixelLayerTool", **kwargs)
Definition: InDetTestPixelLayerConfig.py:7
ITkPixelConditionsSummaryConfig.ITkPixelConditionsSummaryCfg
def ITkPixelConditionsSummaryCfg(flags, name="ITkPixelConditionsSummary", **kwargs)
Definition: ITkPixelConditionsSummaryConfig.py:12
python.InDetTestPixelLayerConfig.ITkTestPixelLayerToolInnerCfg
def ITkTestPixelLayerToolInnerCfg(flags, name="ITkTestPixelLayerInnerTool", **kwargs)
Definition: InDetTestPixelLayerConfig.py:125
python.AtlasExtrapolatorConfig.AtlasExtrapolatorCfg
def AtlasExtrapolatorCfg(flags, name='AtlasExtrapolator')
Definition: AtlasExtrapolatorConfig.py:63
python.InDetTestPixelLayerConfig.CombinedMuonTrigPixelLayerToolCfg
def CombinedMuonTrigPixelLayerToolCfg(flags, name="CombinedMuonPixelLayerToolDefault", **kwargs)
Definition: InDetTestPixelLayerConfig.py:86
python.InDetTestPixelLayerConfig.InDetTestPixelLayerToolInnerCfg
def InDetTestPixelLayerToolInnerCfg(flags, name="InDetTestPixelLayerToolInner", **kwargs)
Definition: InDetTestPixelLayerConfig.py:43
PixelConditionsConfig.PixelDetectorElementStatusAlgCfg
def PixelDetectorElementStatusAlgCfg(flags, name="PixelDetectorElementStatusAlg", **kwargs)
Definition: PixelConditionsConfig.py:367
python.InDetTestPixelLayerConfig.ITkTestPixelLayerToolCfg
def ITkTestPixelLayerToolCfg(flags, name="ITkTestPixelLayerTool", **kwargs)
Definition: InDetTestPixelLayerConfig.py:100
python.InDetTestPixelLayerConfig.CombinedMuonPixelLayerToolCfg
def CombinedMuonPixelLayerToolCfg(flags, name="CombinedMuonPixelLayerToolDefault", **kwargs)
Definition: InDetTestPixelLayerConfig.py:57
python.AtlasExtrapolatorConfig.InDetExtrapolatorCfg
def InDetExtrapolatorCfg(flags, name='InDetExtrapolator', **kwargs)
Definition: AtlasExtrapolatorConfig.py:315
python.PixelReadoutGeometryConfig.PixelReadoutManagerCfg
def PixelReadoutManagerCfg(flags, name="PixelReadoutManager", **kwargs)
Definition: PixelReadoutGeometryConfig.py:6
python.InDetTestPixelLayerConfig.InDetTrigTestPixelLayerToolInnerCfg
def InDetTrigTestPixelLayerToolInnerCfg(flags, name="InDetTrigTestPixelLayerToolInner", **kwargs)
Definition: InDetTestPixelLayerConfig.py:79