Skip to content
Snippets Groups Projects
Commit 015bbfc2 authored by Duc Ta's avatar Duc Ta
Browse files

Merge branch 'RemoveLegacySimConfigStragglers2_24.0' into '24.0'

Clean-up/Migration of commented out legacy configuration in Simulation packages

See merge request atlas/athena!69558
parents d4bc3340 957522ac
No related branches found
No related tags found
No related merge requests found
......@@ -47,15 +47,15 @@ def QuirkPhysicsToolCfg(flags, name="QuirkPhysicsTool", **kwargs):
return result
## def getDebugSteppingActionTool(name="G4UA::DebugSteppingActionTool", **kwargs): # FIXME missing functionality
## from Quirks.QuirksConf import G4UA__DebugSteppingActionTool
## from G4AtlasApps.SimFlags import simFlags
## # use configuration passed through the flags
## if name in simFlags.UserActionConfig.get_Value().keys():
## for prop,value in simFlags.UserActionConfig.get_Value()[name].iteritems():
## kwargs.setdefault(prop,value)
##
## return G4UA__DebugSteppingActionTool(name, **kwargs)
def DebugSteppingActionToolCfg(flags, name="DebugSteppingActionTool", **kwargs):
result = ComponentAccumulator()
# TODO UserActionConfig flag not yet migrated
# example custom configuration
# if name in flags.Sim.UserActionConfig.keys():
# for prop,value in flags.Sim.UserActionConfig[name].iteritems():
# kwargs.setdefault(prop,value)
result.setPrivateTools( CompFactory.G4UA.DebugSteppingActionTool(name, **kwargs) )
return result
def QuirksCfg(flags):
......
# Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
# Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
from AthenaConfiguration.ComponentFactory import CompFactory
......@@ -9,34 +9,21 @@ def getEnvelopeMap(flags):
# Map of volume name to output collection name
envelopeMap = dict()
#todo - migrate ctb and cosmic config too
"""if ( hasattr(simFlags, "LArFarUpstreamMaterial") and
simFlags.LArFarUpstreamMaterial.statusOn and
simFlags.LArFarUpstreamMaterial.get_Value() ):
envelopeMap.update({'LARFARUPSTREAMMATERIAL::LARFARUPSTREAMMATERIAL':
'LArFarUpstreamMaterialExitLayer'})
if flags.Beam.Type is BeamType.Cosmics:
## First filter volume
if simFlags.CosmicFilterVolumeName == "TRT_Barrel":
envelopeMap['TRT::BarrelOuterSupport'] = 'TRTBarrelEntryLayer'
elif simFlags.CosmicFilterVolumeName == "TRT_EC":
envelopeMap['TRT::WheelA'] = 'TRTECAEntryLayer'
envelopeMap['TRT::WheelB'] = 'TRTECBEntryLayer'
elif simFlags.CosmicFilterVolumeName == "SCT_Barrel":
envelopeMap['SCT::ThShieldOuterCly'] = 'SCTBarrelEntryLayer'# could be ThShieldInnerCly or Cyl..
elif simFlags.CosmicFilterVolumeName == "Pixel":
envelopeMap['Pixel::Pixel'] = 'PixelEntryLayer'
## If second volume requested
if simFlags.CosmicFilterVolumeName2.statusOn:
if simFlags.CosmicFilterVolumeName2 == "TRT_Barrel":
envelopeMap['TRT::BarrelOuterSupport'] = 'TRTBarrelEntryLayer'
elif simFlags.CosmicFilterVolumeName2 == "TRT_EC":
envelopeMap['TRT::WheelA'] = 'TRTECAEntryLayer'
envelopeMap['TRT::WheelB'] = 'TRTECBEntryLayer'
elif simFlags.CosmicFilterVolumeName2 == "SCT_Barrel":
envelopeMap['SCT::ThShieldOuterCly'] = 'SCTBarrelEntryLayer'# could be ThShieldInnerCly or Cyl..
elif simFlags.CosmicFilterVolumeName2 == "Pixel":
envelopeMap['Pixel::Pixel'] = 'PixelEntryLayer'"""
# TODO - implement CTB config
# if flags.TestBeam.LArFarUpstreamMaterial:
# envelopeMap['LARFARUPSTREAMMATERIAL::LARFARUPSTREAMMATERIAL'] = 'LArFarUpstreamMaterialExitLayer'
from AthenaConfiguration.Enums import BeamType
if flags.Beam.Type is BeamType.Cosmics:
## First filter volume
if "TRT_Barrel" in flags.Sim.CosmicFilterVolumeNames:
envelopeMap['TRT::BarrelOuterSupport'] = 'TRTBarrelEntryLayer'
elif "TRT_EC" in flags.Sim.CosmicFilterVolumeNames:
envelopeMap['TRT::WheelA'] = 'TRTECAEntryLayer'
envelopeMap['TRT::WheelB'] = 'TRTECBEntryLayer'
elif "TRT_EC" in flags.Sim.CosmicFilterVolumeNames:
envelopeMap['SCT::ThShieldOuterCly'] = 'SCTBarrelEntryLayer'# could be ThShieldInnerCly or Cyl..
elif "Pixel" in flags.Sim.CosmicFilterVolumeNames:
envelopeMap['Pixel::Pixel'] = 'PixelEntryLayer'
if not flags.Sim.ISFRun:
if flags.Detector.GeometryID:
envelopeMap['IDET::IDET'] = 'CaloEntryLayer'
......
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