google-ai-edge / mediapipe

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

how to get confidence values of each keypoints for hand? #5546

Open JasOleander opened 2 months ago

JasOleander commented 2 months ago

Have I written custom code (as opposed to using a stock example script provided in MediaPipe)

None

OS Platform and Distribution

Ubuntu 22.04

MediaPipe Tasks SDK version

No response

Task name (e.g. Image classification, Gesture recognition etc.)

hand pixel coordinates and its confidence

Programming Language and version (e.g. C++, Python, Java)

python

Describe the actual behavior

using hand_landmarks, there is no confidence of each keypoints but only score for all keypoints.

Describe the expected behaviour

I want to get each confidence for each keypoints to define occlusions.

Standalone code/steps you may have used to try to get what you need

And can get pixel cooridnates by multiplying image width and height?

Other info / Complete Logs

No response

ayushgdev commented 5 days ago

Hello @JasOleander
HandLandmarker do not output any confidence score for each keypoint as the underlying models do not output such information. The model output can be found in the model card present in the models section of HandLandmarker or refer here. Also, the API documentation for HandLandmarkerResult can help to find related information.