cogment / cogment-verse

Research platform for Human-in-the-loop learning (HILL) & Multi-Agent Reinforcement Learning (MARL)
https://cogment.ai/cogment_verse
Apache License 2.0
76 stars 14 forks source link
cogment human-in-the-loop-learning reinforcement-learning rlhf

Cogment Verse

Apache 2 License Changelog

Cogment Verse is a SDK helping researchers and developers in the fields of human-in-the-loop learning (HILL) and multi-agent reinforcement learning (MARL) train and validate their agents at scale. Cogment Verse instantiates the open-source Cogment platform for environments following the OpenAI Gym mold, making it easy to get started.

Simply clone the repo and start training.

Documentation table of contents

Getting started

The following will show you how to setup Cogment Verse locally, it is possible to use a Docker based setup instead. Instructions for this can be found here

  1. Clone this repository

  2. Install Python 3.9

  3. Depending on your specific machine, you might also need to following dependencies:

    • swig, which is required for the Box2d gym environments, it can be installed using apt-get install swig on ubuntu or brew install swig on macOS
    • python3-opencv, which is required on ubuntu systems, it can be installed using apt-get install python3-opencv
    • libosmesa6-dev and patchelf are required to run the environment libraries using mujoco. They can be installed using apt-get install libosmesa6-dev patchelf.
  4. Create and activate a virtual environment

    $ python -m venv .venv
    $ source .venv/bin/activate
  5. Install the python dependencies.

    $ pip install -r requirements.txt
  6. Depending on the environment you want to use, you might need to take additional steps.

  7. In another terminal, launch a mlflow server on port 3000

    $ source .venv/bin/activate
    $ python -m simple_mlflow
  8. Start the default Cogment Verse run using python -m main

  9. Open Chrome (other web browser might work but haven't tested) and navigate to http://localhost:8080/

  10. Play the game!

That's the basic setup for Cogment Verse, you are now ready to train AI agents.

Configuration

Cogment Verse relies on hydra for configuration. This enables easy configuration and composition of configuration directly from yaml files and the command line.

The configuration files are located in the config directory, with defaults defined in config/config.yaml.

Here are a few examples:

List of publications and submissions using Cogment and/or Cogment Verse

(please open a pull request to add missing entries)