ATLAS Offline Software
Functions
python.TGC_OverlayConfig Namespace Reference

Functions

def TGC_DataOverlayExtraCfg (flags, **kwargs)
 
def TGC_OverlayAlgCfg (flags, name="TgcOverlay", **kwargs)
 
def TGC_TruthOverlayCfg (flags, name="TgcTruthOverlay", **kwargs)
 
def TGC_OverlayCfg (flags)
 

Detailed Description

Define methods to construct configured TGC overlay algorithms

Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration

Function Documentation

◆ TGC_DataOverlayExtraCfg()

def python.TGC_OverlayConfig.TGC_DataOverlayExtraCfg (   flags,
**  kwargs 
)
Return a ComponentAccumulator with TGC data overlay specifics

Definition at line 11 of file TGC_OverlayConfig.py.

11 def TGC_DataOverlayExtraCfg(flags, **kwargs):
12  """Return a ComponentAccumulator with TGC data overlay specifics"""
13  acc = ComponentAccumulator()
14 
15  # We need to convert BS to RDO for data overlay
16  from MuonConfig.MuonBytestreamDecodeConfig import TgcBytestreamDecodeCfg
17  acc.merge(TgcBytestreamDecodeCfg(flags))
18 
19  return acc
20 
21 

◆ TGC_OverlayAlgCfg()

def python.TGC_OverlayConfig.TGC_OverlayAlgCfg (   flags,
  name = "TgcOverlay",
**  kwargs 
)
Return a ComponentAccumulator for TGCOverlay algorithm

Definition at line 22 of file TGC_OverlayConfig.py.

22 def TGC_OverlayAlgCfg(flags, name="TgcOverlay", **kwargs):
23  """Return a ComponentAccumulator for TGCOverlay algorithm"""
24  acc = ComponentAccumulator()
25 
26  kwargs.setdefault("BkgInputKey", f"{flags.Overlay.BkgPrefix}TGC_DIGITS")
27  kwargs.setdefault("SignalInputKey", f"{flags.Overlay.SigPrefix}TGC_DIGITS")
28  kwargs.setdefault("OutputKey", "TGC_DIGITS")
29 
30  # Do TGC overlay
31  acc.addEventAlgo(CompFactory.TgcOverlay(name, **kwargs))
32 
33  # Setup output
34  if flags.Output.doWriteRDO:
35  from OutputStreamAthenaPool.OutputStreamConfig import OutputStreamCfg
36  acc.merge(OutputStreamCfg(flags, "RDO", ItemList=[
37  "TgcRdoContainer#TGCRDO"
38  ]))
39 
40  if flags.Output.doWriteRDO_SGNL:
41  from OutputStreamAthenaPool.OutputStreamConfig import OutputStreamCfg
42  acc.merge(OutputStreamCfg(flags, "RDO_SGNL", ItemList=[
43  f"TgcRdoContainer#{flags.Overlay.SigPrefix}TGCRDO"
44  ]))
45 
46  return acc
47 
48 

◆ TGC_OverlayCfg()

def python.TGC_OverlayConfig.TGC_OverlayCfg (   flags)
Configure and return a ComponentAccumulator for TGC overlay

Definition at line 85 of file TGC_OverlayConfig.py.

85 def TGC_OverlayCfg(flags):
86  """Configure and return a ComponentAccumulator for TGC overlay"""
87  acc = ComponentAccumulator()
88 
89  # Add data overlay specifics
90  if flags.Overlay.DataOverlay:
91  acc.merge(TGC_DataOverlayExtraCfg(flags))
92 
93  # Add TGC RDO to digit config
94  from MuonConfig.MuonByteStreamCnvTestConfig import TgcRdoToTgcDigitCfg
95  acc.merge(TgcRdoToTgcDigitCfg(flags))
96  # Add TGC overlay digitization algorithm
97  from MuonConfig.TGC_DigitizationConfig import TGC_OverlayDigitizationBasicCfg
98  acc.merge(TGC_OverlayDigitizationBasicCfg(flags))
99  # Add TGC overlay algorithm
100  acc.merge(TGC_OverlayAlgCfg(flags))
101  # Add TGC truth overlay
102  if flags.Digitization.EnableTruth:
103  if flags.Muon.usePhaseIIGeoSetup:
104  from MuonTruthOverlayR4.TruthOverlayConfig import TruthOverlayCfg
105  acc.merge(TruthOverlayCfg(flags, name="TgcTruthOverlay", WriteKey="TGC_SDO", deadTime = 100.))
106  else:
107  acc.merge(TGC_TruthOverlayCfg(flags))
108  # Add TGC digit to RDO config
109  from MuonConfig.MuonByteStreamCnvTestConfig import TgcDigitToTgcRDOCfg
110  acc.merge(TgcDigitToTgcRDOCfg(flags))
111 
112  return acc

◆ TGC_TruthOverlayCfg()

def python.TGC_OverlayConfig.TGC_TruthOverlayCfg (   flags,
  name = "TgcTruthOverlay",
**  kwargs 
)
Return a ComponentAccumulator for the TGC SDO overlay algorithm

Definition at line 49 of file TGC_OverlayConfig.py.

49 def TGC_TruthOverlayCfg(flags, name="TgcTruthOverlay", **kwargs):
50  """Return a ComponentAccumulator for the TGC SDO overlay algorithm"""
51  acc = ComponentAccumulator()
52 
53  # We do not need background TGC SDOs
54  if flags.Overlay.DataOverlay:
55  kwargs.setdefault("BkgInputKey", "")
56  else:
57  kwargs.setdefault("BkgInputKey", f"{flags.Overlay.BkgPrefix}TGC_SDO")
58 
59  if kwargs["BkgInputKey"]:
60  from SGComps.SGInputLoaderConfig import SGInputLoaderCfg
61  acc.merge(SGInputLoaderCfg(flags, [f'MuonSimDataCollection#{kwargs["BkgInputKey"]}']))
62 
63  kwargs.setdefault("SignalInputKey", f"{flags.Overlay.SigPrefix}TGC_SDO")
64  kwargs.setdefault("OutputKey", "TGC_SDO")
65 
66  # Do TGC truth overlay
67  acc.addEventAlgo(CompFactory.MuonSimDataOverlay(name, **kwargs))
68 
69  # Setup output
70  if flags.Output.doWriteRDO:
71  from OutputStreamAthenaPool.OutputStreamConfig import OutputStreamCfg
72  acc.merge(OutputStreamCfg(flags, "RDO", ItemList=[
73  "MuonSimDataCollection#TGC_SDO"
74  ]))
75 
76  if flags.Output.doWriteRDO_SGNL:
77  from OutputStreamAthenaPool.OutputStreamConfig import OutputStreamCfg
78  acc.merge(OutputStreamCfg(flags, "RDO_SGNL", ItemList=[
79  f"MuonSimDataCollection#{flags.Overlay.SigPrefix}TGC_SDO"
80  ]))
81 
82  return acc
83 
84 
python.JetAnalysisCommon.ComponentAccumulator
ComponentAccumulator
Definition: JetAnalysisCommon.py:302
python.TGC_OverlayConfig.TGC_TruthOverlayCfg
def TGC_TruthOverlayCfg(flags, name="TgcTruthOverlay", **kwargs)
Definition: TGC_OverlayConfig.py:49
python.OutputStreamConfig.OutputStreamCfg
def OutputStreamCfg(flags, streamName, ItemList=[], MetadataItemList=[], disableEventTag=False, trigNavThinningSvc=None, takeItemsFromInput=False, extendProvenanceRecord=True, AcceptAlgs=[], HelperTools=[])
Definition: OutputStreamConfig.py:12
python.TGC_OverlayConfig.TGC_OverlayAlgCfg
def TGC_OverlayAlgCfg(flags, name="TgcOverlay", **kwargs)
Definition: TGC_OverlayConfig.py:22
python.TGC_OverlayConfig.TGC_OverlayCfg
def TGC_OverlayCfg(flags)
Definition: TGC_OverlayConfig.py:85
python.TGC_OverlayConfig.TGC_DataOverlayExtraCfg
def TGC_DataOverlayExtraCfg(flags, **kwargs)
Definition: TGC_OverlayConfig.py:11
TruthOverlayConfig.TruthOverlayCfg
def TruthOverlayCfg(flags, name="TruthOverlay", **kwargs)
Definition: TruthOverlayConfig.py:3
SGInputLoaderConfig.SGInputLoaderCfg
def SGInputLoaderCfg(flags, Load=None, **kwargs)
Definition: SGInputLoaderConfig.py:7
python.TGC_DigitizationConfig.TGC_OverlayDigitizationBasicCfg
def TGC_OverlayDigitizationBasicCfg(flags, **kwargs)
Definition: TGC_DigitizationConfig.py:124
python.MuonByteStreamCnvTestConfig.TgcRdoToTgcDigitCfg
def TgcRdoToTgcDigitCfg(flags, name="TgcRdoToTgcDigitAlg", **kwargs)
Definition: MuonByteStreamCnvTestConfig.py:82
python.MuonBytestreamDecodeConfig.TgcBytestreamDecodeCfg
def TgcBytestreamDecodeCfg(flags, name="TgcRawDataProvider", **kwargs)
Definition: MuonBytestreamDecodeConfig.py:97
python.MuonByteStreamCnvTestConfig.TgcDigitToTgcRDOCfg
def TgcDigitToTgcRDOCfg(flags, name="TgcDigitToTgcRDO", **kwargs)
Definition: MuonByteStreamCnvTestConfig.py:197