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

Merge branch 'egammaRecBuilder_takes_anyCluster' into 'master'

egammaRecBuilder can work with any type of clusters, not just topo

See merge request atlas/athena!46687
parents 6083398c 4c22a11d
No related branches found
No related tags found
No related merge requests found
Showing
with 16 additions and 16 deletions
......@@ -15,7 +15,7 @@ from egammaTools.egammaToolsFactories import \
egammaRecBuilder = AlgFactory(
egammaAlgsConf.egammaRecBuilder,
name='egammaRecBuilder',
InputTopoClusterContainerName=jobproperties.egammaRecFlags.egammaTopoClusterCollection(),
InputClusterContainerName=jobproperties.egammaRecFlags.egammaTopoClusterCollection(),
egammaRecContainer=egammaKeys.EgammaRecKey(),
# Builder tools
TrackMatchBuilderTool=EMTrackMatchBuilder,
......
......@@ -35,7 +35,7 @@ def egammaRecBuilderCfg(
"egammaRecContainer",
flags.Egamma.Keys.Internal.EgammaRecs)
kwargs.setdefault(
"InputTopoClusterContainerName",
"InputClusterContainerName",
flags.Egamma.Keys.Internal.EgammaTopoClusters)
egrecAlg = egammaRecBuilder(name, **kwargs)
......
......@@ -28,7 +28,7 @@ StatusCode
egammaRecBuilder::initialize()
{
// First the data handle keys
ATH_CHECK(m_inputTopoClusterContainerKey.initialize());
ATH_CHECK(m_inputClusterContainerKey.initialize());
ATH_CHECK(m_egammaRecContainerKey.initialize());
// retrieve track match builder
......@@ -86,13 +86,13 @@ egammaRecBuilder::execute(const EventContext& ctx) const
ATH_MSG_DEBUG("Executing egammaRecBuilder");
SG::ReadHandle<xAOD::CaloClusterContainer> topoclusters(
m_inputTopoClusterContainerKey, ctx);
m_inputClusterContainerKey, ctx);
// validity check is only really needed for serial running. Remove when MT is
// only way.
if (!topoclusters.isValid()) {
ATH_MSG_ERROR("Could not retrieve cluster container:"
<< m_inputTopoClusterContainerKey.key());
<< m_inputClusterContainerKey.key());
return StatusCode::FAILURE;
}
......
......@@ -24,7 +24,7 @@ class IEMConversionBuilder;
@brief Produces the initial egammaRec objects as a step of the egamma supercluster algorithms.
Input container:
- InputTopoClusterContainerName (default=egammaTopoCluster): topo cluster to be used to build
- InputClusterContainerName (default=egammaTopoCluster): topo cluster to be used to build
the egammaRec
Output container:
- egammaRecContainer (default=EMTrackMatchBuilder)
......@@ -33,7 +33,7 @@ class IEMConversionBuilder;
- TrackMatchBuilderTool (default=EMTrackMatchBuilder)
- ConversionBuilderTool (default=EMConversionBuilder)
The algorithm produces an egammaRec for each topo cluster where the matched tracks and vertices
The algorithm produces an egammaRec for each cluster where the matched tracks and vertices
are linked. These two matchings are done depending on the flags doTrackMatching and doConversions,
by default true.
*/
......@@ -50,9 +50,9 @@ private:
/** @brief retrieve ConversionBuilderTool (EMConversionBuilder) **/
StatusCode RetrieveEMConversionBuilder();
/** @brief Key for the topo cluster input collection */
SG::ReadHandleKey<xAOD::CaloClusterContainer> m_inputTopoClusterContainerKey{
SG::ReadHandleKey<xAOD::CaloClusterContainer> m_inputClusterContainerKey{
this,
"InputTopoClusterContainerName",
"InputClusterContainerName",
"egammaTopoCluster",
"Name of input cluster container"
};
......
......@@ -62,7 +62,7 @@ def precisionElectronRecoSequence(RoIs, ion=False):
TrigEgammaRecAlgo = TrigEgammaRecElectron("TrigEgammaRecElectron_noGSF" + tag)
thesequence += TrigEgammaRecAlgo
TrigEgammaRecAlgo.TrackMatchBuilderTool = TrigEMTrackMatchBuilder
TrigEgammaRecAlgo.InputTopoClusterContainerName = caloClusters
TrigEgammaRecAlgo.InputClusterContainerName = caloClusters
## TrigElectronSuperClusterBuilder_noGSF ##
TrigSuperElectronAlgo = TrigElectronSuperClusterBuilder("TrigElectronSuperClusterBuilder_noGSF" + tag)
......
......@@ -69,7 +69,7 @@ def precisionElectronRecoSequence_GSF(RoIs):
TrigEgammaRecAlgo_GSF = TrigEgammaRecElectron("TrigEgammaRecElectron_GSF")
thesequence_GSF += TrigEgammaRecAlgo_GSF
TrigEgammaRecAlgo_GSF.TrackMatchBuilderTool = TrigEMTrackMatchBuilder_GSF
TrigEgammaRecAlgo_GSF.InputTopoClusterContainerName = precisionCaloMenuDefs.precisionCaloClusters
TrigEgammaRecAlgo_GSF.InputClusterContainerName = precisionCaloMenuDefs.precisionCaloClusters
## TrigElectronSuperClusterBuilder_GSF ##
TrigSuperElectronAlgo_GSF = TrigElectronSuperClusterBuilder("TrigElectronSuperClusterBuilder_GSF")
......
......@@ -57,7 +57,7 @@ def precisionElectronRecoSequence_LRT(RoIs):
TrigEgammaRecAlgo = TrigEgammaRecElectron("TrigEgammaRecElectron_LRT")
thesequence += TrigEgammaRecAlgo
TrigEgammaRecAlgo.TrackMatchBuilderTool = TrigEMTrackMatchBuilder
TrigEgammaRecAlgo.InputTopoClusterContainerName = precisionCaloMenuDefs_LRT.precisionCaloClusters
TrigEgammaRecAlgo.InputClusterContainerName = precisionCaloMenuDefs_LRT.precisionCaloClusters
## TrigElectronSuperClusterBuilder_LRT ##
TrigSuperElectronAlgo = TrigElectronSuperClusterBuilder("TrigElectronSuperClusterBuilder_LRT")
......
......@@ -26,7 +26,7 @@ from egammaRec.Factories import AlgFactory, FcnWrapper
"""Configuring egammaRecBuilder """
TrigEgammaRecElectron = AlgFactory( egammaAlgsConf.egammaRecBuilder,
name = 'TrigEgammaRecElectron',
InputTopoClusterContainerName= "precisionCaloCluster",
InputClusterContainerName= "precisionCaloCluster",
egammaRecContainer= TrigEgammaKeys.EgammaRecKey,
doConversions = False,
doAdd= False,
......
......@@ -174,7 +174,7 @@ def _precisionElectronSeq(flags, doIDperf=False):
def TrigEgammaRecElectronCfg(flags, name='TrigEgammaRecElectron_noGSF'):
acc = ComponentAccumulator()
electronRec = CompFactory.egammaRecBuilder( name,
InputTopoClusterContainerName= 'HLT_CaloEMClusters',
InputClusterContainerName= 'HLT_CaloEMClusters',
egammaRecContainer= TrigEgammaKeys.EgammaRecKey,
doConversions = False,
TrackMatchBuilderTool = recoAcc.popToolsAndMerge(TrigEMTrackMatchBuilderToolCfg(flags)) )
......
......@@ -41,7 +41,7 @@ def precisionPhotonRecoSequence(RoIs):
# Add to the sequence the three steps:
# - TrigEgammaBuilder, TrigPhotonSuperClusters, TrigTopoEgammaPhotons
TrigEgammaAlgo = TrigEgammaRecPhoton()
TrigEgammaAlgo.InputTopoClusterContainerName = precisionCaloMenuDefs.precisionCaloClusters
TrigEgammaAlgo.InputClusterContainerName = precisionCaloMenuDefs.precisionCaloClusters
thesequence += TrigEgammaAlgo
trigPhotonAlgo = TrigPhotonSuperClusterBuilder()
......
......@@ -30,7 +30,7 @@ from TriggerMenuMT.HLTMenuConfig.Egamma.PrecisionCaloMenuSequences import precis
# Factory for egamaRecBuilder/TrigEgammaRecPhoton
TrigEgammaRecPhoton = AlgFactory( egammaAlgsConf.egammaRecBuilder,
name = 'TrigEgammaRecPhoton' ,
InputTopoClusterContainerName = precisionCaloMenuDefs.precisionCaloClusters, # Use as input, the clusters made by precisionCalo
InputClusterContainerName = precisionCaloMenuDefs.precisionCaloClusters, # Use as input, the clusters made by precisionCalo
egammaRecContainer=TrigEgammaKeys.EgammaRecKey,
doTrackMatching = False,
doConversions = 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