Skip to content

Commit fc99c6b

Browse files
fix printf in micro_allocator.cpp
1 parent bcec14e commit fc99c6b

File tree

4 files changed

+15
-3
lines changed

4 files changed

+15
-3
lines changed

library.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"type": "git",
77
"url": "https://github.com/eloquentarduino/EloquentTinyML"
88
},
9-
"version": "0.0.7",
9+
"version": "0.0.10",
1010
"authors": {
1111
"name": "Simone Salerno",
1212
"url": "https://github.com/eloquentarduino"

library.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name=EloquentTinyML
2-
version=0.0.7
2+
version=0.0.10
33
author=Simone Salerno,[email protected]
44
maintainer=Simone Salerno,[email protected]
55
sentence=An eloquent interface to Tensorflow Lite for Microcontrollers

src/EloquentTinyML.h

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,24 @@
11
#pragma once
22

33
#include <Arduino.h>
4+
5+
#ifdef max
6+
#define REDEFINE_MAX
7+
#undef max
8+
#undef min
9+
#endif
10+
411
#include <math.h>
512
#include "tensorflow/lite/version.h"
613
#include "tensorflow/lite/micro/kernels/all_ops_resolver.h"
714
#include "tensorflow/lite/micro/micro_error_reporter.h"
815
#include "tensorflow/lite/micro/micro_interpreter.h"
916

17+
#ifdef REDEFINE_MAX
18+
#define max(a,b) ((a)>(b)?(a):(b))
19+
#define min(a,b) ((a)<(b)?(a):(b))
20+
#endif
21+
1022

1123
namespace Eloquent {
1224
namespace TinyML {

src/tensorflow/lite/micro/micro_allocator.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -415,7 +415,7 @@ TfLiteStatus MicroAllocator::AllocateNodeAndRegistrations(
415415
status = GetRegistrationFromOpCode(opcode, op_resolver, error_reporter_,
416416
&(output[i].registration));
417417
if (status != kTfLiteOk) {
418-
error_reporter_->Report("Failed to get registration from op code % d\n ",
418+
error_reporter_->Report("Failed to get registration from op code %d\n",
419419
opcode);
420420
return status;
421421
}

0 commit comments

Comments
 (0)