Skip to content

Commit da83e62

Browse files
committed
undef min/max
1 parent 9eb3038 commit da83e62

File tree

5 files changed

+7
-2
lines changed

5 files changed

+7
-2
lines changed

MANIFEST

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
# file GENERATED by distutils, do NOT edit
22
setup.py
3+
tinymlgen/__init__.py
34
tinymlgen/tinymlgen.py

dist/tinymlgen-0.1.tar.gz

-1.38 KB
Binary file not shown.

dist/tinymlgen-0.2.tar.gz

1.42 KB
Binary file not shown.

setup.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@
22
setup(
33
name = 'tinymlgen',
44
packages = ['tinymlgen'],
5-
version = '0.1',
5+
version = '0.2',
66
license='MIT',
77
description = 'Generate C code for microcontrollers from Tensorflow models',
88
author = 'Simone Salerno',
99
author_email = '[email protected]',
1010
url = 'https://github.com/eloquentarduino/tinymlgen',
11-
download_url = 'https://github.com/eloquentarduino/tinymlgen/archive/v_01.tar.gz',
11+
download_url = 'https://github.com/eloquentarduino/tinymlgen/archive/v_02.tar.gz',
1212
keywords = ['ML', 'microcontrollers', 'tensorflow', 'machine learning'],
1313
install_requires=[
1414
'tensorflow',

tinymlgen/tinymlgen.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,10 @@ def port(model, optimize=True, variable_name='model_data', pretty_print=False):
2020
c = re.sub(r'(0x..?, ){12}', lambda x: '%s\n\t' % x.group(0), c)
2121
c += '\nconst int %s_len = %d;' % (variable_name, len(bytes))
2222
preamble = '''
23+
// if having troubles with min/max, uncomment the following
24+
// #undef min
25+
// #undef max
26+
2327
#ifdef __has_attribute
2428
#define HAVE_ATTRIBUTE(x) __has_attribute(x)
2529
#else

0 commit comments

Comments
 (0)