# TFLite in OpenMV

<figure><img src="/files/AMyjyUSZE5hSYK9yjF35" alt=""><figcaption></figcaption></figure>

## TensorFlow Lite

TensorFlow is a free and open-source machine learning library. The TensorFlow Lite is a special feature and mainly designed for embedded devices like mobile. This uses a custom memory allocator for execution latency and minimum load. It is also explaining the new file format supported Flat Buffers. TensorFlow Lite takes existing models and converts them into an optimized version within the sort of .tflite file.

<figure><img src="/files/dxeJ5dYSxWmkgbaAIyOS" alt=""><figcaption></figcaption></figure>

The tf module is capable of executing Quantized TensorFlow Lite Models on the OpenMV Cam. The final output .tflite model can be directly loaded and run by your OpenMV Cam. The model and the model’s required sratch RAM must fit within the available frame buffer stack RAM on your OpenMV Cam. Alternatively, you can also load a model onto the MicroPython Heap or the OpenMV Cam frame buffer. However, this significantly limits the model size on all OpenMV Cams.

{% hint style="info" %}
**Reference:** [https://github.com/openmv/tensorflow/blob/master/tensorflow/lite/micro/example](https://github.com/openmv/tensorflow/blob/master/tensorflow/lite/micro/examples/person_detection/training_a_model.md)  [s/person\_detection/training\_a\_model.md](https://github.com/openmv/tensorflow/blob/master/tensorflow/lite/micro/examples/person_detection/training_a_model.md)
{% endhint %}

<br>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://dev.tesa.or.th/tesa-developer/tesa-university-program/rt-thread-iot-os/university-program/edge-ai-workshop/tflite-in-openmv.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
