From 23c26277086c78704a17f0dae86da947816320c0 Mon Sep 17 00:00:00 2001 From: George Gekov Date: Mon, 16 Aug 2021 11:32:10 +0100 Subject: MLECO-2079 Adding the C++ KWS example Signed-off-by: Eanna O Cathain Change-Id: I81899bbfaada32f478c2e2fc6441eabb94d8d0fc --- samples/SpeechRecognition/include/Decoder.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'samples/SpeechRecognition/include/Decoder.hpp') diff --git a/samples/SpeechRecognition/include/Decoder.hpp b/samples/SpeechRecognition/include/Decoder.hpp index 69d97ccf64..9dd484a5d1 100644 --- a/samples/SpeechRecognition/include/Decoder.hpp +++ b/samples/SpeechRecognition/include/Decoder.hpp @@ -46,8 +46,8 @@ namespace asr rowVector.emplace_back(static_cast(contextToProcess[row * rowLength + j])); } - int max_index = std::distance(rowVector.begin(),std::max_element(rowVector.begin(), rowVector.end())); - unfilteredText.emplace_back(this->m_labels.at(max_index)[0]); + int maxIndex = std::distance(rowVector.begin(), std::max_element(rowVector.begin(), rowVector.end())); + unfilteredText.emplace_back(this->m_labels.at(maxIndex)[0]); } std::string filteredText = FilterCharacters(unfilteredText); -- cgit v1.2.1