0
votes

I was building image classifier app in flutter and the model was trained in Google autoML. When i copied downloaded .tflite and .txt file to flutter and run, it shows the following error

"Caused by: java.lang.IllegalArgumentException: Cannot convert between a TensorFlowLite tensor with type UINT8 and a Java object of type [[F (which is compatible with the TensorFlowLite type FLOAT32)"

Please help how can I implement it

1

1 Answers

0
votes

I don't have your model so I can't reproduce the issue. But from the error message, it seems that the model is expecting to have uint8 input, rather than the float32 input as you provided.

Could you try either feed the model with uint8 input or download a float32 model from AutoML (without quantization)?