ATLAS Offline Software
Functions
PLR_OverlayConfig Namespace Reference

Functions

def PLR_OverlayAlgCfg (flags, name="PLR_Overlay", **kwargs)
 
def PLR_TruthOverlayCfg (flags, name="PLR_SDOOverlay", **kwargs)
 
def PLR_OverlayCfg (flags)
 

Detailed Description

Define methods to construct configured PLR overlay algorithms

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

Function Documentation

◆ PLR_OverlayAlgCfg()

def PLR_OverlayConfig.PLR_OverlayAlgCfg (   flags,
  name = "PLR_Overlay",
**  kwargs 
)
Return a ComponentAccumulator for PLR Overlay algorithm

Definition at line 10 of file PLR_OverlayConfig.py.

10 def PLR_OverlayAlgCfg(flags, name="PLR_Overlay", **kwargs):
11  """Return a ComponentAccumulator for PLR Overlay algorithm"""
12  acc = ComponentAccumulator()
13 
14  kwargs.setdefault("BkgInputKey", f"{flags.Overlay.BkgPrefix}PLR_RDOs")
15  kwargs.setdefault("SignalInputKey", f"{flags.Overlay.SigPrefix}PLR_RDOs")
16  kwargs.setdefault("OutputKey", "PLR_RDOs")
17 
18  # Input setup
19  if flags.Overlay.ByteStream:
20  pass
21  else:
22  from SGComps.SGInputLoaderConfig import SGInputLoaderCfg
23  acc.merge(SGInputLoaderCfg(flags, [f'PixelRDO_Container#{kwargs["BkgInputKey"]}']))
24 
25  # Do PLR overlay
26  acc.addEventAlgo(CompFactory.PixelOverlay(name, **kwargs))
27 
28  # Setup output
29  if flags.Output.doWriteRDO:
30  from OutputStreamAthenaPool.OutputStreamConfig import OutputStreamCfg
31  acc.merge(OutputStreamCfg(flags, "RDO", ItemList=[
32  "PixelRDO_Container#PLR_RDOs"
33  ]))
34 
35  if not flags.Input.isMC:
36  acc.merge(OutputStreamCfg(flags, "RDO", ItemList=[
37  "IDCInDetBSErrContainer#PLR_ByteStreamErrs"
38  ]))
39 
40  if flags.Output.doWriteRDO_SGNL:
41  from OutputStreamAthenaPool.OutputStreamConfig import OutputStreamCfg
42  acc.merge(OutputStreamCfg(flags, "RDO_SGNL", ItemList=[
43  f"PixelRDO_Container#{flags.Overlay.SigPrefix}PLR_RDOs"
44  ]))
45 
46  return acc
47 
48 

◆ PLR_OverlayCfg()

def PLR_OverlayConfig.PLR_OverlayCfg (   flags)
Configure and return a ComponentAccumulator for PLR overlay

Definition at line 78 of file PLR_OverlayConfig.py.

78 def PLR_OverlayCfg(flags):
79  """Configure and return a ComponentAccumulator for PLR overlay"""
80  acc = ComponentAccumulator()
81 
82  # Add PLR overlay digitization algorithm
83  from PixelDigitization.PLR_DigitizationConfig import PLR_OverlayDigitizationBasicCfg
84  acc.merge(PLR_OverlayDigitizationBasicCfg(flags))
85 
86  # Add PLR overlay algorithm
87  acc.merge(PLR_OverlayAlgCfg(flags))
88 
89  # Add PLR truth overlay
90  if flags.Digitization.EnableTruth:
91  acc.merge(PLR_TruthOverlayCfg(flags))
92 
93  return acc

◆ PLR_TruthOverlayCfg()

def PLR_OverlayConfig.PLR_TruthOverlayCfg (   flags,
  name = "PLR_SDOOverlay",
**  kwargs 
)
Return a ComponentAccumulator for the PLR SDO overlay algorithm

Definition at line 49 of file PLR_OverlayConfig.py.

49 def PLR_TruthOverlayCfg(flags, name="PLR_SDOOverlay", **kwargs):
50  """Return a ComponentAccumulator for the PLR SDO overlay algorithm"""
51  acc = ComponentAccumulator()
52 
53  # We do not need background PLR SDOs
54  kwargs.setdefault("BkgInputKey", "")
55 
56  kwargs.setdefault("SignalInputKey", f"{flags.Overlay.SigPrefix}PLR_SDO_Map")
57  kwargs.setdefault("OutputKey", "PLR_SDO_Map")
58 
59  # Do PLR truth overlay
60  acc.addEventAlgo(CompFactory.InDetSDOOverlay(name, **kwargs))
61 
62  # Setup output
63  if flags.Output.doWriteRDO:
64  from OutputStreamAthenaPool.OutputStreamConfig import OutputStreamCfg
65  acc.merge(OutputStreamCfg(flags, "RDO", ItemList=[
66  "InDetSimDataCollection#PLR_SDO_Map"
67  ]))
68 
69  if flags.Output.doWriteRDO_SGNL:
70  from OutputStreamAthenaPool.OutputStreamConfig import OutputStreamCfg
71  acc.merge(OutputStreamCfg(flags, "RDO_SGNL", ItemList=[
72  f"InDetSimDataCollection#{flags.Overlay.SigPrefix}PLR_SDO_Map"
73  ]))
74 
75  return acc
76 
77 
python.JetAnalysisCommon.ComponentAccumulator
ComponentAccumulator
Definition: JetAnalysisCommon.py:302
python.OutputStreamConfig.OutputStreamCfg
def OutputStreamCfg(flags, streamName, ItemList=[], MetadataItemList=[], disableEventTag=False, trigNavThinningSvc=None, takeItemsFromInput=False, extendProvenanceRecord=True, AcceptAlgs=[], HelperTools=[])
Definition: OutputStreamConfig.py:12
SGInputLoaderConfig.SGInputLoaderCfg
def SGInputLoaderCfg(flags, Load=None, **kwargs)
Definition: SGInputLoaderConfig.py:7
PLR_DigitizationConfig.PLR_OverlayDigitizationBasicCfg
def PLR_OverlayDigitizationBasicCfg(flags, **kwargs)
Definition: PLR_DigitizationConfig.py:224
PLR_OverlayConfig.PLR_TruthOverlayCfg
def PLR_TruthOverlayCfg(flags, name="PLR_SDOOverlay", **kwargs)
Definition: PLR_OverlayConfig.py:49
PLR_OverlayConfig.PLR_OverlayCfg
def PLR_OverlayCfg(flags)
Definition: PLR_OverlayConfig.py:78
PLR_OverlayConfig.PLR_OverlayAlgCfg
def PLR_OverlayAlgCfg(flags, name="PLR_Overlay", **kwargs)
Definition: PLR_OverlayConfig.py:10