Have a nice day.
Currently I am using eiq example tflm_cifar10_cm33_core0 to model on NPU mode. Modeldata is saved in SRAM. Inference time is good. And here is memory configuration. I modified this eiq example for my models with 5 classes
https://docs.nxp.com/bundle/AN14700/page/topics/eiq_enablement.html
But now my model is larger and I want to locate NPU tflite model on external memory. Modeldata is located in Flash. And here is configuration from eiq example tflm_label_image_ext_mem
https://docs.nxp.com/bundle/AN14700/page/topics/imx_rt700_system_details.html
My target is that, I want to keep source code from tflm_cifar10_cm33_core0 (I dont want to create new source code with tflm_label_image_ext_mem), but I want to locate my NPU tflite model on external memory.
My solution that I will change only memory configuration from SRAM to external memory as above images. Is that right? Or I need to change more other configurations.
Hi @nnxxpp ,
Thanks for your clarification.
Please do not use `--use-sequencer` together with external-memory model execution.
For the `tflm_label_image_ext_mem` example, please keep `--fetch-constants-to-sram` and remove `--use-sequencer`, since the model is executed from external memory.
Please try converting the model as below:
Wish it helps you
Best Regards
May
@mayliu1
Hi. This is new issue (not resolved yet). This issue is related to deploy NPU tflite model on external memory (not on SRAM).
Currently, I am using eiq sample tflm_label_image_ext_mem from SDK of MIMRT700. I could successfully run this example. This example is for model mobilenetv1, size=224 and number of classes=1000.
I tried to replace the sample's model by my model (same classification model) but with different number of classes.
I could build, but when running debug, the program is stopping at "Static processing" and did not give result.
There is an message in the above image Unable to save model handle, call neutronModelUnprepare() when done but one NXP's employee said that it is not error. https://community.nxp.com/t5/eIQ-Machine-Learning-Software/eIQ-FAQ/ta-p/1099741
I see that in the case NPU model is located on external memory, we use model with extension .tflite (not header file .h in the case we locate model on SRAM).
I convert model with flag --fetch-constants-to-sram to locate NPU model on external memory like this
Because I did not see any tutorial from NXP to set up and configs (where and how to change source code), so I tried with the above steps, but it did not work.
Could you help me? Thank you.
Hi @nnxxpp ,
Thank you so much for your interest in our products and for using our community.
I apologize for the delayed response.
I noticed that in your previous post, you mentioned that the issue has already been resolved. I’m glad to hear that everything is working now.
Thank you again for your understanding.
Best regards,
May