1 """Define methods to configure ITkStripLorentzAngleTool
3 Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
5 from AthenaConfiguration.ComponentFactory
import CompFactory
6 from MagFieldServices.MagFieldServicesConfig
import AtlasFieldCacheCondAlgCfg
7 from SCT_ConditionsTools.ITkStripConditionsToolsConfig
import ITkStripSiliconConditionsCfg
8 from StripGeoModelXml.ITkStripGeoModelConfig
import ITkStripReadoutGeometryCfg
11 """Return a SiLorentzAngleTool configured for ITk Strip"""
14 kwargs.setdefault(
"DetectorName",
"SCT")
15 kwargs.setdefault(
"SiLorentzAngleCondData",
"SCTSiLorentzAngleCondData")
16 kwargs.setdefault(
"DetEleCollKey",
"ITkStripDetectorElementCollection")
17 acc.setPrivateTools(CompFactory.SiLorentzAngleTool(name=
"ITkStripLorentzAngleTool", **kwargs))
21 forceUseGeoModel=True, **kwargs):
30 algkwargs[
"UseMagFieldCache"] = kwargs.get(
"UseMagFieldCache",
True)
31 algkwargs[
"UseMagFieldDcs"] = kwargs.get(
"UseMagFieldDcs",
not flags.Common.isOnline)
32 algkwargs[
"UseGeoModel"] = forceUseGeoModel
33 algkwargs[
"useSctDefaults"] = kwargs.get(
"useSctDefaults",
False)
34 if not algkwargs[
"useSctDefaults"]:
35 if kwargs.get(
"SiConditionsTool"):
36 algkwargs[
"SiConditionsTool"] = kwargs.get(
"SiConditionsTool")
39 if kwargs.get(
"DCSConditionsTool"):
40 sikwargs[
"DCSConditionsTool"] = kwargs.get(
"DCSConditionsTool")
41 sikwargs[
"ForceUseGeoModel"] = forceUseGeoModel
44 algkwargs[
"SCTDetEleCollKey"] =
"ITkStripDetectorElementCollection"
45 acc.addCondAlgo(CompFactory.SCTSiLorentzAngleCondAlg(name, **algkwargs))