ATLAS Offline Software
ZWindowRoISeedToolConfig.py
Go to the documentation of this file.
1 # Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
2 
3 # Configuration of ZWindowRoISeedTool package
4 from AthenaConfiguration.ComponentFactory import CompFactory
5 from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
6 
7 # Setup per-event calculation of a region-of-interest (RoI) along z-axis
8 def LeadTracksRoISeedToolCfg(flags, **kwargs) :
10 
11  # Set up needed tools
12  if "TrackToVertexTool" not in kwargs:
13  from TrackToVertex.TrackToVertexConfig import InDetTrackToVertexCfg
14  kwargs.setdefault("TrackToVertexTool", acc.popToolsAndMerge(
15  InDetTrackToVertexCfg(flags)))
16 
17  # Set input/output
18  kwargs.setdefault("InputTracksCollection", "ExtendedTracks")
19  kwargs.setdefault("BeamSpotKey", "BeamSpotData")
20 
21  # Set other input properties
22  kwargs.setdefault("TrackZ0Window", flags.Tracking.ActiveConfig.z0WindowRoI)
23 
24  acc.setPrivateTools(CompFactory.InDet.LeadTracksRoISeedTool(
25  "InDetLeadTracksRoISeedTool"+flags.Tracking.ActiveConfig.extension, **kwargs))
26 
27  return acc
28 
29 def RandomRoISeedToolCfg(flags, **kwargs) :
30  acc = ComponentAccumulator()
31 
32  # Set input/output
33  kwargs.setdefault("BeamSpotKey", "BeamSpotData")
34 
35  # Set other input properties
36  kwargs.setdefault("TrackZ0Window", flags.Tracking.ActiveConfig.z0WindowRoI)
37 
38  acc.setPrivateTools(CompFactory.InDet.RandomRoISeedTool(
39  "InDetRandomRoISeedTool"+flags.Tracking.ActiveConfig.extension, **kwargs))
40 
41  return acc
42 
43 def FileRoISeedToolCfg(flags, **kwargs) :
44  acc = ComponentAccumulator()
45 
46  # Set input/output
47  kwargs.setdefault("InputFileName", flags.Tracking.ActiveConfig.inputLowPtRoIfile)
48 
49  # Set other input properties
50  kwargs.setdefault("TrackZ0Window", flags.Tracking.ActiveConfig.z0WindowRoI)
51 
52  acc.setPrivateTools(CompFactory.InDet.FlatRoISeedTool(
53  "InDetFlatRoISeedTool"+flags.Tracking.ActiveConfig.extension, **kwargs))
54 
55  return acc
56 
57 def TruthHSRoISeedToolCfg(flags, **kwargs) :
58  acc = ComponentAccumulator()
59 
60  # Set input/output
61  kwargs.setdefault("InputTruthEventsCollection", "TruthEvents")
62 
63  # Set other input properties
64  kwargs.setdefault("TrackZ0Window", flags.Tracking.ActiveConfig.z0WindowRoI)
65 
66  acc.setPrivateTools(CompFactory.InDet.TruthHSRoISeedTool(
67  "InDetTruthHSRoISeedTool"+flags.Tracking.ActiveConfig.extension, **kwargs))
68 
69  return acc
python.JetAnalysisCommon.ComponentAccumulator
ComponentAccumulator
Definition: JetAnalysisCommon.py:302
python.ZWindowRoISeedToolConfig.RandomRoISeedToolCfg
def RandomRoISeedToolCfg(flags, **kwargs)
Definition: ZWindowRoISeedToolConfig.py:29
python.ZWindowRoISeedToolConfig.TruthHSRoISeedToolCfg
def TruthHSRoISeedToolCfg(flags, **kwargs)
Definition: ZWindowRoISeedToolConfig.py:57
TrackToVertexConfig.InDetTrackToVertexCfg
def InDetTrackToVertexCfg(flags, name='InDetTrackToVertex', **kwargs)
Definition: TrackToVertexConfig.py:14
python.ZWindowRoISeedToolConfig.FileRoISeedToolCfg
def FileRoISeedToolCfg(flags, **kwargs)
Definition: ZWindowRoISeedToolConfig.py:43
python.ZWindowRoISeedToolConfig.LeadTracksRoISeedToolCfg
def LeadTracksRoISeedToolCfg(flags, **kwargs)
Definition: ZWindowRoISeedToolConfig.py:8