I trained a custom yolo5 model, and then converted it to tflite. Model works completely fine in both stages. I want to use this model in Flutter.
Right now I am using Google ML kit models, which works perfectly fine, but when I replace their model with my tflite file, it gives an error of
[ERROR:flutter/lib/ui/ui_dart_state.cc(198)] Unhandled Exception: PlatformException(ObjectDetectionError, com.google.mlkit.common.MlKitException: Failed to initialize detector. Input tensor has type kTfLiteFloat32: it requires specifying NormalizationOptions metadata to preprocess input images., null, null)
Any lead how I can solve this issue?