google-ai-edge / mediapipe

Cross-platform, customizable ML solutions for live and streaming media.
https://ai.google.dev/edge/mediapipe
Apache License 2.0
27.45k stars 5.15k forks source link

Are there any plans to provide quantized versions of the Multi-class selfie segmentation model? #4706

Open arrufat opened 1 year ago

arrufat commented 1 year ago

MediaPipe Solution (you are using)

v0.10.3

Programming language

typescript/python

Are you willing to contribute it

Yes

Describe the feature and the current behaviour/state

Currently, the Multi-class selfie segmentation model runs relatively slowly on an Android phone compared to a similarly-speced iPhone. I am comparing it using the flagships of the last two years. On the iPhones, the model runs fine in real-time.

However, the delay on Android prevents it from providing a nice and smooth real-time feed with the Multi-class selfie segmentation model.

By adding float16 quantized version, the inference speed improvement on Android phones would allow for smooth real-time inference.

Will this change the current API? How?

No

Who will benefit with this feature?

Anyone using the Multi-class selfie segmentation model, on any platform, not just Android

Please specify the use cases for this feature

I want to apply real-time effects using the result of the Multi-class selfie segmentation model.

Any Other info

No response

kuaashish commented 1 year ago

Hello @lu-wang-g, @schmidt-sebastian,

Could you please look into this feature request. Thank you

fchen09 commented 1 year ago

I got the same problem, too. Android is running much slower.

isrishtisingh commented 1 year ago

Any update on this?? Or is the multiclass selfie segmentation available in any other Tensorflow model format other than tflite?