Hey, I wish to run a
.tflite regression model on Arduino Nicla Vision.
I actually process the image in some way and then get a particular number. I have trained this number for some parameters based on training data. Now I wish to create a script where I could process the image first and then run the NN based regression.
I found that the
tflite-micro does provide an example like hello world where I could run the regression model. But, I think it outputs the usage of the model in C++ and not in micropython.
Further, there is another repository tensorflow-micropython-examples that ports the same examples given in
tflite-micro to micropython.
Could you guys please guide me on how I could integrate the tensorflow-micropython-examples repository with micropython in OpenMV IDE or should I use the c++ implementation of the regression model given
tflite-micro? Further, I wish to deploy this on Nicla-Vision. Is there a way I could relate the source file written in C++ with openmv so that my program could run as main.py?
Hi, you need to use Edge Impulse to generate a model to deploy on the OpenMV cam.
Hey, wont edge impulse model directly expect the input to be an image? the
tf module in openmv documentation describes only detection and classification methods. Nothing about prediction on continuous values for a regression based model on some numerical value.
Edge Impulse supports regression models itself.
If you want to execute tf models that aren’t taking an image in we don’t have support for that now.
Hey, could you please guide me on how can I integrate tensorflow-micropython-examples with OpenMV? It would be really helpful.
I was able to make a model and build the model for NICLAV which doesn’t take images as input. It’s just now am not able to deploy it on Nicla due to the availability of
tf.classify function which only takes images as input
Could you please notify whenever you build support for the execution of models that don’t take images as input?
Hi, what’s the type of data you want to pass? I can just add non-image data support. E.g. a linear array.
Hey, I am really really grateful to you!
Currently, my model preprocesses that data in some way in order to give a python list of 36 numbers(dtype int). This 36-element 1D array is then given to a
.tflite model trained against some values.
This way I save a lot of space. Involving the Conv2D layer in the model takes up a lot of space while building the
.tflite model I end up with errors related to memory overflow
Also, I would really appreciate it if you could allow me to contribute in some way to this, maybe adding a test script or an example or updating some documentation about this.
Hi, another user asked about this. Please create a github ticket to add support for linear data models and I can knock this out quickly.