diff --git a/Reconstruction/MuonIdentification/MuonCombinedAlgs/src/MuonCreatorAlg.cxx b/Reconstruction/MuonIdentification/MuonCombinedAlgs/src/MuonCreatorAlg.cxx index f3214ffaed6ec4dc506324b8171cbe847dd70d2f..8208e007d05d868c36ca8af9d1cd16f69bea79cb 100644 --- a/Reconstruction/MuonIdentification/MuonCombinedAlgs/src/MuonCreatorAlg.cxx +++ b/Reconstruction/MuonIdentification/MuonCombinedAlgs/src/MuonCreatorAlg.cxx @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration */ #include "MuonCreatorAlg.h" @@ -32,8 +32,6 @@ StatusCode MuonCreatorAlg::initialize() { ATH_CHECK(m_muonCreatorTool.retrieve()); - m_copySegs=true; //to have MuGirl and MuidCo segments in the same final collection/container; not needed for trigger or stau - if(m_buildSlowMuon || name().find("Trig")!=std::string::npos) m_copySegs=false; if(m_copySegs) ATH_CHECK(m_muonSegmentConverterTool.retrieve()); else m_muonSegmentConverterTool.disable(); ATH_CHECK(m_muonCollectionName.initialize()); diff --git a/Reconstruction/MuonIdentification/MuonCombinedAlgs/src/MuonCreatorAlg.h b/Reconstruction/MuonIdentification/MuonCombinedAlgs/src/MuonCreatorAlg.h index 435ed11dc521453b49d2dabe2291a0f85e7599e4..7d58ce9e5dc95bdbba688a0738929f175889d2c2 100644 --- a/Reconstruction/MuonIdentification/MuonCombinedAlgs/src/MuonCreatorAlg.h +++ b/Reconstruction/MuonIdentification/MuonCombinedAlgs/src/MuonCreatorAlg.h @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration */ #ifndef MUONCOMBINEDALGS_MUONCREATORALG_H @@ -64,7 +64,7 @@ class MuonCreatorAlg : public AthAlgorithm Gaudi::Property<bool> m_buildSlowMuon{this, "BuildSlowMuon", false}; Gaudi::Property<bool> m_doSA{this, "CreateSAmuons", false}; Gaudi::Property<bool> m_makeClusters{this, "MakeClusters", true}; - bool m_copySegs; + Gaudi::Property<bool> m_copySegs{this, "CopySegments", true}; // Monitoring tool ToolHandle< GenericMonitoringTool > m_monTool { this, "MonTool", "", "Monitoring tool" }; diff --git a/Reconstruction/MuonIdentification/MuonCombinedConfig/python/MuonCombinedReconstructionConfig.py b/Reconstruction/MuonIdentification/MuonCombinedConfig/python/MuonCombinedReconstructionConfig.py index 34fee00f4d16e149d371e096cf5d204165d8b2e7..7d37e901d13250071a4e1d086816577fa8b5a840 100644 --- a/Reconstruction/MuonIdentification/MuonCombinedConfig/python/MuonCombinedReconstructionConfig.py +++ b/Reconstruction/MuonIdentification/MuonCombinedConfig/python/MuonCombinedReconstructionConfig.py @@ -1,4 +1,4 @@ -# Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator from AthenaConfiguration.ComponentFactory import CompFactory @@ -238,6 +238,7 @@ def MuonCreatorAlgCfg( flags, name="MuonCreatorAlg",**kwargs ): if flags.Muon.MuonTrigger: kwargs.setdefault("MakeClusters", False) kwargs.setdefault("ClusterContainerName", "") + kwargs.setdefault("CopySegments", False) if flags.Muon.SAMuonTrigger: kwargs.setdefault("CreateSAmuons", True) kwargs.setdefault("TagMaps", []) @@ -260,6 +261,7 @@ def StauCreatorAlgCfg(flags, name="StauCreatorAlg", **kwargs ): kwargs.setdefault("BuildSlowMuon",1) kwargs.setdefault("ClusterContainerName", "SlowMuonClusterCollection") kwargs.setdefault("TagMaps",["stauTagMap"]) + kwargs.setdefault("CopySegments", False) # if not TriggerFlags.MuonSlice.doTrigMuonConfig: # recordMuonCreatorAlgObjs (kwargs) acc = MuonCreatorAlgCfg(flags, name,**kwargs) diff --git a/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuonCombinedAlgs.py b/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuonCombinedAlgs.py index 1b4a78bccf7711c590f0afa8dbf83b5cbbeb03ff..a54d758463d0092bc9ca09db23b1320d98309799 100644 --- a/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuonCombinedAlgs.py +++ b/Reconstruction/MuonIdentification/MuonCombinedRecExample/python/MuonCombinedAlgs.py @@ -1,4 +1,4 @@ -# Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration from MuonCombinedRecExample.MuonCombinedRecFlags import muonCombinedRecFlags from AthenaCommon.CfgGetter import getPublicTool, getAlgorithm @@ -168,6 +168,7 @@ def MuonCreatorAlg( name="MuonCreatorAlg",**kwargs ): if TriggerFlags.MuonSlice.doTrigMuonConfig: kwargs.setdefault("MakeClusters", False) kwargs.setdefault("ClusterContainerName", "") + kwargs.setdefault("CopySegments", False) return CfgMgr.MuonCreatorAlg(name,**kwargs) @@ -202,6 +203,7 @@ def StauCreatorAlg( name="StauCreatorAlg", **kwargs ): kwargs.setdefault("BuildSlowMuon",1) kwargs.setdefault("ClusterContainerName", "SlowMuonClusterCollection") kwargs.setdefault("TagMaps",["stauTagMap"]) + kwargs.setdefault("CopySegments", False) if not TriggerFlags.MuonSlice.doTrigMuonConfig: recordMuonCreatorAlgObjs (kwargs) return MuonCreatorAlg(name,**kwargs)