Question for put the ML model into MCXN947 based on frdmmcxn947_tflm_cifar10 project

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

Question for put the ML model into MCXN947 based on frdmmcxn947_tflm_cifar10 project

1,325 次查看
BillWen
Contributor II

I have a question for put the ML model into MCXN947 based on frdmmcxn947_tflm_cifar10 project. The following is my model and operator which I used.

 

s_microOpResolver.AddShape();
s_microOpResolver.AddStridedSlice();
s_microOpResolver.AddPack();
s_microOpResolver.AddFill();

s_microOpResolver.AddCustom(tflite::GetString_NEUTRON_GRAPH(),
tflite::Register_NEUTRON_GRAPH());

 

BillWen_1-1723013261981.png

Both LSTM model and LSTM model which converted to TFLite for Neutron cannot initial model on this project, the following is the error log,  "Failed to get registration from op code CUSTOM"

Do you have any experience on this problem or maybe some setting I need to modify?

BillWen_2-1723013536596.png

 

Thanks everyone

Best Regards, Bill Wen

 

标签 (1)
标记 (1)
0 项奖励
回复
5 回复数

1,284 次查看
Joey_z
NXP Employee
NXP Employee

hi,BillWen

Thank you for your interest in NXP Semiconductor products and the opportunity to serve you, I will gladly help you with this.

You are using this SDK code:

frdmmcxn947_tflm_cifar10

 And you replace your own model.

  Could you please give me more details about your own model information, then I can try to reproduce your issues at first.Please help to provide the related files for the issue reproduction.

BR

Xu Zhang

0 项奖励
回复

1,226 次查看
BillWen
Contributor II
Hi XuZhang:

First of all, thanks for your reply. I use a kind of LSTM model to test. I already put my model on the post, what kind of detail information you want?

I have another question is that the NXP MCXN947 only support int8 including all operator and input output data, right?

Thanks
BR, Bill
0 项奖励
回复

1,216 次查看
Joey_z
NXP Employee
NXP Employee

hi,BillWen

The model image you provided is not clear, and I am unable to obtain some important information from it. Could you please provide me with the model file and a clearer, more comprehensive image?

Regarding the error report, it appears that the model contains an operator named "CUSTOM," which is not registered in the eIQ examples. The "CUSTOM" operator indicates that it is a custom-defined operator, or that it should be omitted. Including unregistered operators in the model, especially custom "CUSTOM" operators, will result in an error because they must be implemented by the user themselves. It is essential to avoid including such operators in the final converted model whenever possible.

 

BR

Xu Zhang

 

0 项奖励
回复

1,190 次查看
BillWen
Contributor II

Hi XuZhang:

 

Thanks for your reply.

I upload the model according to the attachment, please check, thanks

quantized_model_uint8_2.tflite is the original one, quantized_model_uint8_2_converted.tflite this one is converted by eIQ tool (convert to tflite for Neutron)

 

Thanks

BR, BillWen

 

0 项奖励
回复

1,126 次查看
Joey_z
NXP Employee
NXP Employee

hi,BillWen

I looked at your model operators via eIQ and they are different from the ones you provided, there are custom operators you didn't include, so it reported the error you mentioned. Also, it turns out that these three custom operators are not supported in TensorFlow Lite Micro.

XuZhang_0-1724207105351.png

FLEX_TENSOR_LIST_RESERVE(), FLEX_TENSOR_LIST_STACK(), and FLEX_TENSOR_LIST_SET_ITEM() are specific operators in the TensorFlow Lite Flex delegate that are used to handle tensor list ( Tensor List) specific operations.TensorFlow Lite Micro does not include a Flex delegate or similar extension mechanism and does not support these three operators.

TensorFlow Lite Micro is a lightweight machine learning library designed for resource-constrained embedded devices such as MCUs. If you need to handle tensor list-like functionality in the TensorFlow Lite Micro environment, avoid complex data structures that require these specific operators when designing your model.

Wish it helps you.

If you still have question about it,please kindly let me know.

BR 

Xu Zhang

0 项奖励
回复