ATLAS Offline Software
InDetImprovedJetFitterVxFinderConfig.py
Go to the documentation of this file.
1 # Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
2 
3 from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
4 from AthenaConfiguration.ComponentFactory import CompFactory
5 
6 from BTagging.JetFitterMultiStageFitConfig import InDetJetFitterMultiStageFitCfg
7 from BTagging.JetFitterTrackSelectorToolConfig import InDetJetFitterTrackSelectorToolCfg
8 from BTagging.JetFitterTwoTrackVtxFinderToolConfig import InDetJetFitterTwoTrackVtxFinderToolCfg
9 from BTagging.JetFitterV0FinderToolConfig import JetFitterV0FinderToolCfg
10 
11 def InDetImprovedJetFitterVxFinderCfg(flags, name, suffix = "", useBTagFlagsDefaults = True, **options):
12  """Sets up a InDetJetFitterTrackSelectorTool tool and returns it.
13 
14  The following options have BTaggingFlags defaults:
15 
16  input: name: The name of the tool (should be unique).
17  useBTagFlagsDefaults : Whether to use BTaggingFlags defaults for options that are not specified.
18  **options: Python dictionary with options for the tool.
19  output: The actual tool, which can then by added to ToolSvc via ToolSvc += output."""
20  acc = ComponentAccumulator()
21  if useBTagFlagsDefaults:
22  InDetJetFitterMultiStageFit = acc.popToolsAndMerge( InDetJetFitterMultiStageFitCfg(flags,"JetFitterMultiStageFit"+suffix,suffix) )
23  InDetJetFitterTrackSelectorTool = acc.popToolsAndMerge( InDetJetFitterTrackSelectorToolCfg(flags,"JetFitterTrackSelectorTool"+suffix,suffix) )
24  InDetJetFitterTwoTrackVtxFinderTool = acc.popToolsAndMerge( InDetJetFitterTwoTrackVtxFinderToolCfg(flags, "InDetJetFitterTwoTrackVtxFinderTool"+suffix,suffix) )
25  InDetJetFitterV0FinderTool = acc.popToolsAndMerge( JetFitterV0FinderToolCfg(flags,"JetFitterV0FinderTool"+suffix,suffix) )
26  defaults = { 'JetFitterTrackSelectorTool' : InDetJetFitterTrackSelectorTool ,
27  'JetFitterTwoTrackVtxFinderTool' : InDetJetFitterTwoTrackVtxFinderTool ,
28  'JetFitterV0FinderTool' : InDetJetFitterV0FinderTool ,
29  'JetFitterMultiStageFit' : InDetJetFitterMultiStageFit }
30  for option in defaults:
31  options.setdefault(option, defaults[option])
32 
33  options['name'] = name
34  acc.setPrivateTools( CompFactory.InDet.InDetImprovedJetFitterVxFinder(**options) )
35  return acc
python.InDetImprovedJetFitterVxFinderConfig.InDetImprovedJetFitterVxFinderCfg
def InDetImprovedJetFitterVxFinderCfg(flags, name, suffix="", useBTagFlagsDefaults=True, **options)
Definition: InDetImprovedJetFitterVxFinderConfig.py:11
python.JetAnalysisCommon.ComponentAccumulator
ComponentAccumulator
Definition: JetAnalysisCommon.py:302
python.JetFitterTrackSelectorToolConfig.InDetJetFitterTrackSelectorToolCfg
def InDetJetFitterTrackSelectorToolCfg(flags, name, suffix="", useBTagFlagsDefaults=True, **options)
Definition: JetFitterTrackSelectorToolConfig.py:10
python.JetFitterV0FinderToolConfig.JetFitterV0FinderToolCfg
def JetFitterV0FinderToolCfg(flags, name, suffix="", useBTagFlagsDefaults=True, **options)
Definition: JetFitterV0FinderToolConfig.py:11
python.JetFitterMultiStageFitConfig.InDetJetFitterMultiStageFitCfg
def InDetJetFitterMultiStageFitCfg(flags, name, suffix="", useBTagFlagsDefaults=True, **options)
Definition: JetFitterMultiStageFitConfig.py:10
python.JetFitterTwoTrackVtxFinderToolConfig.InDetJetFitterTwoTrackVtxFinderToolCfg
def InDetJetFitterTwoTrackVtxFinderToolCfg(flags, name, suffix="", useBTagFlagsDefaults=True, **options)
Definition: JetFitterTwoTrackVtxFinderToolConfig.py:8