I am looking into the tensorflow implementation of posenet to do pose estimation in real time and also if possible in an offline mode. I am looking into the following repo :
https://github.com/tensorflow/tfjs-models/tree/master/posenet
The keypoints are read out in the following function in the following section of code
export function drawKeypoints(keypoints, minConfidence, ctx, scale = 1) {
for (let i = 0; i < keypoints.length; i++) {
const keypoint = keypoints[i];
if (keypoint.score < minConfidence) {
continue;
}
const {y, x} = keypoint.position;
drawPoint(ctx, y * scale, x * scale, 3, color);
}
}
https://github.com/tensorflow/tfjs-models/blob/master/posenet/demos/demo_util.js
I was looking into the possibility to extract the keypoints to a json file and if it was possible to do so ?
Any tips on this regard would be very helpful .