BlazePose
MediaPipe BlazePose for full-body pose detection in Unity Engine with NatML.
Installing BlazePose
Add the following items to your Unity project's Packages/manifest.json
:
{
"scopedRegistries": [
{
"name": "NatML",
"url": "https://registry.npmjs.com",
"scopes": ["ai.fxn", "ai.natml"]
}
],
"dependencies": {
"ai.natml.vision.blazepose": "1.0.2"
}
}
Predicting Poses in an Image
First, create the BlazePose pipeline:
var detectorModelData = await MLModelData.FromHub("@natml/blazepose-detector");
var predictorModelData = await MLModelData.FromHub("@natml/blazepose-landmark");
var pipeline = new BlazePosePipeline(detectorModelData, predictorModelData);
Then detect poses in the image:
Texture2D image = ...;
BlazePosePredictor.Pose[] poses = pipeline.Predict(image);
Requirements
Quick Tips
Thank you very much!