diff --git a/Calorimeter/CaloRec/python/CaloRecoConfig.py b/Calorimeter/CaloRec/python/CaloRecoConfig.py index 3854e8341895af076e790caa8ed29b4c94a54a76..d399a4c5fb260954d9f3a31e026e61ec22f8efb6 100644 --- a/Calorimeter/CaloRec/python/CaloRecoConfig.py +++ b/Calorimeter/CaloRec/python/CaloRecoConfig.py @@ -51,7 +51,7 @@ def CaloRecoCfg(configFlags, clustersname=None): from LArCellRec.LArNoisyROSummaryConfig import LArNoisyROSummaryCfg result.merge(LArNoisyROSummaryCfg(configFlags)) - if not configFlags.Input.isMC: + if not configFlags.Input.isMC and not configFlags.Overlay.DataOverlay: from LArROD.LArFebErrorSummaryMakerConfig import LArFebErrorSummaryMakerCfg result.merge(LArFebErrorSummaryMakerCfg(configFlags)) @@ -59,12 +59,11 @@ def CaloRecoCfg(configFlags, clustersname=None): from TileMuId.TileMuIdConfig import TileLookForMuAlgCfg result.merge(TileLookForMuAlgCfg(configFlags)) - if not configFlags.Input.isMC: + if not configFlags.Input.isMC and not configFlags.Overlay.DataOverlay: #Configure LArDigitsThinner: from LArROD.LArDigitThinnerConfig import LArDigitThinnerCfg result.merge(LArDigitThinnerCfg(configFlags)) - #Configure MBTSTimeDiff #Clients are BackgroundWordFiller and (deprecated?) DQTBackgroundMonTool #Consider moving to BackgroundWordFiller config diff --git a/LArCalorimeter/LArCellRec/python/LArCellBuilderConfig.py b/LArCalorimeter/LArCellRec/python/LArCellBuilderConfig.py index a33517fcdf41be6436abc4d40f057c30db4850b0..36952e2e3337dbb5d43584a4e1df6e222ce0294f 100644 --- a/LArCalorimeter/LArCellRec/python/LArCellBuilderConfig.py +++ b/LArCalorimeter/LArCellRec/python/LArCellBuilderConfig.py @@ -1,9 +1,9 @@ -# Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator from AthenaConfiguration.ComponentFactory import CompFactory LArCellBuilderFromLArRawChannelTool, LArCellMerger, LArCellNoiseMaskingTool=CompFactory.getComps("LArCellBuilderFromLArRawChannelTool","LArCellMerger","LArCellNoiseMaskingTool",) -from LArCabling.LArCablingConfig import LArOnOffIdMappingCfg +from LArCabling.LArCablingConfig import LArOnOffIdMappingCfg from LArBadChannelTool.LArBadChannelConfig import LArBadChannelCfg, LArBadFebCfg from LArCalibUtils.LArHVScaleConfig import LArHVScaleCfg @@ -25,13 +25,13 @@ def LArCellBuilderCfg(configFlags): def LArCellCorrectorCfg(configFlags): result=ComponentAccumulator() - + correctionTools=[] - if configFlags.LAr.RawChannelSource in ("both","input") and not configFlags.Input.isMC: + if configFlags.LAr.RawChannelSource in ("both","input") and not configFlags.Input.isMC and not configFlags.Overlay.DataOverlay: theMerger=LArCellMerger(RawChannelsName="LArRawChannels_FromDigits") correctionTools.append(theMerger) - + if configFlags.LAr.doCellNoiseMasking or configFlags.LAr.doCellSporadicNoiseMasking: result.merge(LArBadChannelCfg(configFlags)) theNoiseMasker=LArCellNoiseMaskingTool(qualityCut = 4000) @@ -44,7 +44,7 @@ def LArCellCorrectorCfg(configFlags): correctionTools.append(theNoiseMasker) result.setPrivateTools(correctionTools) - return result + return result def LArHVCellContCorrCfg(configFlags): diff --git a/LArCalorimeter/LArConfiguration/python/LArConfigFlags.py b/LArCalorimeter/LArConfiguration/python/LArConfigFlags.py index 4d0db477eacdee0ed3ab745e5044751b9b8895fd..77d4f6cc93954c383ffed4dd927b0ad9ef862cba 100644 --- a/LArCalorimeter/LArConfiguration/python/LArConfigFlags.py +++ b/LArCalorimeter/LArConfiguration/python/LArConfigFlags.py @@ -1,12 +1,12 @@ -# Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration from __future__ import print_function from AthenaConfiguration.AthConfigFlags import AthConfigFlags -def createLArConfigFlags(): +def createLArConfigFlags(): lcf=AthConfigFlags() - + lcf.addFlag("LAr.doAlign",lambda prevFlags : prevFlags.GeoModel.Layout=="atlas") lcf.addFlag("LAr.doHVCorr",lambda prevFlags : not prevFlags.Input.isMC) lcf.addFlag("LAr.doCellEmMisCalib",lambda prevFlags : prevFlags.Input.isMC) @@ -14,11 +14,11 @@ def createLArConfigFlags(): lcf.addFlag("LAr.RawChannelSource",_determineRawChannelSource) #sensible value are "input": read from the input-file, bytestream or RDO) # "calculated": re-computed by the offline LArRawChannelBuilder - # "both": overwrite the digits computed + # "both": overwrite the digits computed lcf.addFlag("LAr.doCellNoiseMasking",True) lcf.addFlag("LAr.doCellSporadicNoiseMasking",True) - + # Include MC shape folder lcf.addFlag("LAr.UseMCShape", True) # Name of sqlite file containing Electronic Calibration values @@ -53,7 +53,7 @@ def createLArConfigFlags(): lcf.addFlag("LAr.ROD.UseDelta", 0) # Force using the iterative OFC procedure lcf.addFlag("LAr.ROD.forceIter",False) - + ##NoisyRO flags # cell quality cut lcf.addFlag("LAr.NoisyRO.CellQuality", 4000) @@ -61,7 +61,7 @@ def createLArConfigFlags(): lcf.addFlag("LAr.NoisyRO.BadChanPerFEB", 30) # Number of Bad FEBs per partition cut lcf.addFlag("LAr.NoisyRO.BadFEBCut", 5) - # Number of channels to declare MNB-Loose + # Number of channels to declare MNB-Loose lcf.addFlag("LAr.NoisyRO.MNBLooseCut", 5) # Number of channels to declare MNB-Tight lcf.addFlag("LAr.NoisyRO.MNBTightCut", 17) @@ -82,12 +82,12 @@ def _getLArRunInfo(prevFlags): _lArRunInfo=getLArFormatForRun(run=runnbr,connstring=dbStr) print ("Got LArRunInfo for run ",runnbr) return _lArRunInfo - + def _determineRawChannelSource(prevFlags): - if (prevFlags.Input.isMC): + if prevFlags.Input.isMC or prevFlags.Overlay.DataOverlay: return "input" - + lri=_getLArRunInfo(prevFlags) #runType: 0=RawData, 1=RawDataResult, 2=Result if lri is None or lri.runType is None: @@ -102,5 +102,4 @@ def _determineRawChannelSource(prevFlags): return "input" #Have only raw-channels in bytestream else: print("WARNING unknown LAr run type !") - return "both" - + return "both" diff --git a/TileCalorimeter/TileRecUtils/python/TileDQstatusConfig.py b/TileCalorimeter/TileRecUtils/python/TileDQstatusConfig.py index ae961af23843367f0fa576f6e4caf4498bad35fb..ee35668559398815c26ec2af036ce384f6456860 100644 --- a/TileCalorimeter/TileRecUtils/python/TileDQstatusConfig.py +++ b/TileCalorimeter/TileRecUtils/python/TileDQstatusConfig.py @@ -1,9 +1,11 @@ -# Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration """Define method to construct configured Tile DQ status tool and algorithm""" from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator from AthenaConfiguration.ComponentFactory import CompFactory +from AthenaConfiguration.Enums import ProductionStep + def TileDQstatusToolCfg(flags, **kwargs): """Return component accumulator with configured private Tile DQ status tool @@ -62,7 +64,7 @@ def TileDQstatusAlgCfg(flags, **kwargs): rawChannelContainer = 'TileRawChannelCnt' - elif flags.Overlay.DataOverlay: + elif flags.Common.ProductionStep == ProductionStep.Overlay and flags.Overlay.DataOverlay: beamElemContainer = '' digitsContainer = flags.Overlay.BkgPrefix + 'TileDigitsCnt' rawChannelContainer = flags.Overlay.BkgPrefix + 'TileRawChannelCnt'