Downloads · 30 days
0
m-hamza-mughal/rag-gesture-weights
rag-gesture-weights is a machine learning model from m-hamza-mughal. Use it for the machine learning task on the model card, and read the license before you ship it in a product. It is set up for pytorch. The card lists the license as cc-by-nc-4.0.
Pretrained weights for RAG-Gesture, a retrieval-augmented latent diffusion framework for generating semantically-aware 3D co-speech gestures on the BEAT2 (BEATX) dataset.
Downloads · 30 days
0
Access
Public
Updated Jun 18, 2026
Repo size
6.2 GB
Likes
0
Public
Click a slice to open those files.
.pth3.6 GB · 58%
From the Hugging Face model README
Pretrained weights for RAG-Gesture, a retrieval-augmented latent diffusion framework for generating semantically-aware 3D co-speech gestures on the BEAT2 (BEATX) dataset.
Paper: Retrieving Semantics from the Deep: an RAG Solution for Gesture Synthesis (CVPR 2025). Code: https://github.com/m-hamza-mughal/RAG-Gesture
| Path | Description |
|---|---|
vae/ | Four part-specific Transformer VAEs (upper / hands / face / lower+translation) used as the motion encoder/decoder. Each chunks 15 frames at 15 fps into one 512-d latent. |
diffusion/ | Trained RAG-Gesture diffusion transformer checkpoint (base_beatx_len150fps15_finalweights/). |
assets_deps/ | SMPL-X model files required by the dataloader and decoder for converting axis-angle poses to joints. |
RAG-Gesture denoises a body-part-factored latent sequence conditioned on text (BERT), audio (wav2vec2), and a speaker embedding. At inference, retrieval strategies — discourse-relation & gesture-type — pull semantically-matched motion clips from a database of training samples. The retrieved latents are injected into the diffusion process through DDIM inversion + per-step insertion guidance, biasing the denoiser toward the retrieved semantics without sacrificing the base model's fluency.
Key design choices:
[sep] token between parts, all concatenated along the time axis.x_t against the per-timestep inverted retrieval latent.# 1. Clone the code
git clone https://github.com/m-hamza-mughal/RAG-Gesture
cd RAG-Gesture
pip install -r requirements.txt
# 2. Pull these weights + SMPL-X deps
python tools/download_weights.py
# 3. Pull the BEAT2 dataset + RAG-Gesture annotations
python tools/download_annotations.py
# 4. Run RAG-guided inference (discourse retrieval)
PYTHONPATH=".":$PYTHONPATH python tools/visualize.py \
experiments/diffusion/base_beatx_len150fps15_finalweights/basegesture_len150_beat.py \
experiments/diffusion/base_beatx_len150fps15_finalweights/epoch_64.pth \
--retrieval_method discourse_guidance_test \
--use_retrieval --use_inversion --use_insertion_guidance \
--guidance_iters decreasing_till_25
See the GitHub README for training, evaluation, long-form synthesis, and ablation commands.
@InProceedings{mughal2024raggesture,
title = {Retrieving Semantics from the Deep: an RAG Solution for Gesture Synthesis},
author = {M. Hamza Mughal and Rishabh Dabral and Merel C. J. Scholman and Vera Demberg and Christian Theobalt},
booktitle = {Computer Vision and Pattern Recognition (CVPR)},
year = {2025}
}
Built on EMAGE / PantoMatrix and ReMoDiffuse.