diff --git a/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuGirlTagTool.py b/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuGirlTagTool.py index 3659b269598e4f7d392d916abe5b8760c755662f..c92e770fbe2458bbc6d2abf283bdbf8f68bdb816 100644 --- a/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuGirlTagTool.py +++ b/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuGirlTagTool.py @@ -1,4 +1,4 @@ -# Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration ### JobOptions to run MuGirlTag in xAOD @@ -20,6 +20,7 @@ from AthenaCommon.Logging import log from AtlasGeoModel.CommonGMJobProperties import CommonGeometryFlags from AtlasGeoModel.MuonGMJobProperties import MuonGeometryFlags +from TriggerJobOpts.TriggerFlags import TriggerFlags ############################################################################### ### Configure MuGirlTag### @@ -40,6 +41,8 @@ def TrigMuGirlTagTool( name='TrigMuGirlTagTool', **kwargs ): return MuGirlTagToolBase(name=name,configureForTrigger=True,doStau=True,**kwargs) def MuonInsideOutRecoTool( name="MuonInsideOutRecoTool", **kwargs ): + if TriggerFlags.MuonSlice.doTrigMuonConfig: + kwargs.setdefault("VertexContainer", "") return CfgMgr.MuonCombined__MuonInsideOutRecoTool(name,**kwargs ) def MuonCandidateTrackBuilderTool( name="MuonCandidateTrackBuilderTool",**kwargs): diff --git a/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuonCombinedAlgs.py b/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuonCombinedAlgs.py index 6fe88564b03e00c3d7eeca2276c9dac11c11af97..f198ecebd7a7e702a487f352be7db265ea148e99 100644 --- a/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuonCombinedAlgs.py +++ b/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuonCombinedAlgs.py @@ -1,4 +1,4 @@ -# Copyright (C) 2002-2017, 2019 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration from MuonCombinedRecExample.MuonCombinedRecFlags import muonCombinedRecFlags from AthenaCommon.CfgGetter import getPublicTool, getAlgorithm,getPublicToolClone @@ -12,6 +12,7 @@ from AthenaCommon.BeamFlags import jobproperties from AtlasGeoModel.CommonGMJobProperties import CommonGeometryFlags from AtlasGeoModel.MuonGMJobProperties import MuonGeometryFlags +from TriggerJobOpts.TriggerFlags import TriggerFlags def MuonCombinedInDetExtensionAlg(name="MuonCombinedInDetExtensionAlg",**kwargs): tools = [] @@ -137,6 +138,9 @@ def MuonCreatorAlg( name="MuonCreatorAlg",**kwargs ): # but don't set this default in case the StauCreatorAlg is created (see below) if not muonCombinedRecFlags.doMuGirl() and not name=="StauCreatorAlg": kwargs.setdefault("TagMaps",["muidcoTagMap","stacoTagMap","caloTagMap","segmentTagMap"]) + if TriggerFlags.MuonSlice.doTrigMuonConfig: + kwargs.setdefault("MakeClusters", False) + kwargs.setdefault("ClusterContainerName", "") return CfgMgr.MuonCreatorAlg(name,**kwargs) def StauCreatorAlg( name="StauCreatorAlg", **kwargs ): @@ -150,7 +154,8 @@ def StauCreatorAlg( name="StauCreatorAlg", **kwargs ): kwargs.setdefault("BuildSlowMuon",1) kwargs.setdefault("ClusterContainerName", "SlowMuonClusterCollection") kwargs.setdefault("TagMaps",["stauTagMap"]) - recordMuonCreatorAlgObjs (kwargs) + if not TriggerFlags.MuonSlice.doTrigMuonConfig: + recordMuonCreatorAlgObjs (kwargs) return MuonCreatorAlg(name,**kwargs) class MuonCombinedReconstruction(ConfiguredMuonRec): diff --git a/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuonCombinedFitTools.py b/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuonCombinedFitTools.py index 5a688a837340c0e5ce9a89fdb1905bb30d5df6e6..95cfc9b4013ee9877210d9b8f8a297816712fe2b 100644 --- a/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuonCombinedFitTools.py +++ b/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuonCombinedFitTools.py @@ -1,4 +1,4 @@ -# Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration ############################################################### # @@ -213,8 +213,6 @@ def CombinedMuonTrackBuilderFit( name='CombinedMuonTrackBuilderFit', **kwargs ): kwargs.setdefault("SLFitter" , getPublicTool("iPatSLFitter") ) kwargs.setdefault("MaterialAllocator" , getPublicTool("MuidMaterialAllocator") ) kwargs.setdefault("MdtRotCreator" , getPublicTool("MdtDriftCircleOnTrackCreator") ) - kwargs.setdefault("Propagator" , getPublicTool("MuonCombinedPropagator") ) - kwargs.setdefault("SLPropagator" , getPublicTool("MuonCombinedPropagator") ) kwargs.setdefault("CleanCombined" , True ) kwargs.setdefault("CleanStandalone" , True ) kwargs.setdefault("BadFitChi2" , 2.5 ) @@ -227,10 +225,21 @@ def CombinedMuonTrackBuilderFit( name='CombinedMuonTrackBuilderFit', **kwargs ): kwargs.setdefault("Vertex2DSigmaRPhi" , 100.*mm ) kwargs.setdefault("Vertex3DSigmaRPhi" , 6.*mm ) kwargs.setdefault("Vertex3DSigmaZ" , 60.*mm) - kwargs.setdefault("TrackSummaryTool" , ToolSvc.CombinedMuonTrackSummary ) kwargs.setdefault("UseCaloTG" , False ) kwargs.setdefault("CaloMaterialProvider" , getPublicTool("MuonMaterialProviderTool")) + if TriggerFlags.MuonSlice.doTrigMuonConfig: + kwargs.setdefault("TrackSummaryTool" , getPublicTool("MuonTrackSummaryTool") ) + + kwargs.setdefault("Propagator" , ToolSvc.AtlasRungeKuttaPropagator) + kwargs.setdefault("SLPropagator" , ToolSvc.AtlasRungeKuttaPropagator) + else: + import MuonCombinedRecExample.CombinedMuonTrackSummary + kwargs.setdefault("TrackSummaryTool" , ToolSvc.CombinedMuonTrackSummary ) + kwargs.setdefault("Propagator" , getPublicTool("MuonCombinedPropagator") ) + kwargs.setdefault("SLPropagator" , getPublicTool("MuonCombinedPropagator") ) + + if beamFlags.beamType() == 'cosmics': kwargs.setdefault("MdtRotCreator" , "" ) kwargs.setdefault("LowMomentum" , 1.5*GeV ) diff --git a/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuonCombinedTools.py b/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuonCombinedTools.py index baa6e0380a82954f8f36be2bdaa99d456483e7a2..b2e2dd7218ee0e875ef67a11235ca7860fecf5b1 100644 --- a/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuonCombinedTools.py +++ b/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuonCombinedTools.py @@ -1,4 +1,4 @@ -# Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration from MuonCombinedRecExample.MuonCombinedRecFlags import muonCombinedRecFlags from MuonCombinedRecExample.MuonCombinedKeys import MuonCombinedKeys as MuonCbKeys @@ -48,9 +48,12 @@ def MuonInDetForwardCandidateTool( name = 'MuonInDetForwardCandidateTool', **kwa return idCandTool def MuonCombinedParticleCreator(name="MuonCombinedParticleCreator",**kwargs): - import MuonCombinedRecExample.CombinedMuonTrackSummary + if TriggerFlags.MuonSlice.doTrigMuonConfig: + kwargs.setdefault("TrackSummaryTool" , getPublicTool("MuonTrackSummaryTool") ) + else: + import MuonCombinedRecExample.CombinedMuonTrackSummary + kwargs.setdefault("TrackSummaryTool", ToolSvc.CombinedMuonTrackSummary ) #getPublicTool("CombinedMuonTrackSummary") ) kwargs.setdefault("Extrapolator", getPublicTool("AtlasExtrapolator") ) - kwargs.setdefault("TrackSummaryTool", ToolSvc.CombinedMuonTrackSummary ) #getPublicTool("CombinedMuonTrackSummary") ) kwargs.setdefault("KeepAllPerigee",True ) kwargs.setdefault("UseMuonSummaryTool",True ) if beamFlags.beamType() == 'cosmics': @@ -71,14 +74,17 @@ def InDetCandidateTool(name="InDetCandidateTool",**kwargs ): def MuonCreatorTool(name="MuonCreatorTool",**kwargs): kwargs.setdefault("CaloMaterialProvider", getPublicTool("MuonMaterialProviderTool")) - - getPublicTool("MuonMomentumBalanceSignificanceTool") - getPublicTool("MuonScatteringAngleSignificanceTool") - getPublicTool("MuonCaloParticleCreator") + if TriggerFlags.MuonSlice.doTrigMuonConfig: + kwargs.setdefault('MakeTrackAtMSLink',True) + kwargs.setdefault("FillTimingInformation",False) + kwargs.setdefault("MuonSelectionTool", "") + else: + getPublicTool("MuonMomentumBalanceSignificanceTool") + getPublicTool("MuonScatteringAngleSignificanceTool") + getPublicTool("MuonCaloParticleCreator") kwargs.setdefault("TrackParticleCreator", getPublicTool("MuonCombinedParticleCreator") ) kwargs.setdefault("ParticleCaloExtensionTool", getPublicTool("MuonParticleCaloExtensionTool") ) - # kwargs.setdefault("CaloNoiseTool", getPublicTool("CaloNoiseToolDefault") ) return CfgMgr.MuonCombined__MuonCreatorTool(name,**kwargs) def MuonCandidateTool(name="MuonCandidateTool",**kwargs): diff --git a/Trigger/TriggerCommon/TriggerMenuMT/python/HLTMenuConfig/Muon/MuonSetup.py b/Trigger/TriggerCommon/TriggerMenuMT/python/HLTMenuConfig/Muon/MuonSetup.py index 56037f4e5f3728b21494749b2832c633cc9fd6b1..14533f5289aae2d12e63f3d1ef80872b3d73a0fc 100644 --- a/Trigger/TriggerCommon/TriggerMenuMT/python/HLTMenuConfig/Muon/MuonSetup.py +++ b/Trigger/TriggerCommon/TriggerMenuMT/python/HLTMenuConfig/Muon/MuonSetup.py @@ -9,12 +9,8 @@ log = logging.getLogger('MuonSetup') ### Output data name ### from TrigEDMConfig.TriggerEDMRun3 import recordable -from AthenaCommon.DetFlags import DetFlags from MuonConfig.MuonBytestreamDecodeConfig import MuonCacheNames -from AtlasGeoModel.CommonGMJobProperties import CommonGeometryFlags -from AtlasGeoModel.MuonGMJobProperties import MuonGeometryFlags - TrackParticlesName = recordable("HLT_xAODTracks_Muon") theFTF_name = "FTFTracks_Muons" CBTPname = recordable("HLT_CBCombinedMuon_RoITrackParticles") @@ -397,14 +393,13 @@ def l2muisoRecoSequence( RoIs ): def muEFSARecoSequence( RoIs, name ): - from AthenaCommon.AppMgr import ServiceMgr import AthenaCommon.CfgGetter as CfgGetter - from AthenaCommon.CfgGetter import getPublicToolClone from AthenaCommon import CfgMgr from AthenaCommon.CFElements import parOR from MuonRecExample.MuonStandalone import MooSegmentFinderAlg, MuonStandaloneTrackParticleCnvAlg - from MuonCombinedRecExample.MuonCombinedAlgs import MuonCombinedMuonCandidateAlg + from MuonCombinedRecExample.MuonCombinedAlgs import MuonCombinedMuonCandidateAlg, MuonCreatorAlg + from MuonCombinedAlgs.MuonCombinedAlgsMonitoring import MuonCreatorAlgMonitoring muEFSARecoSequence = parOR("efmsViewNode_"+name) @@ -419,9 +414,6 @@ def muEFSARecoSequence( RoIs, name ): ( 'Muon::CscStripPrepDataContainer' , 'StoreGateSvc+CSC_Measurements'), ( 'Muon::CscPrepDataContainer' , 'StoreGateSvc+CSC_Clusters') ] )) - from TrkDetDescrSvc.TrkDetDescrSvcConf import Trk__TrackingVolumesSvc - ServiceMgr += Trk__TrackingVolumesSvc("TrackingVolumesSvc") - #need MdtCondDbAlg for the MuonStationIntersectSvc (required by segment and track finding) from AthenaCommon.AlgSequence import AthSequencer from MuonCondAlg.MuonTopCondAlgConfigRUN2 import MdtCondDbAlg @@ -432,27 +424,21 @@ def muEFSARecoSequence( RoIs, name ): theSegmentFinderAlg = MooSegmentFinderAlg("TrigMuonSegmentMaker_"+name) theSegmentCnvAlg = CfgMgr.xAODMaker__MuonSegmentCnvAlg("MuonSegmentCnvAlg") - TrackBuilder = CfgMgr.MuPatTrackBuilder("TrigMuPatTrackBuilder_"+name ,MuonSegmentCollection = "MuonSegments", TrackSteering=CfgGetter.getPublicToolClone("TrigMuonTrackSteering", "MuonTrackSteering")) + from MuonSegmentTrackMaker.MuonTrackMakerAlgsMonitoring import MuPatTrackBuilderMonitoring + TrackBuilder = CfgMgr.MuPatTrackBuilder("TrigMuPatTrackBuilder_"+name ,MuonSegmentCollection = "MuonSegments", + TrackSteering=CfgGetter.getPublicToolClone("TrigMuonTrackSteering", "MuonTrackSteering"), + MonTool = MuPatTrackBuilderMonitoring("MuPatTrackBuilderMonitoringSA_"+name)) xAODTrackParticleCnvAlg = MuonStandaloneTrackParticleCnvAlg("TrigMuonStandaloneTrackParticleCnvAlg_"+name) theMuonCandidateAlg=MuonCombinedMuonCandidateAlg("TrigMuonCandidateAlg_"+name) - # Monitoring tool for MuonTrackMakerAlgs in SA - from MuonSegmentTrackMaker.MuonTrackMakerAlgsMonitoring import MuPatTrackBuilderMonitoring - TrackBuilder.MonTool = MuPatTrackBuilderMonitoring("MuPatTrackBuilderMonitoringSA_"+name) - - muonparticlecreator = getPublicToolClone("MuonParticleCreator", "TrackParticleCreatorTool", UseTrackSummaryTool=False, UseMuonSummaryTool=True, KeepAllPerigee=True) - theTrackQueryNoFit = getPublicToolClone("TrigMuonTrackQueryNoFitSA", "MuonTrackQuery", Fitter="") - thecreatortool= getPublicToolClone("MuonCreatorTool_SA", "MuonCreatorTool", ScatteringAngleTool="", MuonSelectionTool="", FillTimingInformation=False, UseCaloCells=False, MakeSAMuons=True, MomentumBalanceTool="", TrackParticleCreator=muonparticlecreator,TrackQuery=theTrackQueryNoFit) - msMuonName = muNames.EFSAName if 'FS' in name: msMuonName = muNamesFS.EFSAName - themuoncreatoralg = CfgMgr.MuonCreatorAlg("MuonCreatorAlg_"+name, MuonCreatorTool=thecreatortool, CreateSAmuons=True, MakeClusters=False, TagMaps=[], MuonContainerLocation=msMuonName,ExtrapolatedLocation = "HLT_MSExtrapolatedMuons_"+name, MSOnlyExtrapolatedLocation = "HLT_MSOnlyExtrapolatedMuons_"+name ) + themuoncreatoralg = MuonCreatorAlg("TrigMuonCreatorAlg_"+name, CreateSAmuons=True, TagMaps=[], MuonContainerLocation=msMuonName, + ExtrapolatedLocation = "HLT_MSExtrapolatedMuons_"+name, MSOnlyExtrapolatedLocation = "HLT_MSOnlyExtrapolatedMuons_"+name, + MonTool = MuonCreatorAlgMonitoring("MuonCreatorAlgSA_"+name)) - # Monitoring tool for MuonCreatorAlg in SA - from MuonCombinedAlgs.MuonCombinedAlgsMonitoring import MuonCreatorAlgMonitoring - themuoncreatoralg.MonTool = MuonCreatorAlgMonitoring("MuonCreatorAlgSA_"+name) #Algorithms to views efAlgs.append( theSegmentFinderAlg ) @@ -482,10 +468,10 @@ def muEFSARecoSequence( RoIs, name ): def muEFCBRecoSequence( RoIs, name ): global TrackParticlesName - from AthenaCommon.CfgGetter import getPublicToolClone from AthenaCommon import CfgMgr from AthenaCommon.CFElements import parOR, seqAND - from MuonCombinedRecExample.MuonCombinedAlgs import MuonCombinedInDetCandidateAlg, MuonCombinedAlg + from MuonCombinedRecExample.MuonCombinedAlgs import MuonCombinedInDetCandidateAlg, MuonCombinedAlg, MuonCreatorAlg + from MuonCombinedAlgs.MuonCombinedAlgsMonitoring import MuonCreatorAlgMonitoring efAlgs = [] muEFCBRecoSequence = parOR("efcbViewNode_"+name) @@ -558,28 +544,14 @@ def muEFCBRecoSequence( RoIs, name ): theMuonCombinedAlg = MuonCombinedAlg("TrigMuonCombinedAlg_"+name, MuonCandidateLocation=candidatesName, InDetCandidateLocation="InDetCandidates_"+name) - #Create xAOD Muons - theTrackQueryNoFit = getPublicToolClone("TrigMuonTrackQueryNoFit_"+name, "MuonTrackQuery", Fitter="") - muonparticlecreator = getPublicToolClone("MuonParticleCreatorCB_"+name, "TrackParticleCreatorTool", UseTrackSummaryTool=False, UseMuonSummaryTool=True, KeepAllPerigee=True) - thecreatortoolCB= getPublicToolClone("MuonCreatorTool_triggerCB_"+name, "MuonCreatorTool", ScatteringAngleTool="", CaloMaterialProvider='TMEF_TrkMaterialProviderTool', MuonSelectionTool="", FillTimingInformation=False, UseCaloCells=False,TrackQuery=theTrackQueryNoFit,TrackParticleCreator=muonparticlecreator) - cbMuonName = muNames.EFCBOutInName if 'FS' in name: cbMuonName = muNamesFS.EFCBName - themuoncbcreatoralg = CfgMgr.MuonCreatorAlg("MuonCreatorAlgCB_"+name, MuonCandidateLocation=candidatesName, TagMaps=["muidcoTagMap"], InDetCandidateLocation="InDetCandidates_"+name) - themuoncbcreatoralg.MuonCreatorTool=thecreatortoolCB - themuoncbcreatoralg.MakeClusters=False - themuoncbcreatoralg.ClusterContainerName="" - themuoncbcreatoralg.MuonContainerLocation = cbMuonName - themuoncbcreatoralg.SegmentContainerName = "CBSegments" - themuoncbcreatoralg.ExtrapolatedLocation = "CBExtrapolatedMuons" - themuoncbcreatoralg.MSOnlyExtrapolatedLocation = "CBMSOnlyExtrapolatedMuons" - themuoncbcreatoralg.CombinedLocation = "HLT_CBCombinedMuon_"+name - - # Monitoring tool for MuonCreatorAlg in CB - from MuonCombinedAlgs.MuonCombinedAlgsMonitoring import MuonCreatorAlgMonitoring - themuoncbcreatoralg.MonTool = MuonCreatorAlgMonitoring("MuonCreatorAlgCB_"+name) + themuoncbcreatoralg = MuonCreatorAlg("TrigMuonCreatorAlgCB_"+name, MuonCandidateLocation=candidatesName, TagMaps=["muidcoTagMap"], InDetCandidateLocation="InDetCandidates_"+name, + MuonContainerLocation = cbMuonName, SegmentContainerName = "CBSegments", ExtrapolatedLocation = "CBExtrapolatedMuons", + MSOnlyExtrapolatedLocation = "CBMSonlyExtrapolatedMuons", CombinedLocation = "HLT_CBCombinedMuon_"+name, + MonTool = MuonCreatorAlgMonitoring("MuonCreatorAlgCB_"+name)) #Add all algorithms efAlgs.append(theIndetCandidateAlg) @@ -600,12 +572,9 @@ def muEFInsideOutRecoSequence(RoIs, name): from AthenaCommon.CFElements import parOR, seqAND from AthenaCommon import CfgMgr - from AthenaCommon.CfgGetter import getPublicTool, getPublicToolClone - from AthenaCommon.AppMgr import ToolSvc, ServiceMgr - import AthenaCommon.CfgGetter as CfgGetter from MuonRecExample.MuonStandalone import MooSegmentFinderAlg - from MuonCombinedRecExample.MuonCombinedAlgs import MuonCombinedInDetCandidateAlg + from MuonCombinedRecExample.MuonCombinedAlgs import MuonCombinedInDetCandidateAlg, MuonInsideOutRecoAlg, MuGirlStauAlg, MuonCreatorAlg, StauCreatorAlg efAlgs = [] @@ -617,9 +586,6 @@ def muEFInsideOutRecoSequence(RoIs, name): if "Late" in name: #Need to run hough transform at start of late muon chain - from TrkDetDescrSvc.TrkDetDescrSvcConf import Trk__TrackingVolumesSvc - ServiceMgr += Trk__TrackingVolumesSvc("TrackingVolumesSvc") - #need MdtCondDbAlg for the MuonStationIntersectSvc (required by segment and track finding) from AthenaCommon.AlgSequence import AthSequencer from MuonCondAlg.MuonTopCondAlgConfigRUN2 import MdtCondDbAlg @@ -670,67 +636,19 @@ def muEFInsideOutRecoSequence(RoIs, name): efmuInsideOutRecoSequence += ViewVerifyInsideOut - #Need to configure tools to avoid accessing calo data in muon trigger - theCaloEnergyTool = getPublicToolClone("TrigCaloEnergyTool", "MuidCaloEnergyTool", EnergyLossMeasurement=False, MopParametrization=True, TrackIsolation=False) - - from TrkExRungeKuttaIntersector.TrkExRungeKuttaIntersectorConf import Trk__IntersectorWrapper as Propagator - TrigMuonPropagator = Propagator(name = 'TrigMuonPropagator') - ToolSvc += TrigMuonPropagator - - theCaloTSOS = getPublicToolClone("TrigCaloTrackStateOnSurface", "MuidCaloTrackStateOnSurface", CaloEnergyDeposit=theCaloEnergyTool, CaloEnergyParam=theCaloEnergyTool, Propagator =TrigMuonPropagator, MinRemainingEnergy= 200, ParamPtCut= 3000) - from MuidCaloScatteringTools.MuidCaloScatteringToolsConf import Rec__MuidMaterialEffectsOnTrackProvider - Rec__MuidMaterialEffectsOnTrackProvider.TSOSTool=theCaloTSOS - - theErrorOptimiser = getPublicToolClone("TrigMuonErrorOptimiser", "MuonErrorOptimisationTool", PrepareForFit=False, RecreateStartingParameters=False,RefitTool=getPublicToolClone("TrigMuidRefitTool", "MuonRefitTool", AlignmentErrors = False, Fitter = CfgGetter.getPublicTool("iPatFitter"))) - - theTrackCleaner = getPublicToolClone("TrigMuonTrackCleaner", "MuonTrackCleaner", Fitter='TMEF_iPatFitter', SLFitter='TMEF_iPatFitter') - - - from TrkTrackSummaryTool.TrkTrackSummaryToolConf import Trk__TrackSummaryTool - trkSummaryTool = Trk__TrackSummaryTool( 'TrigMuonTrackSummary',MuonSummaryHelperTool=getPublicTool('MuonTrackSummaryHelperTool'), doSharedHits=False) - if DetFlags.detdescr.ID_on(): - from InDetTrigRecExample.InDetTrigConfigRecLoadTools import InDetTrigTrackSummaryHelperTool - trkSummaryTool.InDetSummaryHelperTool=InDetTrigTrackSummaryHelperTool - trkSummaryTool.doHolesInDet=True - ToolSvc += Trk__TrackSummaryTool('TrigMuonTrackSummary') - theTrackQueryNoFit = getPublicToolClone("TrigMuonInsideOutTrackQueryNoFit", "MuonTrackQuery", Fitter="") - theTrackBuilderTool = getPublicToolClone("TrigCombinedMuonTrackBuilder","CombinedMuonTrackBuilder", UseCaloTG = True, CaloTSOS=theCaloTSOS, CaloMaterialProvider='TMEF_TrkMaterialProviderTool', MuonHoleRecovery="",CaloEnergyParam=theCaloEnergyTool,MuonErrorOptimizer=theErrorOptimiser, Fitter='TMEF_iPatFitter', MaterialAllocator="TMEF_MaterialAllocator", Propagator=TrigMuonPropagator, LargeMomentumError=0.5, PerigeeAtSpectrometerEntrance=False, ReallocateMaterial=False, TrackSummaryTool=trkSummaryTool, Cleaner=theTrackCleaner,TrackQuery=theTrackQueryNoFit) - - #Inside-out reconstruction - theMuonCandidateTrackBuilderTool = getPublicToolClone("TrigMuonCandidateTrackBuilderTool", "MuonCandidateTrackBuilderTool", MuonTrackBuilder=theTrackBuilderTool,) - insideOutRecoTool = getPublicToolClone("TrigMuonInsideOutRecoTool", "MuonInsideOutRecoTool",MuonTrackBuilder=theTrackBuilderTool,MuonCandidateTrackBuilderTool=theMuonCandidateTrackBuilderTool, VertexContainer="") - if 'Late' in name: - insideOutRecoTool = getPublicToolClone("TrigMuonStauRecoTool", "MuonStauRecoTool",MuonInsideOutRecoTool="TMEF_MuonStauInsideOutRecoTool") - theInsideOutRecoAlg = CfgMgr.MuonCombinedInDetExtensionAlg("TrigMuonInsideOutRecoAlg_"+name,InDetCandidateLocation="InDetCandidates_"+name,MuonCombinedInDetExtensionTools=[insideOutRecoTool],usePRDs=True,HasCSC=MuonGeometryFlags.hasCSC(),HasSTgc=(CommonGeometryFlags.Run() in ["RUN3", "RUN4"]),HasMM=(CommonGeometryFlags.Run() in ["RUN3", "RUN4"])) - - if 'Late' in name: - theInsideOutRecoAlg.TagMap = "stauTagMap" - - #Create the xAOD muons cbMuonName = muNames.EFCBInOutName if 'Late' in name: cbMuonName = cbMuonName+"_Late" - - muonparticlecreator = getPublicToolClone("MuonParticleCreatorInsideOut", "TrackParticleCreatorTool", UseTrackSummaryTool=False, UseMuonSummaryTool=True, KeepAllPerigee=True) - thecreatortool= getPublicToolClone("MuonCreatorTool_triggerInsideOut", "MuonCreatorTool", ScatteringAngleTool="", CaloMaterialProvider='TMEF_TrkMaterialProviderTool', MuonSelectionTool="", FillTimingInformation=False, UseCaloCells=False,TrackQuery=theTrackQueryNoFit,TrackParticleCreator=muonparticlecreator) - if 'Late' in name: - thecreatortool= getPublicToolClone("MuonCreatorTool_LateMu", "MuonCreatorTool", ScatteringAngleTool="", CaloMaterialProvider='TMEF_TrkMaterialProviderTool', MuonSelectionTool="", FillTimingInformation=False, UseCaloCells=False,TrackQuery=theTrackQueryNoFit,TrackParticleCreator=muonparticlecreator,BuildStauContainer=True) - insideoutcreatoralg = CfgMgr.MuonCreatorAlg("MuonCreatorAlgInsideOut_"+name, TagMaps=["muGirlTagMap"],InDetCandidateLocation="InDetCandidates_"+name) - if 'Late' in name: - insideoutcreatoralg.BuildSlowMuon=True - insideoutcreatoralg.TagMaps = ["stauTagMap"] + theInsideOutRecoAlg = MuGirlStauAlg("TrigMuonLateInsideOutRecoAlg_"+name,InDetCandidateLocation="InDetCandidates_"+name) + insideoutcreatoralg = StauCreatorAlg("TrigLateMuonCreatorAlg_"+name, TagMaps=["stauTagMap"],InDetCandidateLocation="InDetCandidates_"+name, + MuonContainerLocation = cbMuonName) else: - insideoutcreatoralg.TagMaps = ["muGirlTagMap"] - insideoutcreatoralg.MuonCreatorTool=thecreatortool - insideoutcreatoralg.MakeClusters=False - insideoutcreatoralg.ClusterContainerName="" - insideoutcreatoralg.MuonContainerLocation = cbMuonName - insideoutcreatoralg.SegmentContainerName = "InsideOutCBSegments" - insideoutcreatoralg.ExtrapolatedLocation = "InsideOutCBExtrapolatedMuons" - insideoutcreatoralg.MSOnlyExtrapolatedLocation = "InsideOutCBMSOnlyExtrapolatedMuons" - insideoutcreatoralg.CombinedLocation = "InsideOutCBCombinedMuon" + theInsideOutRecoAlg = MuonInsideOutRecoAlg("TrigMuonInsideOutRecoAlg_"+name,InDetCandidateLocation="InDetCandidates_"+name) + insideoutcreatoralg = MuonCreatorAlg("TrigMuonCreatorAlgInsideOut_"+name, TagMaps=["muGirlTagMap"],InDetCandidateLocation="InDetCandidates_"+name, + MuonContainerLocation = cbMuonName, SegmentContainerName = "InsideOutCBSegments", ExtrapolatedLocation = "InsideOutCBExtrapolatedMuons", + MSOnlyExtrapolatedLocation = "InsideOutCBMSOnlyExtrapolatedMuons", CombinedLocation = "InsideOutCBCombinedMuon") efAlgs.append(theInsideOutRecoAlg) efAlgs.append(insideoutcreatoralg)