GitXplorerGitXplorer
o

multi-agent-emergence-environments

public
1628 stars
303 forks
27 issues

Commits

List of commits on branch master.
Verified
bafaf1e11e6398624116761f91ae7c93b136f395

Merge pull request #31 from bowenbaker/master

bbowenbaker committed 4 years ago
Verified
85d2167999110edc6c975d1f81ab7ec8ff39a809

Merge pull request #1 from bowenbaker/bowen-rusp

bbowenbaker committed 4 years ago
Unverified
ed67549a70a3d369f121561f931b73f28409f920

Randomized Uncertain Social Preferences

bbowenbaker committed 4 years ago
Unverified
8e5ab4511ad3f59df4276f078a9d4ea43335054b

Bump tensorflow from 1.9.0 to 1.12.2

ddependabot[bot] committed 5 years ago
Unverified
5b3494af0a8e4790f39c752d997f3d05a25df179

minor updates to readme and ma_policy comments

ttodor-markov committed 5 years ago
Unverified
bc31472e0795e5ea93ca5f42c10815f934c112ab

all files added

ttodor-markov committed 5 years ago

README

The README file for this repository.

Status: Archive (code is provided as-is, no updates expected)

Multiagent emergence environments

Environment generation code for Emergent Tool Use From Multi-Agent Autocurricula (blog)

Installation

This repository depends on the mujoco-worldgen package. You will need to clone the mujoco-worldgen repository and install it and its dependencies:

pip install -r mujoco-worldgen/requirements.txt
pip install -e mujoco-worldgen/
pip install -e multi-agent-emergence-environments/

This repository has been tested only on Mac OS X and Ubuntu 16.04 with Python 3.6

Use

Environment construction works in the following way: You start from the Base environment (defined in mae_envs/envs/base.py) and then you add environment modules (e.g. Boxes, Ramps, RandomWalls, etc.) and then wrappers on top. You can see examples in the mae_envs/envs folder.

If you want to construct a new environment, we highly recommend using the above paradigm in order to minimize code duplication. If you need new objects or game dynamics that don't already exist in this codebase, add them in via a new EnvModule class or a gym.Wrapper class rather than subclassing Base (or mujoco-worldgen's Env class). In general, EnvModules should be used for adding objects or sites to the environment, or otherwise modifying the mujoco simulator; wrappers should be used for everything else (e.g. adding rewards, additional observations, or implementing game mechanics like Lock and Grab).

The environments defined in this repository are:
Hide and seek - mae_envs/envs/hide_and_seek.py - The Hide and Seek environment described in the paper. This encompasses the random rooms, quadrant and food versions of the game (you can switch between them by changing the arguments given to the make_env function in the file)
Box locking - mae_envs/envs/box_locking.py - Encompasses the Lock and Return and Sequential Lock transfer tasks described in the paper.
Blueprint Construction - mae_envs/envs/blueprint_construction.py
Shelter Construction - mae_envs/envs/shelter_construction.py

You can test out environments by using the bin/examine script. Example usage: bin/examine.py base.
You can also use bin/examine to play a saved policy on an environment. There are several environment jsonnets and policies in the examples folder. Example usage:

bin/examine.py examples/hide_and_seek_quadrant.jsonnet examples/hide_and_seek_quadrant.npz

Note that to be able to play saved policies, you will need to install a few additional packages. You can do this via

pip install -r multi-agent-emergence-environments/requirements_ma_policy.txt