am15h / tflite_flutter_plugin

TensorFlow Lite Flutter Plugin
https://pub.dev/packages/tflite_flutter
Apache License 2.0
508 stars 353 forks source link

Classification Model generated with TensorFlow Lite Model Maker - Uint8 input invalid #141

Open mlankenau opened 3 years ago

mlankenau commented 3 years ago

Hi,

I am trying to load an image classification model generated with TensorFlow Lite Model Maker with tflite_flutter 0.9.0.

The shape of the input tensor is: [1, 224, 224, 3] using TfLiteType.uint8

`Unsupported operation: TfLiteType.uint8 is not Supported.

0 ByteConversionUtils.convertBytesToObject (package:tflite_flutter/src/util/byte_conversion_utils.dart:131:5)

1 Tensor._convertBytesToObject (package:tflite_flutter/src/tensor.dart:188:32)

2 Tensor.copyTo (package:tflite_flutter/src/tensor.dart:172:13)

3 Interpreter.runForMultipleInputs (package:tflite_flutter/src/interpreter.dart:196:24)

4 Interpreter.run (package:tflite_flutter/src/interpreter.dart:157:5)

5 _isolateProcess. (package:damage_ai/isolate_interpreter.dart:31:19)

6 _RootZone.runUnaryGuarded (dart:async/zone.dart:1546:10)

7 _BufferingStreamSubscription._sendData (dart:async/stream_impl.dart:341:11)

8 _BufferingStreamSubscription._add (dart:async/stream_impl.dart:271:7)

9 _SyncStreamControllerDispatch._sendData (dart:async/stream_controller.dart:733:19)

10 _StreamController._add (dart:async/stream_controller.dart:607:7)

11 _StreamController.add (dart:async/stream_controller.dart:554:5)

12 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:184:12)`

Is it planned to support these Uint8 input tensors in near future?