Skip to content
Snippets Groups Projects
Commit 70058a61 authored by Edward Moyse's avatar Edward Moyse
Browse files

Merge branch 'master-SCT-job-config-1013' into 'master'

Clean-ups of some of the new job configurations for SCT

See merge request atlas/athena!37237
parents bd4ea627 b665a381
No related branches found
No related tags found
No related merge requests found
Showing
with 147 additions and 154 deletions
......@@ -23,7 +23,7 @@ if __name__=="__main__":
from AthenaConfiguration.AllConfigFlags import ConfigFlags
ConfigFlags.Input.isMC = False
ConfigFlags.Input.ProjectName = "data17_13TeV"
ConfigFlags.Input.ProjectName = "data16_13TeV"
ConfigFlags.Input.RunNumber = 310809
ConfigFlags.addFlag("Input.InitialTimeStamp", 1476741326) # LB 18 of run 310809, 10/17/2016 @ 9:55pm (UTC)
ConfigFlags.IOVDb.GlobalTag = "CONDBR2-BLKPA-2017-06"
......
"""Define method to configure and test SCT_SiliconConditionsTestAlgConfig
Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
"""
from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
from AthenaConfiguration.ComponentFactory import CompFactory
def SCT_SiliconConditionsTestAlgCfg(flags, name="SCT_SiliconConditionsTestAlg", **kwargs):
"""Return a configured SCT_SiliconConditionsTestAlg"""
acc = ComponentAccumulator()
from SCT_ConditionsTools.SCT_SiliconConditionsConfig import SCT_SiliconConditionsCfg
kwargs.setdefault("SCT_SiliconConditionsTool", acc.popToolsAndMerge(SCT_SiliconConditionsCfg(flags)))
acc.addEventAlgo(CompFactory.SCT_SiliconConditionsTestAlg(**kwargs))
return acc
if __name__=="__main__":
from AthenaCommon.Logging import log
from AthenaCommon.Constants import INFO
log.setLevel(INFO)
from AthenaCommon.Configurable import Configurable
Configurable.configurableRun3Behavior=1
from AthenaConfiguration.AllConfigFlags import ConfigFlags
ConfigFlags.Input.isMC = True
ConfigFlags.Input.ProjectName = "mc16_13TeV"
ConfigFlags.Input.RunNumber = 300000 # MC16c 2017 run number
ConfigFlags.addFlag("Input.InitialTimeStamp", 1500000000) # MC16c 2017 time stamp
ConfigFlags.IOVDb.GlobalTag = "OFLCOND-MC16-SDR-18"
ConfigFlags.GeoModel.AtlasVersion = "ATLAS-R2-2015-03-01-00"
ConfigFlags.Detector.GeometrySCT = True
ConfigFlags.lock()
from AthenaConfiguration.MainServicesConfig import MainServicesCfg
cfg = MainServicesCfg(ConfigFlags)
from McEventSelector.McEventSelectorConfig import McEventSelectorCfg
cfg.merge(McEventSelectorCfg(ConfigFlags))
cfg.merge(SCT_SiliconConditionsTestAlgCfg(ConfigFlags))
cfg.run(maxEvents=20)
"""Define methods to configure SCT_DCSConditions
Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
"""
from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
from AthenaConfiguration.ComponentFactory import CompFactory
......@@ -11,42 +11,46 @@ SCT_DCSConditionsStatCondAlg=CompFactory.SCT_DCSConditionsStatCondAlg
SCT_DCSConditionsHVCondAlg=CompFactory.SCT_DCSConditionsHVCondAlg
SCT_DCSConditionsTempCondAlg=CompFactory.SCT_DCSConditionsTempCondAlg
def SCT_DCSConditionsToolCfg(flags, name="InDetSCT_DCSConditionsTool", **kwargs):
"""Return a configured SCT_DCSConditionsTool"""
kwargs.setdefault("ReadAllDBFolders", True)
kwargs.setdefault("ReturnHVTemp", True)
return SCT_DCSConditionsTool(name, **kwargs)
def SCT_DCSConditionsCfg(flags, name="InDetSCT_DCSConditions", **kwargs):
"""Return configured ComponentAccumulator and tool for SCT_DCSConditions
DCSConditionsTool may be provided in kwargs
"""Configure necessary condition folders, condition algorithms
for SCT_DCSConditionsTool and return it.
"""
acc = ComponentAccumulator()
acc.merge(GeoModelCfg(flags)) # For SCT_ID used in SCT_DCSConditionsTool
tool = kwargs.get("DCSConditionsTool", SCT_DCSConditionsToolCfg(flags))
# folder arguments
dbInstance = kwargs.get("dbInstance", "DCS_OFL")
hvFolder = kwargs.get("hvFolder", "/SCT/DCS/HV")
tempFolder = kwargs.get("tempFolder", "/SCT/DCS/MODTEMP")
stateFolder = kwargs.get("stateFolder", "/SCT/DCS/CHANSTAT")
if tool.ReadAllDBFolders == tool.ReturnHVTemp:
# Condition folders
isDataHLT = flags.Common.isOnline and not flags.Input.isMC
dcsFolder = "/SCT/HLT/DCS" if isDataHLT else "/SCT/DCS"
dbInstance = kwargs.get("dbInstance", "SCT" if isDataHLT else "DCS_OFL")
hvFolder = kwargs.get("hvFolder", dcsFolder + "/HV")
tempFolder = kwargs.get("tempFolder", dcsFolder + "/MODTEMP")
stateFolder = kwargs.get("stateFolder", dcsFolder + "/CHANSTAT")
ReadAllDBFolders = kwargs.get("ReadAllDBFolders", True)
ReturnHVTemp = kwargs.get("ReturnHVTemp", True)
# Condition algorithms
if ReadAllDBFolders == ReturnHVTemp:
acc.merge(addFolders(flags, stateFolder, dbInstance, className="CondAttrListCollection"))
# algo
statArgs = {
"name": name + "StatCondAlg",
"ReturnHVTemp": tool.ReturnHVTemp,
"ReturnHVTemp": ReturnHVTemp,
"ReadKeyHV": hvFolder,
"ReadKeyState": stateFolder,
}
statAlg = SCT_DCSConditionsStatCondAlg(**statArgs)
acc.addCondAlgo(statAlg)
if tool.ReturnHVTemp:
if ReturnHVTemp:
acc.merge(addFolders(flags, [hvFolder, tempFolder], dbInstance, className="CondAttrListCollection"))
hvAlg = SCT_DCSConditionsHVCondAlg(name=name + "HVCondAlg", ReadKey=hvFolder)
acc.addCondAlgo(hvAlg)
tempAlg = SCT_DCSConditionsTempCondAlg(name=name + "TempCondAlg", ReadKey=tempFolder)
acc.addCondAlgo(tempAlg)
acc.setPrivateTools(tool)
return acc
# Condition tool
acc.merge(GeoModelCfg(flags)) # For SCT_ID used in SCT_DCSConditionsTool
toolkwargs = {}
toolkwargs["ReadAllDBFolders"] = ReadAllDBFolders
toolkwargs["ReturnHVTemp"] = ReturnHVTemp
acc.setPrivateTools(SCT_DCSConditionsTool(name="InDetSCT_DCSConditionsTool", **toolkwargs))
return acc
......@@ -5,29 +5,37 @@ Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
from AthenaConfiguration.ComponentFactory import CompFactory
from AtlasGeoModel.GeoModelConfig import GeoModelCfg
from SCT_ConditionsTools.SCT_DCSConditionsConfig import SCT_DCSConditionsCfg
SCT_SiliconHVCondAlg=CompFactory.SCT_SiliconHVCondAlg
SCT_SiliconTempCondAlg=CompFactory.SCT_SiliconTempCondAlg
SCT_SiliconConditionsTool=CompFactory.SCT_SiliconConditionsTool
def SCT_SiliconConditionsToolCfg(flags, name="SCT_SiliconConditionsTool", **kwargs):
"""Return a configured SCT_SiliconConditionsTool (a.k.a. SiConditionsTool)"""
kwargs.setdefault("UseDB", True)
kwargs.setdefault("ForceUseGeoModel", False)
return SCT_SiliconConditionsTool(name, **kwargs)
def SCT_SiliconConditionsCfg(flags, name="SCT_Silicon", **kwargs):
"""Return a ComponentAccumulator configured for SiliconConditions DB
DCSConditionsTool may be provided in kwargs
"""
acc = ComponentAccumulator()
acc.merge(GeoModelCfg(flags)) # For SCT_ID used in SCT_SiliconConditionsTool
CondArgs = {}
# Condition algorithms
algkwargs = {}
DCSConditionsTool = kwargs.get("DCSConditionsTool")
if DCSConditionsTool:
CondArgs["UseState"] = DCSConditionsTool.ReadAllDBFolders
CondArgs["DCSConditionsTool"] = DCSConditionsTool
acc.addCondAlgo(SCT_SiliconHVCondAlg(name=name + "HVCondAlg", **CondArgs))
acc.addCondAlgo(SCT_SiliconTempCondAlg(name=name + "TempCondAlg", **CondArgs))
return acc
algkwargs["UseState"] = DCSConditionsTool.ReadAllDBFolders
algkwargs["DCSConditionsTool"] = DCSConditionsTool
else:
algkwargs["UseState"] = True
algkwargs["DCSConditionsTool"] = acc.popToolsAndMerge(SCT_DCSConditionsCfg(flags))
# For SCT_ID used in SCT_SiliconHVCondAlg,
# SCT_SiliconTempCondAlg and SCT_SiliconConditionsTool
acc.merge(GeoModelCfg(flags))
acc.addCondAlgo(SCT_SiliconHVCondAlg(name=name + "HVCondAlg", **algkwargs))
acc.addCondAlgo(SCT_SiliconTempCondAlg(name=name + "TempCondAlg", **algkwargs))
# Condition tool
toolkwargs = {}
toolkwargs["UseDB"] = kwargs.get("UseDB", True)
toolkwargs["ForceUseGeoModel"] = kwargs.get("ForceUseGeoModel", False)
acc.setPrivateTools(SCT_SiliconConditionsTool(name="SCT_SiliconConditionsTool", **toolkwargs))
return acc
......@@ -87,24 +87,3 @@ class SCT_SiliconConditionsToolSetup:
self.setAlgs()
self.setTool()
self.tool.UseDB = self.useDB
def SCT_SiliconConditionsCfg( flags, toolName, dcsTool=None, hvAlgName="SCT_SiliconHVCondAlg"):
"""
Sets up necessary tools for ID reco in trigger
TDOD: Experts review to cover other use cases (i.e. missing dcsTool, dependence on flags)
"""
from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
from AthenaConfiguration.ComponentFactory import CompFactory
acc = ComponentAccumulator()
tool = CompFactory.SCT_SiliconConditionsTool(toolName,
UseDB = True, # TODO: repalce by the flag once there
ForceUseGeoModel = False ) # TODO: derive from flags
acc.setPrivateTools( tool )
condAlg = CompFactory.SCT_SiliconHVCondAlg(name = hvAlgName,
UseState = dcsTool.ReadAllDBFolders,
DCSConditionsTool = dcsTool)
acc.addCondAlgo( condAlg )
return acc
#!/usr/bin/env python
"""Run tests on SCT_ConditionsTools/python/*Config.py scripts
Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
"""
from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
from AthenaConfiguration.AllConfigFlags import ConfigFlags
......@@ -10,7 +10,7 @@ from AthenaCommon.Logging import log
from AthenaCommon.Constants import DEBUG
from AthenaCommon.Configurable import Configurable
from SCT_ConditionsTools.SCT_DCSConditionsConfig import SCT_DCSConditionsCfg
from SCT_ConditionsTools.SCT_SiliconConditionsConfig import SCT_SiliconConditionsToolCfg, SCT_SiliconConditionsCfg
from SCT_ConditionsTools.SCT_SiliconConditionsConfig import SCT_SiliconConditionsCfg
from SCT_ConditionsTools.SCT_ReadCalibChipDataConfig import SCT_ReadCalibChipDataCfg
# test setup
......@@ -18,7 +18,6 @@ log.setLevel(DEBUG)
Configurable.configurableRun3Behavior = True
ConfigFlags.Input.Files = defaultTestFiles.HITS
# call tests
tool = SCT_SiliconConditionsToolCfg(ConfigFlags, name="SiliconTestTool")
dcs_acc = SCT_DCSConditionsCfg(ConfigFlags, name="DCSTest")
dcs_acc.popPrivateTools()
acc1=SCT_SiliconConditionsCfg(ConfigFlags, name="SiliconTest")
......
......@@ -4,10 +4,12 @@ Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
"""
from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
from AthenaConfiguration.ComponentFactory import CompFactory
from AtlasGeoModel.GeoModelConfig import GeoModelCfg
def SCTSiLorentzAngleTestAlgCfg(flags, name="SCTSiLorentzAngleTestAlg", **kwargs):
"""Return a configured SCTSiLorentzAngleTestAlg"""
acc = ComponentAccumulator()
acc.merge(GeoModelCfg(flags)) # For SCT_ID used in SCTSiLorentzAngleTestAlg
from SiLorentzAngleTool.SCT_LorentzAngleConfig import SCT_LorentzAngleCfg
kwargs.setdefault("SCTLorentzAngleTool", acc.popToolsAndMerge(SCT_LorentzAngleCfg(flags)))
acc.addEventAlgo(CompFactory.SCTSiLorentzAngleTestAlg(**kwargs))
......@@ -40,4 +42,3 @@ if __name__=="__main__":
cfg.merge(SCTSiLorentzAngleTestAlgCfg(ConfigFlags))
cfg.run(maxEvents=20)
......@@ -2,54 +2,46 @@
Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
"""
from AthenaCommon import Logging
from AthenaConfiguration.ComponentFactory import CompFactory
SiLorentzAngleTool=CompFactory.SiLorentzAngleTool
SCTSiLorentzAngleCondAlg=CompFactory.SCTSiLorentzAngleCondAlg
from SCT_ConditionsTools.SCT_DCSConditionsConfig import SCT_DCSConditionsCfg
from SCT_ConditionsTools.SCT_SiliconConditionsConfig import SCT_SiliconConditionsCfg
from SCT_GeoModel.SCT_GeoModelConfig import SCT_GeometryCfg
from MagFieldServices.MagFieldServicesConfig import MagneticFieldSvcCfg
def SCT_LorentzAngleToolCfg(flags, name="SCT_LorentzAngleTool", **kwargs):
"""Return a SiLorentzAngleTool configured for SCT"""
kwargs.setdefault("DetectorName", "SCT")
kwargs.setdefault("SiLorentzAngleCondData", "SCTSiLorentzAngleCondData")
kwargs.setdefault("DetEleCollKey", "SCT_DetectorElementCollection")
kwargs.setdefault("UseMagFieldCache", True)
return SiLorentzAngleTool(name, **kwargs)
def SCT_LorentzAngleCfg(flags, name="SCT_SiLorentzAngleCondAlg",
forceUseDB=False, forceUseGeoModel=False, **kwargs):
forceUseGeoModel=False, **kwargs):
"""Return configured ComponentAccumulator and tool for SCT_LorentzAngle
SiLorentzAngleTool may be provided in kwargs
SiConditionsTool and/or DCSConditionsTool may be provided in kwargs
"""
if forceUseDB and forceUseGeoModel:
msg = Logging.logging.getLogger("SCT_LorentzAngleCfg")
msg.error("Setting is wrong: both forceUseDB and forceUseGeoModel cannot be True at the same time")
# Condition algorithm
# construct with field services
acc = MagneticFieldSvcCfg(flags)
acc.merge(SCT_GeometryCfg(flags)) # For SCT_DetectorElementCollection used in SCTSiLorentzAngleCondAlg
tool = kwargs.get("SiLorentzAngleTool", SCT_LorentzAngleToolCfg(flags))
if not forceUseGeoModel:
DCSkwargs = {}
# For HLT
if flags.Common.isOnline and not flags.Input.isMC:
dcs_folder = "/SCT/HLT/DCS"
DCSkwargs["dbInstance"] = "SCT"
DCSkwargs["hvFolder"] = dcs_folder + "/HV"
DCSkwargs["tempFolder"] = dcs_folder + "/MODTEMP"
DCSkwargs["stateFolder"] = dcs_folder + "/CHANSTAT"
DCSAcc = SCT_DCSConditionsCfg(flags, **DCSkwargs)
SCAcc = SCT_SiliconConditionsCfg(flags, DCSConditionsTool=DCSAcc.popPrivateTools())
acc.merge(DCSAcc)
acc.merge(SCAcc)
# For SCT_ID and SCT_DetectorElementCollection used
# in SCTSiLorentzAngleCondAlg and SiLorentzAngleTool
acc.merge(SCT_GeometryCfg(flags))
# set up SCTSiLorentzAngleCondAlg
kwargs.setdefault("UseMagFieldCache", tool.UseMagFieldCache)
kwargs.setdefault("UseMagFieldDcs", not flags.Common.isOnline)
kwargs.setdefault("UseGeoModel", forceUseGeoModel)
kwargs.setdefault("useSctDefaults", False)
acc.addCondAlgo(SCTSiLorentzAngleCondAlg(name, **kwargs))
acc.setPrivateTools(tool)
algkwargs = {}
algkwargs["UseMagFieldCache"] = kwargs.get("UseMagFieldCache", True)
algkwargs["UseMagFieldDcs"] = kwargs.get("UseMagFieldDcs", not flags.Common.isOnline)
algkwargs["UseGeoModel"] = forceUseGeoModel
algkwargs["useSctDefaults"] = kwargs.get("useSctDefaults", False)
if not algkwargs["useSctDefaults"]:
if kwargs.get("SiConditionsTool"):
algkwargs["SiConditionsTool"] = kwargs.get("SiConditionsTool")
else:
sikwargs = {}
if kwargs.get("DCSConditionsTool"):
sikwargs["DCSConditionsTool"] = kwargs.get("DCSConditionsTool")
sikwargs["ForceUseGeoModel"] = forceUseGeoModel
algkwargs["SiConditionsTool"] = acc.popToolsAndMerge(SCT_SiliconConditionsCfg(flags, **sikwargs))
acc.addCondAlgo(SCTSiLorentzAngleCondAlg(name, **algkwargs))
# Condition tool
toolkwargs = {}
toolkwargs["DetectorName"] = "SCT"
toolkwargs["DetEleCollKey"] = "SCT_DetectorElementCollection"
toolkwargs["SiLorentzAngleCondData"] = "SCTSiLorentzAngleCondData"
acc.setPrivateTools(SiLorentzAngleTool(name, **toolkwargs))
return acc
......@@ -24,7 +24,7 @@ if __name__=="__main__":
from AthenaConfiguration.AllConfigFlags import ConfigFlags
ConfigFlags.Input.isMC = True
ConfigFlags.Input.ProjectName = "mc16_13TeV"
ConfigFlags.Input.RunNumber = [300000] # MC16c 2017 run number
ConfigFlags.Input.RunNumber = 300000 # MC16c 2017 run number
ConfigFlags.addFlag("Input.InitialTimeStamp", 1500000000) # MC16c 2017 time stamp
ConfigFlags.IOVDb.GlobalTag = "OFLCOND-MC16-SDR-18"
ConfigFlags.GeoModel.AtlasVersion = "ATLAS-R2-2015-03-01-00"
......
......@@ -4,43 +4,36 @@ Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
"""
from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
from AthenaConfiguration.ComponentFactory import CompFactory
from SCT_ConditionsTools.SCT_DCSConditionsConfig import SCT_DCSConditionsCfg
from SCT_ConditionsTools.SCT_SiliconConditionsConfig import SCT_SiliconConditionsCfg
from SCT_GeoModel.SCT_GeoModelConfig import SCT_GeometryCfg
SiPropertiesTool=CompFactory.SiPropertiesTool
SCTSiPropertiesCondAlg=CompFactory.SCTSiPropertiesCondAlg
def SCT_SiPropertiesToolCfg(flags, name="SCT_SiPropertiesTool", **kwargs):
"""Return a SiPropertiesTool configured for SCT"""
kwargs.setdefault("DetectorName", "SCT")
kwargs.setdefault("ReadKey", "SCTSiliconPropertiesVector")
return SiPropertiesTool(name=name, **kwargs)
def SCT_SiPropertiesCfg(flags, name="SCTSiPropertiesCondAlg", **kwargs):
"""Return configured ComponentAccumulator and tool for SCT_SiProperties
SiConditionsTool and/or SiPropertiesTool may be provided in kwargs
SiConditionsTool and/or DCSConditionsTool may be provided in kwargs
"""
acc = ComponentAccumulator()
acc.merge(SCT_GeometryCfg(flags)) # For SCT_DetectorElementCollection used in SCTSiPropertiesCondAlg
# Condition algorithm
# SCTSiPropertiesCondAlg needs outputs of SCT_SiliconConditions algorithms
algkwargs = {}
SiConditionsTool = kwargs.get("SiConditionsTool")
if SiConditionsTool:
algkwargs["SiConditionsTool"] = SiConditionsTool
else:
algkwargs["SiConditionsTool"] = acc.popToolsAndMerge(SCT_SiliconConditionsCfg(flags, **kwargs))
# For SCT_ID and SCT_DetectorElementCollection
# used in SCTSiPropertiesCondAlg and SiPropertiesTool
acc.merge(SCT_GeometryCfg(flags))
alg = SCTSiPropertiesCondAlg(name, **algkwargs)
acc.addCondAlgo(alg)
DCSkwargs = {}
# For HLT
if flags.Common.isOnline and not flags.Input.isMC:
dcs_folder = "/SCT/HLT/DCS"
DCSkwargs["dbInstance"] = "SCT"
DCSkwargs["hvFolder"] = dcs_folder + "/HV"
DCSkwargs["tempFolder"] = dcs_folder + "/MODTEMP"
DCSkwargs["stateFolder"] = dcs_folder + "/CHANSTAT"
DCSAcc = SCT_DCSConditionsCfg(flags, **DCSkwargs)
SCAcc = SCT_SiliconConditionsCfg(flags, DCSConditionsTool=DCSAcc.popPrivateTools())
acc.merge(DCSAcc)
acc.merge(SCAcc)
# Condition tool
toolkwargs = {}
toolkwargs["DetectorName"] = "SCT"
toolkwargs["ReadKey"] = "SCTSiliconPropertiesVector"
acc.setPrivateTools(SiPropertiesTool(name=name, **toolkwargs))
tool = kwargs.get("SiPropertiesTool", SCT_SiPropertiesToolCfg(flags))
alg = SCTSiPropertiesCondAlg(name, **kwargs)
acc.addCondAlgo(alg)
acc.setPrivateTools(tool)
return acc
......@@ -7,8 +7,7 @@ from AthenaConfiguration.ComponentFactory import CompFactory
from AthenaCommon.Logging import logging
from OutputStreamAthenaPool.OutputStreamConfig import OutputStreamCfg
from SCT_GeoModel.SCT_GeoModelConfig import SCT_GeometryCfg
from SCT_ConditionsTools.SCT_DCSConditionsConfig import SCT_DCSConditionsCfg
from SCT_ConditionsTools.SCT_SiliconConditionsConfig import SCT_SiliconConditionsToolCfg, SCT_SiliconConditionsCfg
from SCT_ConditionsTools.SCT_SiliconConditionsConfig import SCT_SiliconConditionsCfg
from SCT_ConditionsTools.SCT_ReadCalibChipDataConfig import SCT_ReadCalibChipDataCfg
from SiPropertiesTool.SCT_SiPropertiesConfig import SCT_SiPropertiesCfg
from SiLorentzAngleTool.SCT_LorentzAngleConfig import SCT_LorentzAngleCfg
......@@ -166,14 +165,9 @@ def SCT_SurfaceChargesGeneratorCfg(flags, name="SCT_SurfaceChargesGenerator", **
SCT_SurfaceChargesGenerator, SCT_RadDamageSummaryTool = CompFactory.getComps("SCT_SurfaceChargesGenerator", "SCT_RadDamageSummaryTool",)
tool = SCT_SurfaceChargesGenerator(name, **kwargs)
tool.RadDamageSummaryTool = SCT_RadDamageSummaryTool()
DCSCondTool = acc.popToolsAndMerge(SCT_DCSConditionsCfg(flags))
SiliCondTool = SCT_SiliconConditionsToolCfg(flags)
SiliCondAcc = SCT_SiliconConditionsCfg(flags, DCSConditionsTool=DCSCondTool)
SiliPropsAcc = SCT_SiPropertiesCfg(flags, SiConditionsTool=SiliCondTool)
acc.merge(SiliCondAcc)
tool.SiConditionsTool = SiliCondTool
tool.SiPropertiesTool = acc.popToolsAndMerge(SiliPropsAcc)
tool.LorentzAngleTool = acc.popToolsAndMerge(SCT_LorentzAngleCfg(flags))
tool.SiConditionsTool = acc.popToolsAndMerge(SCT_SiliconConditionsCfg(flags))
tool.SiPropertiesTool = acc.popToolsAndMerge(SCT_SiPropertiesCfg(flags, SiConditionsTool=tool.SiConditionsTool))
tool.LorentzAngleTool = acc.popToolsAndMerge(SCT_LorentzAngleCfg(flags, SiConditionsTool=tool.SiConditionsTool))
acc.setPrivateTools(tool)
return acc
......
......@@ -58,11 +58,10 @@ def SCT_ClusterOnTrackToolCfg( flags, **kwargs ):
acc = ComponentAccumulator()
from SiLorentzAngleTool.SCT_LorentzAngleConfig import SCT_LorentzAngleCfg
sctLATool = acc.popToolsAndMerge( SCT_LorentzAngleCfg( flags ) )
acc.addPublicTool( sctLATool )
tool = CompFactory.InDet.SCT_ClusterOnTrackTool("SCT_ClusterOnTrackTool",
CorrectionStrategy = 0, # do correct position bias
ErrorStrategy = 2, # do use phi dependent errors
LorentzAngleTool = acc.getPublicTool( "SCT_LorentzAngleTool" ) # default name
LorentzAngleTool = sctLATool # default name
)
acc.addPublicTool ( tool )
return acc
......@@ -287,16 +286,6 @@ def TrigInDetCondCfg( flags ):
acc.merge(addFoldersSplitOnline(flags, "INDET","/Indet/Onl/AlignL3","/Indet/AlignL3",className="AlignableTransformContainer"))
acc.merge(addFoldersSplitOnline(flags, "INDET","/Indet/Onl/IBLDist","/Indet/IBLDist",className="CondAttrListCollection"))
from SCT_ConditionsTools.SCT_DCSConditionsConfig import SCT_DCSConditionsCfg, SCT_DCSConditionsToolCfg
dcsTool = acc.popToolsAndMerge( SCT_DCSConditionsCfg( flags, DCSConditionsTool = SCT_DCSConditionsToolCfg( flags, ReadAllDBFolders = True, ReturnHVTemp = True)) )
# SCT_DCSConditionsTool=CompFactory.SCT_DCSConditionsTool
# dcsTool = SCT_DCSConditionsTool(ReadAllDBFolders = True, ReturnHVTemp = True)
from SCT_ConditionsTools.SCT_SiliconConditionsConfig import SCT_SiliconConditionsCfg #, SCT_SiliconConditionsToolCfg
#sctSiliconConditionsTool= SCT_SiliconConditionsCfg(flags, toolName="InDetSCT_SiliconConditionsTool", dcsTool=dcsTool )
#sctSiliconConditionsTool = SCT_SiliconConditionsToolCfg(flags)
acc.merge(SCT_SiliconConditionsCfg(flags, DCSConditionsTool=dcsTool))
SCT_AlignCondAlg=CompFactory.SCT_AlignCondAlg
acc.addCondAlgo(SCT_AlignCondAlg(UseDynamicAlignFolders = True))
......@@ -315,14 +304,6 @@ def TrigInDetCondCfg( flags ):
ReadKeyModule = moduleFolder,
ReadKeyMur = murFolder))
acc.merge(addFolders(flags, [channelFolder, moduleFolder, murFolder], "SCT", className="CondAttrListVec"))
# Set up SCTSiLorentzAngleCondAlg
SCT_ConfigurationConditionsTool=CompFactory.SCT_ConfigurationConditionsTool
stateFolder = "/SCT/DCS/CHANSTAT"
hvFolder = "/SCT/DCS/HV"
tempFolder = "/SCT/DCS/MODTEMP"
dbInstance = "DCS_OFL"
acc.merge(addFolders(flags, [stateFolder, hvFolder, tempFolder], dbInstance, className="CondAttrListCollection"))
# from InDetConfig.InDetRecToolConfig import InDetSCT_ConditionsSummaryToolCfg
# sctCondSummaryTool = acc.popToolsAndMerge( InDetSCT_ConditionsSummaryToolCfg( flags, withFlaggedCondTool=False, withTdaqTool=False ) )
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment