The official PyTorch implementation of the paper "Coordinate-Based Dual-Constrained Autoregressive MotionGeneration".
Please visit our webpage for more details.
Our model is devloped based on MoMask. You can follow the setup instructions provided there, or refer to the steps below. (The environment setup is the same but we change conda env name to "CDAMD")
Details
conda env create -f environment.yml
conda activate BAMM
pip install git+https://github.com/openai/CLIP.git
We test our code on Python 3.7.13 and PyTorch 1.7.1
pip install -r requirements.txt
We test this installation on Python 3.10
bash prepare/download_models.sh
For evaluation only.
bash prepare/download_evaluator.sh
bash prepare/download_glove.sh
To address the download error related to gdown: "Cannot retrieve the public link of the file. You may need to change the permission to 'Anyone with the link', or have had many accesses". A potential solution is to run pip install --upgrade --no-cache-dir gdown, as suggested on wkentaro/gdown#43. This should help resolve the issue.
Visit [Google Drive] to download the models and evaluators mannually.
You have two options here:
- Skip getting data, if you just want to generate motions using own descriptions.
- Get full data, if you want to re-train and evaluate the model.
(a). Full data (text + motion)
HumanML3D - Follow the instruction in HumanML3D, then copy the result dataset to our repository:
cp -r ../HumanML3D/HumanML3D ./dataset/HumanML3D
KIT-Download from HumanML3D, then place result in ./dataset/KIT-ML
python train_vq.py \
--dataset_name t2m \
--name abs_VQVAE_dp1_b256 \
--batch_size 256 \
--gpu_id 0
python train_AE.py --name AE --dataset_name t2m --batch_size 256 --epoch 50 --lr_decay 0.05
python train_abs_transformer.py --dataset_name t2m --name dual_sparse_token_trans_4_all_quants --batch_size 64 --max_epoch 500 --milestones 50000 --trans cross_attn --latent_dim 512 --ff_size 1024 --n_heads 8 --n_layers 4 --gpu_id 0
Details
python eval_t2m_trans_abs.py --name dual_sparse_token_trans_4 --dataset_name t2m --gpu_id 0 --cond_scale 4 --time_steps 10 --ext your_eval --checkpoints_dir ./log/t2m
If our project is helpful for you, please consider citing :
@misc{ding2026coordinatebaseddualconstrainedautoregressivemotion,
title={Coordinate-Based Dual-Constrained Autoregressive Motion Generation},
author={Kang Ding and Hongsong Wang and Jie Gui and Liang Wang},
year={2026},
eprint={2604.08088},
archivePrefix={arXiv},
primaryClass={cs.CV},
url={https://arxiv.org/abs/2604.08088},
}