tensorflow / tflite-micro

Infrastructure to enable deployment of ML models to low-power resource-constrained embedded targets (including microcontrollers and digital signal processors).
Apache License 2.0
1.74k stars 769 forks source link

Adds GetCurrentOperatorIndex to micro_interpreter #2605

Closed DanieleParravicini-Synthara closed 1 week ago

DanieleParravicini-Synthara commented 4 weeks ago

In this way an AOT can add metadata that could then be accessed with the couple GetCurrentSubgraphIndex, GetCurrentOperatorIndex. These can be accessed from tflite::GetMicroContext(context)->graph()

Refers to #2593 BUG=#2593

google-cla[bot] commented 4 weeks ago

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

DanieleParravicini-Synthara commented 2 weeks ago

Hello @rascani, Hope that everything is right. What do you think, is it a good starting point?

On a side note, I see that the CLA is in place, but the CI fails. However, I am not so versed in github actions, but I guess it is missing the label to go further right?

rascani commented 2 weeks ago

Hello @rascani, Hope that everything is right. What do you think, is it a good starting point?

On a side note, I see that the CLA is in place, but the CI fails. However, I am not so versed in github actions, but I guess it is missing the label to go further right?

Looks good to me. I think the CI failure was just due to a flaky synchronization issue. I've triggered another run.

rascani commented 2 weeks ago

@DanieleParravicini-Synthara - Looks like the only failing check is the code style check. I can fix that up if I have permission to modify your branch, or you can do it by running:

tensorflow/lite/micro/tools/ci_build/test_code_style.sh --fix_formatting
DanieleParravicini-Synthara commented 1 week ago

run, reformatted and rebased