Skip to content

Latest commit

 

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Playstyles Humanoid

Python 3.10.18 TensorFlow 2.14.1 Reverb 0.14.0

assets/Humanoid-with-styles.gif

Humanoid codebase part of the Coachable agents for interactive gameplay paper that can be found here.

Setup instructions

This codebase was run and tested on a Linux machine with 535 Nvidia drivers with 32 Gb of memory. To install and run this code, please follow the instructions below.

Requirements

Operating Systems

The following project is only compatible with Linux based Operating Systems due our dependency on DeepMind's dm-reverb package found here.

Nvidia Drivers & Toolkit

Additionally, a Cuda 11.8 compatible computer must be used along with the corresponding Nvidia Toolkit. Instruction on setting the Nvidia drivers can be found on the official website located here.

Docker

The project above provides a Dockerfile to reproduce the results from this experiment with a Docker image. To install docker, please follow the guide here.

uv (Optional)

If docker isn't desired, a local setup can be created. In that case, please install uv by doing the following on your local machine by looking at this reference which will serve as our python dependency manager and installer.

Bash Installation Guide

First, begin by cloning this repository to your local computer. Afterwards, build the image with the following command:

docker build -t humanoid/playstyles .

After the image has been built, start and enter into a new docker container with the following (you may optionally need a --runtime nvidia flag dependening on your setup):

docker run -it \
    --net=host \
    --gpus all \
    -v .:/home/dev/playstyles \
    -e HOST_SYSTEM="Linux" \
    -e CUDA_CACHE_MAXSIZE="2147483647" \
    -e DISPLAY=$DISPLAY \
    -u 1000:1000 --group-add video \
    humanoid/playstyles \
    /bin/bash -l

From there, start training your first experiment by running the following within the docker container:

python run_experiment.py

It will take some time for the training job to complete (~2.5 days). While training, the experiment will store data in the ./runs/ folder. If you would like to run a standalone evaluation on a particular checkpoint, run the following command on a particular trained policy within the docker container. This command will iterate cartesian combination of each of the tasks (3 poses, 2 gait lengths) in order:

python run_experiment.py -m standalone_eval -f ./runs/<run_id>/checkpoints/<policy_file>

As part of this release, a binary policy is provided. To evaluate this policy, please run the following:

python run_experiment.py -m standalone_eval -f ./policy/weights.bin

Managing Dependencies

For our Python dependency management, we use uv. To install/sync the python dependencies in your virtual environment, run the following:

uv sync --frozen --active

When expanding on this list of dependencies, simply follow these steps:

  1. Update the pyproject.toml file with the new dependency
  2. Freeze the dependencies:
uv lock --project .
  1. Install the new dependencies:
uv sync --frozen --active --project .

Citation

If you use this project as part of your research, please cite our paper with the following citation:

@misc{capobianco2026coachableagents,
      title={Coachable agents for interactive gameplay},
      author={Roberto Capobianco and Harm van Seijen and Nolan D. Bard and Neil Burch and Fatima Davelouis and Josh Davidson and Alisa Devlic and Yunshu Du and Ishan Durugkar and Siddhant Gangapurwala and Daniel Hernandez and G. Zacharias Holland and Sahil Jain and Kenta Kawamoto and Raksha Kumaraswamy and Patrick MacAlpine and Dustin R. Morrill and Declan Oller and Francesco Riccio and Akanksha Saran and Craig Sherstan and Kaushik Subramanian and Thomas J. Walsh and Samuel Barrett and Kizza N. Frisbee and Mady Govil and Johannes Günther and Varun R. Kompella and James A. MacGlashan and Maxwell Svetlik and Michael D. Thomure and Jaden B. Travnik and Kevin Waugh and Elahe Aghapour and Florian Fuchs and Andreanne Lemay and Shruti Mishra and Takuma Seno and Peter Stone and Michael Spranger and Peter R. Wurman},
      year={2026},
      eprint={2607.00642},
      archivePrefix={arXiv},
}

About

Coachable agents for interactive gameplay

Resources

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages