cpetig / tflite_micro_compiler

generate tflite micro code which bypasses the interpreter (directly calls into kernels)
Apache License 2.0
76 stars 26 forks source link

[FEATURE]Omit constant initializations from the table #37

Closed cpetig closed 4 years ago

cpetig commented 4 years ago

Don't add constant (same for all nodes/tensors) values to the info arrays but emit a statement into the for loop instead. This saves text space especially for homogenous models.

E.g.: Don't add quantization information to each tensor initialization in a non-quantized model.

alxhoff commented 4 years ago

I'd be happy to look into doing this one as an exercise to get more familiar with the code base

alxhoff commented 4 years ago

I also think that maybe we should add an option to enable the inclusion of them and extra relating helper functions. Just as I have some students that will probably make use of this tool who do not have a lot of programming experience and might benefit from additional helpers. Maybe we can add our own compiler optimization flag?

cpetig commented 4 years ago

Hi Alex, What is your position on the naming unification (https://github.com/cpetig/tflite_micro_compiler/issues/11), in hindsight I feel I should have used a more similar, even though less natural, naming scheme for the two main functions. Best regards  Christof