seohongpark/ogbench
A benchmark for offline goal-conditioned RL and offline RL
What it is: OGBench is a benchmark suite and Python library for a specific area of AI research called offline goal-conditioned reinforcement learning (RL). In this setup, an AI agent learns from a pre-collected dataset of past actions (offline) to reach specific target states (goal-conditioned). The project provides the environments, datasets, and baseline algorithms needed to test and compare such agents.
Key features:
- 8 diverse environment types: Includes locomotion (mazes, soccer), robotic manipulation (cubes, puzzles), and a drawing environment (Powderworld).
- Large dataset collection: Provides 85 pre-generated datasets and 410 single-task variants for standard offline RL.
- Dual observation modes: Supports both state-based (coordinates, joint angles) and pixel-based (camera images) observations.
- Reference implementations: Includes clean, pre-tuned JAX-based code for 6 well-known offline goal-conditioned RL algorithms (e.g., GCBC, GCIQL, HIQL).
- Easy installation: Installable via
pip install ogbenchwith minimal dependencies (MuJoCo, dm_control, Gymnasium).
How it works:
Users install the package and use the ogbench.make_env_and_datasets function to create a simulated environment and automatically download the corresponding training/validation datasets. The environment follows the standard Gymnasium API, so users can plug in their own RL agents. The library also provides standalone scripts to train the included reference algorithms, and even includes the exact commands used to generate the datasets and reproduce the paper's benchmark results.
Why it matters: Offline RL is important because it allows AI agents to learn without risky or expensive real-world trial-and-error. OGBench standardizes this research by offering a wide variety of realistic tasks and pre-collected data, making it easier for researchers to fairly compare new algorithms against established baselines.
Notable details:
- It distinguishes between
terminals(end of a data trajectory) andmasks(whether a task was completed), which is crucial for correctly training certain RL algorithms. - It includes
-oraclerepvariants that provide ground-truth goal representations (e.g., only the x-y position) to simplify certain tasks. - The reference implementations require a GPU (e.g., A5000) and can take 2-12 hours per training run, with large pixel-based datasets potentially needing up to 120GB of RAM.
Related
- Project
- Project
- Project
- Project