/ Модель

Характеристики

Лицензия
Своя лицензия
Библиотека
onnxruntime
Опубликована
17 окт 2026

sam-3d-body-onnx

Языковая модель3 профессии

ONNX-конверсия SAM 3D Body оценивает 2D- и 3D-ключевые точки одного человека по обрезанному изображению и его рамке.

0скачиваний за 30 дней0лайковвеса обновлены17 окт 2026

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Публичные оценки

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

В подключённых источниках результатов для этой модели пока нет.

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

SAM 3D Body ViT-H Body Decoder ONNX — конверсия модели Meta `facebook/sam-3d-body-vith`, подготовленная KaleidoLab для редактора поз. Модель принимает обрезанное RGB-изображение одного человека и параметры его рамки, затем оценивает 70 двумерных и трёхмерных ключевых точек тела, включая точки стоп и кистей, а также перенос камеры. Для получения рамки нужен отдельный детектор; детектор, оценка поля зрения и дополнительный декодер уточнения кистей в эту сборку не входят.

Веса модели не изменены; переписаны только несовместимые с ONNX операции. Модель хранит веса в FP16, но вычисления выполняет в FP32. По данным карточки, результаты близки к исходной PyTorch-модели: расхождение ключевых точек составляет до 0,4 пикселя в 2D и до 0,6 мм в 3D. Заявленное время обработки одного человека — около 2 секунд на CPU или 0,2 секунды на DirectML с RTX 3070. Модель рассчитана на одного человека за запуск и требует подготовленного кропа и параметров рамки. Конверсия распространяется по лицензии SAM; условия лицензии следует проверить перед использованием или распространением.

Сценарии применения

  • оценка 3D-позы человека по изображению
  • извлечение 2D-ключевых точек тела и конечностей
  • отслеживание положения стоп и кистей на изображении
  • передача координат позы человека в редактор поз

Ограничения

Модель обрабатывает одного человека за запуск и требует кроп изображения с параметрами рамки, полученными отдельно; детектор людей, оценка поля зрения и декодер уточнения кистей не включены. Лицензия SAM может ограничивать использование и распространение.

Для каких профессий подходит3

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

SAM 3D Body (ViT-H, body decoder) — ONNX

This is an ONNX conversion of Meta's SAM 3D Body (facebook/sam-3d-body-vith), built for KaleidoLab's pose editor. It estimates the 3D pose of one person per run from a cropped image and the person's box. The person box comes from a separate detector; KaleidoLab uses RTMO.

SAM 3D Body is licensed under the SAM License (see LICENSE). This conversion is a derivative of the SAM Materials and is distributed under the same agreement. Anyone who uses or redistributes it agrees to that license.

Source

ItemValue
Checkpointfacebook/sam-3d-body-vith @ f7f4ba4f67739e297f291639afb7c59041745367
model.ckpt SHA-2563b1cb897f4bbd977bf81cbb0b30780a9582681ac642ee112865790ceb4d66056
assets/mhr_model.pt SHA-256352e271a6c42729c68554ceaea0c955e866970160c31e35506d782dc0f7377bc
Codefacebookresearch/sam-3d-body @ b5c765a0d89d789985e186d396315e7590887b94

What was changed

The network weights are unchanged. Only the parts that cannot be exported to ONNX were rewritten so that they compute the same values:

  • MHR body model. The original is a TorchScript module that uses a sparse matrix and skins all 18,439 vertices. export/mhr_lite.py reimplements only what is needed for the 70 keypoints in plain PyTorch: forward kinematics of the 127 joints, plus skinning and pose correctives for the 468 vertices those keypoints use. It follows the math of pymomentum (MIT) and MHR (Apache-2.0). Its keypoints match the TorchScript module within 1e-6.
  • ONNX-incompatible ops. export/sam3db_onnx_patches.py rewrites the following without changing results:
    • assignments to .../boolean indices, rewritten as permutations;
    • the antialiased resize of the camera-ray field, replaced by an exact precomputed grid, because that field is linear in the pixel coordinates.
  • Body decoder only. The optional hand-refinement decoder, the detector and the FOV estimator are not included.
  • Weight storage. Weights are stored as float16 and cast to float32 at the start of the graph, so computation stays in float32. This keeps the file under 2 GB.
  • DirectML. Reshape nodes have allowzero set to 0, because DirectML rejects allowzero=1. No shape in this graph contains 0, so the meaning is the same.

Compared with the original PyTorch model on the same input, the 2D keypoints differ by at most 0.4 px (on an 836 px image), and the 3D keypoints by at most 0.6 mm. This holds on both the CPU and DirectML execution providers. One person takes about 2 s on CPU and 0.2 s on DirectML (RTX 3070).

Export: torch 2.11.0, onnx 1.23.2, onnxscript 0.7.2 (torch.onnx.export(..., dynamo=True, opset_version=18)), onnxruntime 1.31.0. The scripts are in export/. sam3db_export.py expects a checkout of the code revision above with two local edits:

  • .cuda() calls replaced so that it runs on CPU;
  • the input-range assert in prompt_encoder.py removed.

File

FileBytesSHA-256
sam-3d-body-vith-body.onnx1,424,013,951c13492cf96932c6fab67bdab3ce9a983f81743e270ba1adae128d7ff4dff4378

Inputs (one person)

NameShapeMeaning
image[1, 3, 512, 512]RGB crop in 0–1. Warp the image with affine (bilinear, zero border).
bbox_center[1, 2]Crop center in image pixels.
bbox_scale[1, 2]Crop size in image pixels (square).
affine[1, 2, 3]Image → crop transform: [[k, 0, 256 - k*cx], [0, k, 256 - k*cy]] with k = 512 / size.
image_size[1, 2]Original image width, height.
camera[3, 3]Intrinsics. The default used by SAM 3D Body is f = sqrt(w² + h²), c = (w/2, h/2).

Crop from a person box x1, y1, x2, y2:

  1. Take the center c and the size (x2-x1, y2-y1) × 1.25.
  2. Widen the size to an aspect ratio of 0.75, then make it square.

Outputs

NameShapeMeaning
keypoints_2d[1, 70, 2]MHR-70 keypoints in original image pixels. Order: body 0–14 (COCO order without wrists), feet 15–20, right hand 21–41, left hand 42–62, extra 63–69.
keypoints_3d[1, 70, 3]Same keypoints in camera space (m, before cam_t).
cam_t[1, 3]Camera translation.
focal_length[1]Focal length used.
joint_coords[1, 127, 3]MHR skeleton joint positions (m).
joint_rotations[1, 127, 3, 3]MHR global joint rotations.
global_rot[1, 3]Root rotation (Euler ZYX).
body_pose[1, 133]MHR body pose parameters.

License

SAM License. See LICENSE. Notable terms:

  • commercial use is allowed;
  • redistribution must include a copy of the license;
  • use must comply with trade controls and must not be for military, weapons or other prohibited purposes.

The scripts in export/ are provided under the same terms.

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · onnxruntime

Нельзя запустить

Модель выложена только в формате ONNX.

Ревизия весов
d7a99c0

0 моделей