Giter Club home page Giter Club logo

gymnasium_rs's Introduction

gymnasium_rs

crates.io docs.rs Rust Docker deps.rs codecov.io

Rust implementation of Gymnasium API for reinforcement learning. This implementation is compatible and interoperable with the Python implementation.

Overview

The workspace contains these packages:

Instructions

Rust

Add gymnasium as a Rust dependency to your Cargo.toml manifest.

[dependencies]
gymnasium = "0.1"

Examples: gymnasium/examples/

CLI tool

Install the gymnasium_rs executable with cargo.

cargo install --locked gymnasium_cli

Afterwards, run the gymnasium_rs executable.

# Pass `--help` to show the usage and available options
gymnasium_rs

Docker

To install Docker on your system, you can run .docker/host/install_docker.bash to configure Docker with NVIDIA GPU support.

.docker/host/install_docker.bash

Build Image

To build a new Docker image from Dockerfile, you can run .docker/build.bash as shown below.

.docker/build.bash ${TAG:-latest} ${BUILD_ARGS}

Run Container

To run the Docker container, you can use .docker/run.bash as shown below.

.docker/run.bash ${TAG:-latest} ${CMD}

Run Dev Container

To run the Docker container in a development mode (source code mounted as a volume), you can use .docker/dev.bash as shown below.

.docker/dev.bash ${TAG:-latest} ${CMD}

As an alternative, users familiar with Dev Containers can modify the included .devcontainer/devcontainer.json to their needs. For convenience, .devcontainer/open.bash script is available to open this repository as a Dev Container in VS Code.

.devcontainer/open.bash

Join Container

To join a running Docker container from another terminal, you can use .docker/join.bash as shown below.

.docker/join.bash ${CMD:-bash}

License

This project is dual-licensed to be compatible with the Rust project, under either the MIT or Apache 2.0 licenses.

Contributing

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

gymnasium_rs's People

Contributors

andrejorsula avatar dependabot[bot] avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

gymnasium_rs's Issues

Features

This meta-issue tracks the progress towards the next releases and describes the intended structure of the project.
Any form of feedback is welcome and appreciated!

Note: Before the first major release, the public API is subject to changes that are required to accommodate these features.

gymnasium

  • Rust implementation of environment (gymnasium::Env trait)
  • #2
    • Space trait
    • Fundamental spaces
      • BoxSpace
      • BoxSpaceIdentical
      • BoxSpaceIndependent
      • DiscreteSpace
      • MultiBinarySpace
      • MultiDiscreteSpace
      • TextSpace
    • Composite spaces
      • HashMapSpace (DictSpace)
      • VecSpace
  • Rust implementation of the environment registry (gymnasium::Registry static — TBD)
    • Interface for registering Rust gymnasium::Env impl in Rust gymnasium::Registry
    • Interface for loading Rust-registered gymnasium::Env impl in Rust
    • [gymnasium_py overlap] Interface for registering Rust gymnasium::Env impl in Python gymnasium.envs.registry* (Python runtime inside a Rust binary)
    • [gymnasium_py overlap] Interface for loading Python-registered gymnasium.Env subclass in Rust

* Use-case: Python-based RL algorithm/framework used inside a Rust binary on Rust environments directly via a Python C library wrapper (e.g. pyo3)

TBD
  • Rust derive macro for vectorised/parallel environment (e.g. #[derive(gymnasium::VectorEnv)] macro)
  • Rust implementation for certain environment "wrappers" (e.g. gymnasium::GoalEnv: gymnasium::Env trait)

gymnasium_py

  • Interface for loading Rust-registered gymnasium::Env impl in Python (inside a standalone Python script)

gymnasium_cli

  • gymnasium_rs new ... — CLI for templating new Rust crates
  • gymnasium_rs list ... — CLI for listing all registered environments of Python modules and Rust crates
  • gymnasium_rs info ... — CLI for printing detailed information about registered environments
  • gymnasium_rs rand ... — CLI for running a random agent in a specific environment

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.