feat(data-only-viz): SMPLer-X fork + submodule
Fork electron-rare/SMPLer-X (S-Lab License 1.0, non-comm seulement) ajoute en git submodule a third_party/SMPLer-X. Setup script utilise le submodule au lieu de cloner upstream. pyproject : nouvel extra 'smplerx' (torch + mmcv-lite + ultralytics + smplx + timm). NOTICE.md documente la posture non-commerciale heritee de Multi-HMR et SMPLer-X. Le portage inference ARM Mac est l'etape suivante : SMPLer-X vendorise sa propre mmpose (transformer_utils/mmpose), donc seul mmcv.Config a besoin d'un substitut (mmcv-lite). Le detecteur mmdet sera remplace par YOLO Ultralytics. NOT YET DONE: smpler_x_worker.py (model load + inference, ~1 j) ; bench camera ; integration main.py.
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
[submodule "third_party/SMPLer-X"]
|
||||
path = third_party/SMPLer-X
|
||||
url = https://github.com/electron-rare/SMPLer-X.git
|
||||
@@ -0,0 +1,40 @@
|
||||
# AV-Live Third-Party Notices
|
||||
|
||||
AV-Live includes or depends on the following third-party works,
|
||||
which are licensed under their own terms.
|
||||
|
||||
## Body Mesh Recovery Models
|
||||
|
||||
### Multi-HMR (NAVER, 2025)
|
||||
|
||||
- **License**: NAVER Non-Commercial License
|
||||
(https://github.com/naver/multi-hmr/blob/main/LICENSE.txt)
|
||||
- **Use**: Non-commercial only. Body mesh recovery from camera input.
|
||||
- **Integration**: model checkpoint downloaded at runtime to
|
||||
`~/.cache/av-live-multihmr/`. No source code vendored.
|
||||
|
||||
### SMPLer-X (S-Lab, ECCV 2024)
|
||||
|
||||
- **License**: S-Lab License 1.0
|
||||
(`third_party/SMPLer-X/LICENSE` after submodule init)
|
||||
- **Use**: Non-commercial only. Whole-body mesh recovery (SMPL-X).
|
||||
- **Integration**: vendored as git submodule at
|
||||
`third_party/SMPLer-X` (fork `electron-rare/SMPLer-X`, kept in
|
||||
sync with `caizhongang/SMPLer-X` or its current upstream).
|
||||
- **Modifications in fork**: minimal patches for ARM macOS Python
|
||||
3.14 inference (replace mmdet detector with Ultralytics YOLO,
|
||||
shim `mmcv.Config` via `mmcv-lite`).
|
||||
|
||||
## Implication
|
||||
|
||||
**AV-Live integrates non-commercial-only model code from Multi-HMR
|
||||
and SMPLer-X.** Commercial deployment (paid performances, packaged
|
||||
installations sold to clients) requires either :
|
||||
|
||||
1. Obtaining commercial licenses from NAVER and S-Lab respectively, OR
|
||||
2. Replacing both integrations with MIT/Apache-licensed alternatives
|
||||
(see `docs/superpowers/plans/2026-05-13-modern-body-mesh-survey.md`
|
||||
for candidates like Fast-SAM-3D-Body which is MIT-licensed).
|
||||
|
||||
The AV-Live source code itself (sound_algo, oscope-of, launcher,
|
||||
data_only_viz integration glue) is under GPL-3.0 (see root LICENSE).
|
||||
@@ -64,6 +64,25 @@ multihmr = [
|
||||
"pillow>=10.0",
|
||||
"tqdm>=4.65",
|
||||
]
|
||||
# SMPLer-X (S-Lab, ECCV 2024, NON-COMMERCIAL). Code source vendu
|
||||
# via git submodule third_party/SMPLer-X (fork electron-rare).
|
||||
# mmcv-lite suffit pour Config (le repo vendorise sa propre mmpose).
|
||||
# Le detector mmdet est remplace par YOLO Ultralytics (extras pose).
|
||||
smplerx = [
|
||||
"torch>=2.4",
|
||||
"torchvision>=0.19",
|
||||
"smplx>=0.1.28",
|
||||
"mmcv-lite>=2.1",
|
||||
"ultralytics>=8.3",
|
||||
"opencv-python>=4.10",
|
||||
"numpy>=1.26,<2",
|
||||
"scipy>=1.13",
|
||||
"einops>=0.8",
|
||||
"pillow>=10.0",
|
||||
"tqdm>=4.65",
|
||||
"yacs>=0.1.8",
|
||||
"timm>=1.0",
|
||||
]
|
||||
|
||||
[tool.uv]
|
||||
package = false
|
||||
|
||||
Executable
+57
@@ -0,0 +1,57 @@
|
||||
#!/usr/bin/env bash
|
||||
# Setup SMPLer-X-S inference pipeline pour ARM Mac (M5).
|
||||
#
|
||||
# Stratégie : SMPLer-X vendorise sa propre copie de mmpose dans
|
||||
# transformer_utils/mmpose/, donc on n'a besoin que de :
|
||||
# - mmcv-lite (pour `from mmcv import Config`)
|
||||
# - smplx (pour decode SMPL-X params)
|
||||
# - YOLO/Ultralytics (déjà dans extras pose) pour body detection
|
||||
#
|
||||
# On évite mmdet/mmcv-full/mmpose pip installs qui plantent sur ARM
|
||||
# Python 3.14.
|
||||
set -euo pipefail
|
||||
|
||||
CACHE="$HOME/.cache/av-live-smplerx"
|
||||
# Repo source = git submodule electron-rare/SMPLer-X (fork S-Lab 1.0)
|
||||
# initialise au niveau du repo AV-Live racine.
|
||||
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
|
||||
REPO_ROOT="$(cd "$SCRIPT_DIR/../.." && pwd)"
|
||||
REPO="$REPO_ROOT/third_party/SMPLer-X"
|
||||
|
||||
mkdir -p "$CACHE/checkpoints" "$CACHE/models/smplx"
|
||||
|
||||
if [ ! -d "$REPO/main" ]; then
|
||||
echo "==> Init git submodule SMPLer-X"
|
||||
( cd "$REPO_ROOT" && git submodule update --init third_party/SMPLer-X )
|
||||
fi
|
||||
|
||||
CKPT="$CACHE/checkpoints/smpler_x_s32.pth.tar"
|
||||
if [ ! -f "$CKPT" ]; then
|
||||
echo "==> Telechargement SMPLer-X-S checkpoint (ViT-S, ~150 MB)"
|
||||
curl -fL --progress-bar \
|
||||
"https://huggingface.co/caizhongang/SMPLer-X/resolve/main/smpler_x_s32.pth.tar" \
|
||||
-o "$CKPT" \
|
||||
|| { echo "ERREUR download checkpoint"; exit 1; }
|
||||
fi
|
||||
|
||||
SMPLX="$CACHE/models/smplx/SMPLX_NEUTRAL.npz"
|
||||
SHARED="$HOME/.cache/av-live-multihmr/models/smplx/SMPLX_NEUTRAL.npz"
|
||||
if [ ! -f "$SMPLX" ]; then
|
||||
if [ -f "$SHARED" ]; then
|
||||
echo "==> Symlink SMPLX_NEUTRAL.npz depuis cache Multi-HMR"
|
||||
ln -sf "$SHARED" "$SMPLX"
|
||||
else
|
||||
echo ""
|
||||
echo "MANUEL REQUIS :"
|
||||
echo " 1. Inscrivez-vous sur https://smpl-x.is.tue.mpg.de/"
|
||||
echo " 2. Telechargez 'SMPL-X v1.1 (NPZ + PKL)'"
|
||||
echo " 3. Extraire SMPLX_NEUTRAL.npz vers : $SMPLX"
|
||||
echo " OU lance d'abord scripts/setup_multihmr.sh et symlink."
|
||||
fi
|
||||
fi
|
||||
|
||||
echo "Setup OK. Cache : $CACHE"
|
||||
echo "Files :"
|
||||
ls -lh "$CACHE/checkpoints/" 2>/dev/null
|
||||
echo ""
|
||||
echo "Next: ajouter 'mmcv-lite' au pyproject.toml et 'uv sync --extra smplerx'"
|
||||
+1
Submodule third_party/SMPLer-X added at 064baef0e4
Reference in New Issue
Block a user