Skip to content

jjd1123/Skeleton2Stage

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Skeleton2Stage: Reward-Guided Fine-Tuning for Physically Plausible Dance Generation

   

Jidong Jia, Youjian Zhang, Huan Fu, Dacheng Tao

Shanghai Jiao Tong University

Abstract

Official implementation of paper: "Skeleton2Stage: Reward-Guided Fine-Tuning for Physically Plausible Dance Generation". Prior dance generation methods often operate on sparse skeletons and overlook geometric constraints of the human body, leading to artifacts such as penetration and foot sliding. We propose a reward-guided fine-tuning framework that aligns generated motions with body geometry, improving physical plausibility.

method

Table of Contents

News

[Febrary 2, 2026] Training code for imitation policy released.

[January 30, 2026] Training and Evaluation code for EDGE released.

TODOs

  • Supports for training on GPU newer than A100.

  • Installation guidance

  • Release training imitation policy code.

  • Release training code.

  • Release evaluation code.

  • Release rendering code.

  • Release guidance for custom models and rewards.

Introduction

We identify and address a critical yet often-overlooked gap between skeleton-based motion generation and mesh-level body visualization. Specifically, we leverage a physics-based humanoid controller to evaluate the physical plausibility of generated motions and convert its feedback into a reward that penalizes violations of physical laws, especially constraints arising from human body geometry. Combined with complementary reward signals, this reward design enables us to fine-tune a generative model with reinforcement learning to produce motions that remain physically plausible when visualized on a human body mesh.

Docs

Current Results on EDGE

All evaluation is done using the mean SMPL body shape.

results

Installation

To create the environment, follow the following instructions:

  1. Clone the project:

    git clone https://github.com/jjd1123/Skeleton2Stage.git
  2. Create new conda environment and install pytroch:

    conda create -n isaac python=3.8
    pip install -r requirement.txt
  3. Download and setup Isaac Gym.

  4. Download the MuJoCo version 2.1 for Linux.

  5. Install torch-mesh-isect for body penetration rate evaluation.

  6. Configure your paths in environment.sh.
    For a cleaner project layout, you can place Isaac Gym, MuJoCo, and torch-mesh-isect under the environment/ directory.

  7. This repository additionally depends on the following libraries, which may require special installation procedures:

  1. Place the smpl files under body_models/ like following,

    body_models/
    ├── README.md            # This guide file
    │
    ├── smpl/
    │   ├── J_regressor_extra.npy
    │   ├── kintree_table.pkl
    │   ├── smplfaces.npy
    │   ├── SMPL_FEMALE.pkl
    │   ├── SMPL_MALE.pkl
    │   └── SMPL_NEUTRAL.pkl
    │
    ├── smplh/
    │   ├── female/
    │   │   └── model.npz
    │   ├── male/
    │   │   └── model.npz
    │   └── neutral/
    │       └── model.npz
    │
    └── smplx/
        ├── female/
        │   └── model.npz
        ├── male/
        │   └── model.npz
        └── neutral/
            └── model.npz

Evaluation

Evaluation Pipeline

Before evaluation, make sure you have:

(1) the correct settings in metric computation scripts, and

(2) the correct model in Line 56 in EDGE.py.

cd code/rl_finetune
bash eval.sh exp_name epoch_num motion_save_root ckpt_root cached_music_features

Evaluation on Other Models

Coming soon!

Training

Data Processing

To fine-tune the generative model, you need the following:

  1. A base checkpoint of the generative model;
  2. Conditioning data for training-time sampling;
  3. A checkpoint of the trained imitation policy.

In this section, we provide data (preprocessed data and the pretrained imitation policy) for a minimal example: finetuning EDGE on AIST++. You can directly run following scripts:

cd code/rl_finetune
# download EDGE checkpoint.
bash download_mode.sh
# download preprocessed data of AIST++ and the pretrained imitation policy.
bash download_data.sh
  • Note: We use DVC for dataset version control. Please follow the README in the downloaded data directory for a quick setup.

We will also explain how to prepare your own datasets and pre-trained models below.

1) Pretrain a base generative model

You can follow the instructions from:

2) Pretrain an imitation policy

Follow the instructions in Training Imitation Policy.

3) Prepare the conditioning data

Coming soon!

Training Imitation Policy

  1. Prepare the Expert Dataset

    First, prepare the expert dataset for imitation policy training by following the guide in the Vid2player3d README.

  2. Run the Training Script

    Once the dataset is ready, start the training by executing the train.sh script.

    cd code/pretrain/vid2player3d
    bash train.sh PATH_TO_VID2PLAYER3D
    • Customization: You can modify the training strategy by changing the configuration file and the execution order within train.sh.

RLFT for EDGE

(1) Change the weight of different rewards in reward.yaml.

(2) Set the correct model for finetuning in Line 56 in EDGE.py.

cd code/rl_finetune
bash run.sh exp_name gpu_parallel_num epoch_num batch_size

RLFT for Other Models

Coming soon!

Rendering

Coming soon!

Trouble Shooting

Supporting GPU types newer than A100

Coming soon!

Citation

If you find this work useful for your research, please cite our paper:

@misc{jia2026skeleton2stagerewardguidedfinetuningphysically,
      title={Skeleton2Stage: Reward-Guided Fine-Tuning for Physically Plausible Dance Generation}, 
      author={Jidong Jia and Youjian Zhang and Huan Fu and Dacheng Tao},
      year={2026},
      eprint={2602.13778},
      archivePrefix={arXiv},
      primaryClass={cs.CV},
      url={https://arxiv.org/abs/2602.13778}, 
}   

References

This repository is built on top of the following amazing repositories:

Please follow the lisence of the above repositories for usage.

About

Official Implementation of Skeleton2Stage

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published