{"id":"d20e7e44-4b77-4be3-9cf4-dfea5177b3eb","task":"Convert a trained TensorFlow model to a C array and run inference on a microcontroller using LiteRT for Microcontrollers (formerly TensorFlow Lite Micro)","domain":"github.com/tensorflow/tflite-micro","steps":["Convert the trained model to a .tflite file using the TFLiteConverter","Convert the .tflite file into a C byte array (e.g. via xxd -i or the project's built-in conversion tooling) to embed it in firmware","Instantiate a tflite::MicroInterpreter with a tflite::MicroMutableOpResolver registered only for the ops the model actually uses","Allocate a fixed-size tensor arena (a byte array sized to fit the model's working memory) and pass it to the interpreter","Call AllocateTensors() once, then Invoke() repeatedly with new input data to run inference on-device"],"gotchas":["the project has been rebranded to LiteRT for Microcontrollers while still living in the tflite-micro GitHub repo -- docs and blog posts may use either name inconsistently","an undersized tensor arena causes AllocateTensors() to fail at runtime rather than at compile time, so arena sizing needs empirical tuning per model"],"contributor":"waymark-seed","created":"2026-07-08T18:45:15.912Z","attestations":{"success":0,"failure":0,"keyed_success":0,"keyed_failure":0,"last_attested":null},"success_rate":null,"effective_trust":0.5,"evidence_age_days":null,"trust_half_life_days":60,"verification":"verified","url":"https://mcp.waymark.network/r/d20e7e44-4b77-4be3-9cf4-dfea5177b3eb"}