Giter Club home page Giter Club logo

graphmix's Introduction

GraphMIX: Graph Convolutional Value Decomposition in Multi-Agent Reinforcement Learning

GraphMIX is a multi-agent deep reinforcement learning (MARL) approach that relies on a graph neural network (GNN) architecture for combining the individual agent value functions into a global team value funtion, and it provides state-of-the-art results across several maps in the StarCraft Multi-Agent Challenge (SMAC) benchmark.

This repository contains the PyTorch-based implementation of GraphMIX and relies on the PyMARL and SMAC libraries.

Installation instructions

Build the Dockerfile using

cd docker
bash build.sh

Set up StarCraft II and SMAC:

bash install_sc2.sh

This will download SC2 into the 3rdparty folder and copy the maps necessary to run over.

The requirements.txt file can be used to install the necessary packages into a virtual environment (not recomended).

Running an experiment

Use the following command to run GraphMIX on any desired SMAC map (e.g., corridor in the example below):

python3 src/main.py --config=graphmix --env-config=sc2 with \
env_args.map_name=corridor lambda_local=1 test_interval=20000 test_nepisode=32 \
t_max=5000000 epsilon_anneal_time=500000

The parameter lambda_local represents the local loss coefficient in the GraphMIX objective function.

All results will be stored in the results folder.

Saving and loading learnt models

Saving models

You can save the learnt models to disk by setting save_model = True, which is set to False by default. The frequency of saving models can be adjusted using save_model_interval configuration. Models will be saved in the result directory, under the folder called models. The directory corresponding each run will contain models saved throughout the experiment, each within a folder corresponding to the number of timesteps passed since starting the learning process.

Loading models

Learnt models can be loaded using the checkpoint_path parameter, after which the learning will proceed from the corresponding timestep.

If you use this repository in your work, please cite the accompanying paper using the BibTeX citation below:

@article{naderializadeh2020graph,
  title={Graph Convolutional Value Decomposition in Multi-Agent Reinforcement Learning},
  author={Naderializadeh, Navid and Hung, Fan H and Soleyman, Sean and Khosla, Deepak},
  journal={arXiv preprint arXiv:2010.04740},
  year={2020}
}

graphmix's People

Contributors

navid-naderi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

graphmix's Issues

Regarding missing layers_gcn.py module

In paper, figure 5 GraphMIX (GCN) results are there. However, I could not able to find layers_gcn.py which contains "class GraphConvolution(nn.Module):"

Kindly look into this.

Regards
Ajay N N

About the permutation invariance of the algorithm

Hello, I see that your article mentioned the permutation invariance in the past, I would like to ask if the algorithm can achieve a transferable MADRL through the permutation invariance, that is, the model trained under the map of agents of different scales can be used in another map?

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.