ATLAS Offline Software
Loading...
Searching...
No Matches
PLR_SiPropertiesConfig.py
Go to the documentation of this file.
1"""Define methods to configure SiPropertiesTool for PLR
2
3Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
4"""
5from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
6from AthenaConfiguration.ComponentFactory import CompFactory
7
8from PixelConditionsAlgorithms.PLR_ConditionsConfig import (
9 PLR_DCSCondHVAlgCfg, PLR_DCSCondTempAlgCfg
10)
11
12
13def PLR_SiPropertiesCondAlgCfg(flags, name="PLR_SiPropertiesCondAlg", **kwargs):
14 """Return configured ComponentAccumulator and tool for PLR_SiPropertiesCondAlg
15
16 SiPropertiesTool may be provided in kwargs
17 """
18 acc = ComponentAccumulator()
19 acc.merge(PLR_DCSCondHVAlgCfg(flags))
20 acc.merge(PLR_DCSCondTempAlgCfg(flags))
21 kwargs.setdefault("PixelIDName", "PLR_ID")
22 kwargs.setdefault("PixelDetEleCollKey", "PLR_DetectorElementCollection")
23 kwargs.setdefault("ReadKeyeTemp", "PLR_DCSTempCondData")
24 kwargs.setdefault("ReadKeyHV", "PLR_DCSHVCondData")
25 kwargs.setdefault("WriteKey", "PLR_SiliconPropertiesVector")
26 acc.addCondAlgo(CompFactory.PixelSiPropertiesCondAlg(name, **kwargs))
27 return acc
28
29
30def PLR_SiPropertiesToolCfg(flags, name="PLR_SiPropertiesTool", **kwargs):
31 """Return a SiPropertiesTool configured for PLR"""
32 acc = PLR_SiPropertiesCondAlgCfg(flags)
33 kwargs.setdefault("DetectorName", "PLR")
34 kwargs.setdefault("ReadKey", "PLR_SiliconPropertiesVector")
35 acc.setPrivateTools(CompFactory.SiPropertiesTool(name, **kwargs))
36 return acc
PLR_SiPropertiesCondAlgCfg(flags, name="PLR_SiPropertiesCondAlg", **kwargs)
PLR_SiPropertiesToolCfg(flags, name="PLR_SiPropertiesTool", **kwargs)