Multi-person whole-body pose estimation using ONNX models with RTMPose and YOLOX detectors.
Install from PyPI:
pip install simple-rtmwOr install from source:
git clone https://github.com/anath2/simple-rtmw
cd simple-rtmw
pip install .import cv2
import numpy as np
from simple_rtmw import Wholebody
from simple_rtmw.draw import draw_annotated_image
# Initialize the model
model = Wholebody(device="cpu") # Use "cuda" or "mps" for GPU
# Load image and run pose estimation
image = cv2.imread("your_image.jpg")
keypoints, scores = model(image)
detection_boxes = model.det_model(image)
# Format results and create visualization
keypoints_with_scores = np.concatenate([keypoints, scores[..., np.newaxis]], axis=-1)
pose_results = model.format_result(keypoints_with_scores)
annotated_image = draw_annotated_image(
image,
detection_boxes=detection_boxes,
pose_results=pose_results
)
# Save the result
cv2.imwrite("output.jpg", annotated_image)| Input Image | Output Image | |
![]() |
➡️ | ![]() |
- Easy to use: No depencencies except OpenCV, ONNX and Numpy
- Multi-platform: CPU, CUDA, MPS (Apple Silicon) support
- Flexible visualization: Customizable drawing with detection boxes and pose annotations
Licensed under the Apache License, Version 2.0. See LICENSE for details.

