gymnasium-maze
Science Score: 44.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
✓CITATION.cff file
Found CITATION.cff file -
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
○DOI references
-
○Academic publication links
-
○Academic email domains
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (14.5%) to scientific vocabulary
Repository
Basic Info
- Host: GitHub
- Owner: karamdaaboul
- License: mit
- Language: Python
- Default Branch: main
- Size: 389 MB
Statistics
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
- Releases: 0
Metadata Files
README.md
This library contains a collection of Reinforcement Learning maze environments that use the Gymnasium API. The environments run with the MuJoCo physics engine and the maintained mujoco python bindings.
Installation
These environments require the MuJoCo engine from Deepmind to be installed. Instructions to install the physics engine can be found at the MuJoCo website and the MuJoCo Github repository.
We support and test for Linux and macOS. We will accept PRs related to Windows, but do not officially support it.
Environments
Gymnasium-Maze includes maze environments where an agent has to navigate through a maze to reach certain goal position. Two different agents can be used: a 2-DoF force-controlled ball, or the classic Ant agent from the Gymnasium MuJoCo environments. The environment can be initialized with a variety of maze shapes with increasing levels of difficulty.
Available Maze Types
- UMaze - Simple U-shaped maze
- Open - Open area with walls around the perimeter
- Medium - Medium complexity maze
- Large - Large, complex maze
- Dangerous - maze with dangerous states
Agent Types
- Point - A 2-DoF force-controlled ball that can move in x and y directions
- Ant - The classic Ant agent with 8 degrees of freedom
Environment Variations
Each maze type comes in different variations: * Standard - Single goal and reset location * Diverse_G - Multiple possible goal locations * Diverse_GR - Multiple possible goal and reset locations
Multi-goal API
The maze environments use an extension of the core Gymnasium API by inheriting from GoalEnv class. The new API forces the environments to have a dictionary observation space that contains 3 keys:
observation- The actual observation of the environmentdesired_goal- The goal that the agent has to achievedachieved_goal- The goal that the agent has currently achieved instead. The objective of the environments is for this value to be close todesired_goal
This API also exposes the function of the reward, as well as the terminated and truncated signals to re-compute their values with different goals. This functionality is useful for algorithms that use Hindsight Experience Replay (HER).
The following example demonstrates how the exposed reward, terminated, and truncated functions can be used to re-compute the values with substituted goals. The info dictionary can be used to store additional information that may be necessary to re-compute the reward, but that is independent of the goal, e.g. state derived from the simulation.
```python import gymnasium as gym
env = gym.make("PointMazeUMaze-v3") env.reset() obs, reward, terminated, truncated, info = env.step(env.actionspace.sample())
The following always has to hold:
assert reward == env.computereward(obs["achievedgoal"], obs["desiredgoal"], info) assert truncated == env.computetruncated(obs["achievedgoal"], obs["desiredgoal"], info) assert terminated == env.computeterminated(obs["achievedgoal"], obs["desired_goal"], info)
However goals can also be substituted:
substitutegoal = obs["achievedgoal"].copy() substitutereward = env.computereward(obs["achievedgoal"], substitutegoal, info) substituteterminated = env.computeterminated(obs["achievedgoal"], substitutegoal, info) substitutetruncated = env.computetruncated(obs["achievedgoal"], substitutegoal, info) ```
The GoalEnv class can also be used for custom environments.
Project Maintainers
Main Contributors: Rodrigo Perez-Vicente, Kallinteris Andreas, Jet Tai
Modified by: Karam Daaboul
Owner
- Name: Karam Daaboul
- Login: karamdaaboul
- Kind: user
- Location: Karlsruhe, Germany
- Company: KIT
- Website: https://www.youtube.com/channel/UCo1wkKlVsJlqe3FURaW3WZA
- Repositories: 2
- Profile: https://github.com/karamdaaboul
Citation (CITATION.cff)
cff-version: 1.2.0 message: "If you use this software, please cite it as below." authors: - name: "Gymnasium-Robotics Contributors" title: "Gymnasium-Robotics: A a collection of robotics simulation environments for Reinforcement Learning" date-released: 2022-01-07
GitHub Events
Total
- Push event: 3
- Fork event: 1
Last Year
- Push event: 3
- Fork event: 1
Dependencies
- Jinja2 >=3.0.3
- PettingZoo >=1.23.0
- gymnasium >=1.2.0
- imageio *
- mujoco >=2.2.0
- numpy >=1.21.0
- setuptools *