mediapipe icon indicating copy to clipboard operation
mediapipe copied to clipboard

Conversion of TFLite model precision and original model files.

Open Criminal-9527 opened this issue 1 year ago • 2 comments

I have downloaded the hand_landmarks_detector.tflite model, but this is a TensorFlow float16 model. I hope to obtain the original float32 model, or directly get an int8 model is also possible. Is there a way to directly convert it, or can I get the original .pb file of this model? The official documentation of hand_landmark only has .pbtxt files, and they cannot be directly converted into .pb files with TensorFlow's API. Are there any MediaPipe-specific APIs that can convert it?

Criminal-9527 avatar Sep 18 '24 08:09 Criminal-9527

Hello @Criminal-9527

Unfortunately, we do not have any float32 model at our disposal. Regarding the APIs for conversion of .pbtxt files, we are checking with the team for the possibility.

ayushgdev avatar Sep 19 '24 09:09 ayushgdev

Are there any original model files available for use? We ultimately want to get an ONNX format model, but the tools I currently know for converting from TFLite format to ONNX format (such as tflite2onnx) do not support the conversion of float16. The warning is as follows: Data type float16 not supported/tested yet, the generated model may contain errors. Although an ONNX format model will eventually be converted, it is basically unrecognizable. @ayushgdev

Criminal-9527 avatar Sep 22 '24 07:09 Criminal-9527