Path: blob/master/OpenPose/OpenPose_Notebook.ipynb
3092 views
Kernel: Python 3
In [1]:
Specify the model to be used
COCO and MPI are body pose estimation model. COCO has 18 points and MPI has 15 points as output.
HAND is hand keypoints estimation model. It has 22 points as output
Ensure that the model files are available in the folders.
In [ ]:
Let us load an image with multiple people and check what the model sees
In [3]:
Load the network and pass the image through the network
In [4]:
Out[4]:
(1, 44, 46, 46)
Slice a probability map from the output for a specific keypoint and plot the heatmap ( after resizing ) on the image itself
In [5]:
Out[5]:
(-0.5, 1279.5, 1071.5, -0.5)
Similarly plot the affinity map on the image
In [6]:
Out[6]:
(-0.5, 1279.5, 1071.5, -0.5)
Next, we find the keypoints for a image with only single person
In [7]:
Pass it through the network
In [8]:
gather the points and plot the keypoints and the skeleton figure
In [18]:
Out[18]:
<matplotlib.image.AxesImage at 0x7f38b64b5450>
In [ ]: