ATLAS Offline Software
Functions | Variables
JetRecToolsConfig Namespace Reference

Functions

def getIDTrackSelectionTool (toolname, **toolProps)
 
def getTrackSelAlg (jetdef, trackSelOpt=False, DecorDeps=None)
 
def getJetTrackVtxAlg (trkProperties, algname="jetTVA", **ttva_overide)
 
def getPFlowSelAlg ()
 

Variables

 jrtlog = Logging.logging.getLogger('JetRecToolsConfig')
 

Function Documentation

◆ getIDTrackSelectionTool()

def JetRecToolsConfig.getIDTrackSelectionTool (   toolname,
**  toolProps 
)
returns a InDetTrackSelectionTool configured with toolProps
 (except in Analysis releases where some un-used (?) options are explicitely turned off)

Definition at line 19 of file JetRecToolsConfig.py.

19 def getIDTrackSelectionTool(toolname, **toolProps):
20  """returns a InDetTrackSelectionTool configured with toolProps
21  (except in Analysis releases where some un-used (?) options are explicitely turned off)
22  """
23  idtracksel = CompFactory.getComp("InDet::InDetTrackSelectionTool")(toolname, **toolProps)
24 
25  if not isAnalysisRelease():
26  # thes options can not be set in AnalysisBase/AthAnalysis. (but not setting them is equivalent to set them to False)
27  idtracksel.UseTrkTrackTools = False
28  idtracksel.Extrapolator = ""
29  idtracksel.TrackSummaryTool = ""
30  return idtracksel
31 

◆ getJetTrackVtxAlg()

def JetRecToolsConfig.getJetTrackVtxAlg (   trkProperties,
  algname = "jetTVA",
**  ttva_overide 
)
theSequence and ttva_overide are options used in trigger  (HLT/Jet/JetTrackingConfig.py)

Definition at line 59 of file JetRecToolsConfig.py.

59 def getJetTrackVtxAlg( trkProperties, algname="jetTVA", **ttva_overide):
60  """ theSequence and ttva_overide are options used in trigger (HLT/Jet/JetTrackingConfig.py)"""
61  from TrackVertexAssociationTool.TrackVertexAssociationToolConfig import getTTVAToolForReco
62 
63  ttva_options = dict(
64  TrackContName = trkProperties["Tracks"],
65  HardScatterLinkDeco = ""
66  )
67  # allow client to overide options :
68  ttva_options.update(**ttva_overide)
69 
70  idtvassoc = getTTVAToolForReco( "jetTVatool", **ttva_options )
71 
72  alg = CompFactory.JetTrackVtxAssoAlg(algname,
73  TrackParticleContainer = trkProperties["Tracks"],
74  TrackVertexAssociation = trkProperties["TVA"],
75  VertexContainer = trkProperties["Vertices"],
76  TrackVertexAssoTool = idtvassoc
77  )
78  return alg
79 
80 

◆ getPFlowSelAlg()

def JetRecToolsConfig.getPFlowSelAlg ( )

Definition at line 81 of file JetRecToolsConfig.py.

81 def getPFlowSelAlg():
82  # PFlow objects matched to electrons/muons filtering algorithm
83  return CompFactory.JetPFlowSelectionAlg( "pflowselalg",
84  electronID = "LHMedium",
85  ChargedPFlowInputContainer = "JetETMissChargedParticleFlowObjects",
86  NeutralPFlowInputContainer = "JetETMissNeutralParticleFlowObjects",
87  ChargedPFlowOutputContainer = "GlobalPFlowChargedParticleFlowObjects",
88  NeutralPFlowOutputContainer = "GlobalPFlowNeutralParticleFlowObjects"
89  )

◆ getTrackSelAlg()

def JetRecToolsConfig.getTrackSelAlg (   jetdef,
  trackSelOpt = False,
  DecorDeps = None 
)

Definition at line 32 of file JetRecToolsConfig.py.

32 def getTrackSelAlg(jetdef, trackSelOpt=False, DecorDeps=None):
33  if not DecorDeps:
34  DecorDeps = ["TTVA_AMVFWeights_forReco", "TTVA_AMVFVertices_forReco"]
35  trkProperties = jetdef._contextDic
36  trkOpt=jetdef.context
37 
38  trackToolProps = dict(**trkProperties["trackSelOptions"])
39 
40  if not trackSelOpt:
41  # track selection from trkOpt but OVERWRITING the CutLevel for e.g. ghosts (typically, only a pt>500MeV cut remains):
42  trackToolProps.update( CutLevel=trkProperties['GhostTrackCutLevel'] )
43  outContainerKey = "JetTracks"
44  trkOpt= trkOpt+'ghost' # just so it gives a different tool name below
45  else:
46  outContainerKey = "JetTracksQualityCuts"
47 
48  # build the selection alg
49  trkSelAlg = CompFactory.JetTrackSelectionAlg( f"trackselalg_{trkOpt}_{trkProperties[outContainerKey]}",
50  TrackSelector = getIDTrackSelectionTool(f"tracksel{trkOpt}",**trackToolProps),
51  InputContainer = trkProperties["Tracks"],
52  OutputContainer = trkProperties[outContainerKey],
53  DecorDeps = DecorDeps # Hardcoded for now... we might want to have this context-dependent ??
54  )
55 
56  return trkSelAlg
57 
58 

Variable Documentation

◆ jrtlog

JetRecToolsConfig.jrtlog = Logging.logging.getLogger('JetRecToolsConfig')

Definition at line 12 of file JetRecToolsConfig.py.

JetRecToolsConfig.getTrackSelAlg
def getTrackSelAlg(jetdef, trackSelOpt=False, DecorDeps=None)
Definition: JetRecToolsConfig.py:32
JetRecToolsConfig.getPFlowSelAlg
def getPFlowSelAlg()
Definition: JetRecToolsConfig.py:81
JetRecToolsConfig.getJetTrackVtxAlg
def getJetTrackVtxAlg(trkProperties, algname="jetTVA", **ttva_overide)
Definition: JetRecToolsConfig.py:59
ParticleJetToolsConfig.isAnalysisRelease
def isAnalysisRelease()
Definition: ParticleJetToolsConfig.py:19
TrackVertexAssociationToolConfig.getTTVAToolForReco
def getTTVAToolForReco(name="TTVATool", **kwargs)
Definition: TrackVertexAssociationToolConfig.py:6
JetRecToolsConfig.getIDTrackSelectionTool
def getIDTrackSelectionTool(toolname, **toolProps)
Definition: JetRecToolsConfig.py:19