Fancy Gym
=========
.. raw:: html
Built upon the foundation of
`Gymnasium `__ (a maintained fork of
OpenAI’s renowned Gym library) ``fancy_gym`` offers a comprehensive
collection of reinforcement learning environments.
Key Features
------------
- **New Challenging Environments**: ``fancy_gym`` includes several new
environments (`Panda Box Pushing `_,
`Table Tennis `_,
`etc. `_) that present a higher degree of
difficulty, pushing the boundaries of reinforcement learning research.
- **Support for Movement Primitives**: ``fancy_gym`` supports a range
of movement primitives (MPs), including Dynamic Movement Primitives
(DMPs), Probabilistic Movement Primitives (ProMP), and Probabilistic
Dynamic Movement Primitives (ProDMP).
- **Upgrade to Movement Primitives**: With our framework, it’s
straightforward to transform standard Gymnasium environments into
environments that support movement primitives.
- **Benchmark Suite Compatibility**: ``fancy_gym`` makes it easy to
access renowned benchmark suites such as `DeepMind
Control `__
and `Metaworld `__, whether you want
to use them in the regular step-based setting or using MPs.
- **Contribute Your Own Environments**: If you’re inspired to create
custom gym environments, both step-based and with movement
primitives, this
`guide `__
will assist you. We encourage and highly appreciate submissions via
PRs to integrate these environments into ``fancy_gym``.
Quickstart Guide
----------------
Install via pip (`or use an alternative installation method `__)
.. code:: bash
pip install 'fancy_gym[all]'
Try out one of our step-based environments (`or explore our other envs `__)
.. code:: python
import gymnasium as gym
import fancy_gym
import time
env = gym.make('fancy/BoxPushingDense-v0', render_mode='human')
observation = env.reset()
env.render()
for i in range(1000):
action = env.action_space.sample() # Randomly sample an action
observation, reward, terminated, truncated, info = env.step(action)
time.sleep(1/env.metadata['render_fps'])
if terminated or truncated:
observation, info = env.reset()
Explore the MP-based variant (`or learn more about Movement Primitives (MPs) `__)
.. code:: python
import gymnasium as gym
import fancy_gym
env = gym.make('fancy_ProMP/BoxPushingDense-v0', render_mode='human')
env.reset()
env.render()
for i in range(10):
action = env.action_space.sample() # Randomly sample MP parameters
observation, reward, terminated, truncated, info = env.step(action) # Will execute full trajectory, based on MP
observation = env.reset()
.. toctree::
:maxdepth: 3
:caption: User Guide
guide/installation
guide/episodic_rl
guide/basic_usage
guide/upgrading_envs
.. toctree::
:maxdepth: 3
:caption: Environments
envs/fancy/index
envs/dmc
envs/meta
envs/open_ai
.. toctree::
:maxdepth: 3
:caption: Examples
examples/general
examples/dmc
examples/metaworld
examples/open_ai
examples/movement_primitives
examples/mp_params_tuning
examples/pd_control_gain_tuning
examples/replanning_envs
.. toctree::
:maxdepth: 3
:caption: API
api
Citing the Project
------------------
To cite `fancy_gym` in publications:
.. code:: bibtex
@software{fancy_gym,
title = {Fancy Gym},
author = {Otto, Fabian and Celik, Onur and Roth, Dominik and Zhou, Hongyi},
abstract = {Fancy Gym: Unifying interface for various RL benchmarks with support for Black Box approaches.},
url = {https://github.com/ALRhub/fancy_gym},
organization = {Autonomous Learning Robots Lab (ALR) at KIT},
}
Icon Attribution
----------------
The icon is based on the
`Gymnasium `__ icon as
can be found
`here `__.
=================
.. raw:: html