diff --git a/Trigger/TrigHypothesis/TrigMuonHypoMT/src/TrigMufastHypoTool.cxx b/Trigger/TrigHypothesis/TrigMuonHypoMT/src/TrigMufastHypoTool.cxx index d975a6c2cfd41ac389d3779d84e28da055980d44..602d47ce93aa70f0168e75fcac792631c02249d9 100644 --- a/Trigger/TrigHypothesis/TrigMuonHypoMT/src/TrigMufastHypoTool.cxx +++ b/Trigger/TrigHypothesis/TrigMuonHypoMT/src/TrigMufastHypoTool.cxx @@ -322,18 +322,17 @@ StatusCode TrigMufastHypoTool::inclusiveSelection(std::vector<TrigMufastHypoTool StatusCode TrigMufastHypoTool::multiplicitySelection(std::vector<TrigMufastHypoTool::MuonClusterInfo>& toolInput) const{ HLT::Index2DVec passingSelection( m_ptBins.size() ); - size_t elementIndex{ 0 }; for ( size_t cutIndex=0; cutIndex < m_ptBins.size(); ++cutIndex ) { + size_t elementIndex{ 0 }; for ( auto& i: toolInput ) { if(!m_acceptAll && m_applyOR && !i.passOR) { ATH_MSG_DEBUG("skip due to overap, DecisionID " << m_decisionId ); + elementIndex++; continue; } - elementIndex = &i - &toolInput.front(); - // If muon event has difference DecisionID, it shouldn't apply. if ( TrigCompositeUtils::passed( m_decisionId.numeric(), i.previousDecisionIDs ) ) { if ( decideOnSingleObject( i, cutIndex ) == true ) { @@ -345,6 +344,7 @@ StatusCode TrigMufastHypoTool::multiplicitySelection(std::vector<TrigMufastHypoT } else { ATH_MSG_DEBUG("Not match DecisionID " << m_decisionId ); } + elementIndex++; } // If no object passes the selection, multipul selection should stop. diff --git a/Trigger/TrigHypothesis/TrigMuonHypoMT/src/TrigmuCombHypoTool.cxx b/Trigger/TrigHypothesis/TrigMuonHypoMT/src/TrigmuCombHypoTool.cxx index dc4323fef1c0fed9a47ec5d35e2d9a774edfe370..78c4ede0260031c7e3075f2d7a412f8f1547ef77 100644 --- a/Trigger/TrigHypothesis/TrigMuonHypoMT/src/TrigmuCombHypoTool.cxx +++ b/Trigger/TrigHypothesis/TrigMuonHypoMT/src/TrigmuCombHypoTool.cxx @@ -275,18 +275,17 @@ StatusCode TrigmuCombHypoTool::inclusiveSelection(std::vector<TrigmuCombHypoTool StatusCode TrigmuCombHypoTool::multiplicitySelection(std::vector<TrigmuCombHypoTool::CombinedMuonInfo>& input) const { HLT::Index2DVec passingSelection( m_ptBins.size() ); - size_t elementIndex{ 0 }; for ( size_t cutIndex=0; cutIndex < m_ptBins.size(); ++cutIndex ) { + size_t elementIndex{ 0 }; for ( auto& i: input ) { if(!m_acceptAll && m_applyOR && !i.passOR) { ATH_MSG_DEBUG("skip due to overap, DecisionID " << m_decisionId ); + elementIndex++; continue; } - elementIndex = &i - &input.front(); - // If muon event has difference DecisionID, it shouldn't apply. if ( TrigCompositeUtils::passed( m_decisionId.numeric(), i.previousDecisionIDs ) ) { if ( decideOnSingleObject( i, cutIndex ) == true ) { @@ -298,6 +297,7 @@ StatusCode TrigmuCombHypoTool::multiplicitySelection(std::vector<TrigmuCombHypoT } else { ATH_MSG_DEBUG("Not match DecisionID " << m_decisionId ); } + elementIndex++; } // If no object passes the selection, multipul selection should stop.