Code Monkey home page Code Monkey logo

policy-guided-diffusion's Introduction

Policy-Guided Diffusion

animated

The official implementation of Policy-Guided Diffusion (https://arxiv.org/abs/2404.06356) - built by Matthew Jackson and Michael Matthews.

  • Offline RL agents (TD3+BC, IQL),
  • Trajectory-level U-Net diffusion model,
  • EDM diffusion training and sampling,
  • Runs on the D4RL benchmark.

Diffusion and agent training is implemented entirely in Jax, with extensive JIT-compilation and parallelization!

Running experiments

Diffusion and agent training is executed with python3 train_diffusion.py and python3 train_agent.py, with all arguments found in util/args.py.

  • --log --wandb_entity [entity] --wandb_project [project] enables logging to WandB.
  • --debug disables JIT compilation.

Docker installation

  1. Build docker image
cd docker & ./build.sh & cd ..
  1. (To enable WandB logging) Add your account key to setup/wandb_key:
echo [KEY] > setup/wandb_key

Launching experiments

./run_gpu.sh [GPU index] python3.9 train_diffusion.py [args]

Citation

If you use this implementation in your work, please cite us with the following:

@misc{jackson2024policyguided,
      title={Policy-Guided Diffusion},
      author={Matthew Thomas Jackson and Michael Tryfan Matthews and Cong Lu and Benjamin Ellis and Shimon Whiteson and Jakob Foerster},
      year={2024},
      eprint={2404.06356},
      archivePrefix={arXiv},
      primaryClass={cs.LG}
}

policy-guided-diffusion's People

Contributors

emptyjackson avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.