summaryrefslogtreecommitdiff
path: root/source/application/main
diff options
context:
space:
mode:
Diffstat (limited to 'source/application/main')
-rw-r--r--source/application/main/Classifier.cc3
-rw-r--r--source/application/main/Mfcc.cc15
-rw-r--r--source/application/main/Profiler.cc5
-rw-r--r--source/application/main/UseCaseCommonUtils.cc4
4 files changed, 16 insertions, 11 deletions
diff --git a/source/application/main/Classifier.cc b/source/application/main/Classifier.cc
index 9a47f3d..c5519fb 100644
--- a/source/application/main/Classifier.cc
+++ b/source/application/main/Classifier.cc
@@ -23,6 +23,7 @@
#include <string>
#include <set>
#include <cstdint>
+#include <inttypes.h>
namespace arm {
namespace app {
@@ -125,7 +126,7 @@ namespace app {
/* Sanity checks. */
if (totalOutputSize < topNCount) {
- printf_err("Output vector is smaller than %u\n", topNCount);
+ printf_err("Output vector is smaller than %" PRIu32 "\n", topNCount);
return false;
} else if (totalOutputSize != labels.size()) {
printf_err("Output size doesn't match the labels' size\n");
diff --git a/source/application/main/Mfcc.cc b/source/application/main/Mfcc.cc
index 9ddcb5d..c8ad138 100644
--- a/source/application/main/Mfcc.cc
+++ b/source/application/main/Mfcc.cc
@@ -19,6 +19,7 @@
#include "PlatformMath.hpp"
#include <cfloat>
+#include <inttypes.h>
namespace arm {
namespace app {
@@ -49,16 +50,16 @@ namespace audio {
char strC[1024];
snprintf(strC, sizeof(strC) - 1, "\n \
\n\t Sampling frequency: %f\
- \n\t Number of filter banks: %u\
+ \n\t Number of filter banks: %" PRIu32 "\
\n\t Mel frequency limit (low): %f\
\n\t Mel frequency limit (high): %f\
- \n\t Number of MFCC features: %u\
- \n\t Frame length: %u\
- \n\t Padded frame length: %u\
+ \n\t Number of MFCC features: %" PRIu32 "\
+ \n\t Frame length: %" PRIu32 "\
+ \n\t Padded frame length: %" PRIu32 "\
\n\t Using HTK for Mel scale: %s\n",
- this->m_samplingFreq, this->m_numFbankBins, this->m_melLoFreq,
- this->m_melHiFreq, this->m_numMfccFeatures, this->m_frameLen,
- this->m_frameLenPadded, this->m_useHtkMethod ? "yes" : "no");
+ this->m_samplingFreq, this->m_numFbankBins, this->m_melLoFreq,
+ this->m_melHiFreq, this->m_numMfccFeatures, this->m_frameLen,
+ this->m_frameLenPadded, this->m_useHtkMethod ? "yes" : "no");
return std::string{strC};
}
diff --git a/source/application/main/Profiler.cc b/source/application/main/Profiler.cc
index 10a828a..5924414 100644
--- a/source/application/main/Profiler.cc
+++ b/source/application/main/Profiler.cc
@@ -208,7 +208,7 @@ namespace app {
}
void printStatisticsHeader(uint32_t samplesNum) {
- info("Number of samples: %i\n", samplesNum);
+ info("Number of samples: %" PRIu32 "\n", samplesNum);
info("%s\n", "Total / Avg./ Min / Max");
}
@@ -224,7 +224,8 @@ namespace app {
for (Statistics &stat: result.data) {
if (printFullStat) {
- info("%s %s: %llu / %.0f / %llu / %llu \n", stat.name.c_str(), stat.unit.c_str(),
+ info("%s %s: %" PRIu64 "/ %.0f / %" PRIu64 " / %" PRIu64 " \n",
+ stat.name.c_str(), stat.unit.c_str(),
stat.total, stat.avrg, stat.min, stat.max);
} else {
info("%s %s: %.0f\n", stat.name.c_str(), stat.unit.c_str(), stat.avrg);
diff --git a/source/application/main/UseCaseCommonUtils.cc b/source/application/main/UseCaseCommonUtils.cc
index 3acf53f..b3653d9 100644
--- a/source/application/main/UseCaseCommonUtils.cc
+++ b/source/application/main/UseCaseCommonUtils.cc
@@ -18,6 +18,8 @@
#include "InputFiles.hpp"
+#include <inttypes.h>
+
namespace arm {
namespace app {
@@ -103,7 +105,7 @@ namespace app {
currentFilename.size(),
dataPsnTxtStartX, yVal, 0);
- info("\t%u => %s\n", i, currentFilename.c_str());
+ info("\t%" PRIu32 " => %s\n", i, currentFilename.c_str());
}
#endif /* NUMBER_OF_FILES > 0 */