Skip to content
Advertisement

Tag: tensorflow-lite

Cant convert between a TensorFlowLite tensor with type UINT8 and a Java object of type [[F (which is compatible with the TensorFlowLite type FLOAT32)

I’m trying to run a Tflite model on android, with flutter but i’m getting this error- E/AndroidRuntime(18461): Caused by: java.lang.IllegalArgumentException: Cannot copy to a TensorFlowLite tensor (serving_default_sequential_5_input:0) with 150528 bytes from a Java Buffer with 602112 bytes. E/AndroidRuntime(18461): at org.tensorflow.lite.TensorImpl.throwIfSrcShapeIsIncompatible(TensorImpl.java:418) E/AndroidRuntime(18461): at org.tensorflow.lite.TensorImpl.setTo(TensorImpl.java:139) E/AndroidRuntime(18461): at org.tensorflow.lite.NativeInterpreterWrapper.run(NativeInterpreterWrapper.java:237) E/AndroidRuntime(18461): at org.tensorflow.lite.InterpreterImpl.runForMultipleInputsOutputs(InterpreterImpl.java:135) E/AndroidRuntime(18461): at org.tensorflow.lite.Interpreter.runForMultipleInputsOutputs(Interpreter.java:80) E/AndroidRuntime(18461): at org.tensorflow.lite.InterpreterImpl.run(InterpreterImpl.java:128) E/AndroidRuntime(18461): at org.tensorflow.lite.Interpreter.run(Interpreter.java:80) E/AndroidRuntime(18461): at

Advertisement