Giter VIP home page Giter VIP logo

brnes's Introduction

BRNES: Byzantine Robust Neighbor Experience Sharing in Differentially Private Multiagent Reinforcement Learning

This is the codification used in the AAMAS 2023 paper proposing BRNES framework as means of accelerating learning in Multiagent Systems composed of advisee and advisor agents. You are free to use all or part of the codes here presented for any purpose, provided that the paper is properly cited and the original authors properly credited. All the files here shared come with no warranties.

This project was built on Python 3.8. All the experiments are executed in the Predator-Prey (PP) domain (https://www.ifaamas.org/Proceedings/aamas2017/pdfs/p1722.pdf), we included the version we used in the Main/PP_environment folder (slightly different from the standard PP domain). For the graph generation code you will need to install Jupyter Notebook (http://jupyter.readthedocs.io/en/latest/install.html).

Files

The folder Main contains our implementation of all algorithms and experiments

The folder Main/PP_environment contains the Predator-Prey environment (also called a Pursuit domain) we used for experiments

Finally, the folder ProcessedFiles contains already processed .pickle files for graph printing and data visualization

How to use

First, install python 3.8 from https://www.python.org/downloads/release/python-380/
Then open up your command terminal/prompt to run the following commands sequentially

  1. python RandomInit.py G N O E L Nw Ap D S M
  2. python BRNES.py G N O E L Nw Ap D S M
  3. python DARL.py G N O E L Nw Ap D S M
  4. python AdhocTD.py G N O E L Nw Ap D S M

where,
G: Grid Height and Width (N x N)
N: number of agents
O: number of obstacles
E: Total Episode
L: number of times the code will run as a loop
Nw: Neighbor weights [0,1]
Ap: Attack Percentage [0,100]
D: Display environment [on, off]
S: Sleep (sec)
M: Play mode [random, static]

Example:
python RandomInit.py 15 10 3 2000 10 0.90 20 on 2 random
python BRNES.py 15 10 3 2000 10 0.90 20 on 2 random
python DARL.py 15 10 3 2000 10 0.90 20 on 2 random
python AdhocTD.py 15 10 3 2000 10 0.90 20 on 2 random

However, it will take a very long time until the experiments are completed. It may be of interest to run more than one algorithm at the same time if you have enough computing power. Also, note that, for each framework, if the agents do not attain goal within (GridSize*100) steps in a particular episode, the episode and environment will be reset to the next.

The file name associated with any experiment is appended into a log file (BRNES.txt) that resides inside "Main/OutputFile" directory.
The results (Steps to goal (SG), Time to goal (TG), Rewards, Convergence, Qtable) of any experiment are stored categorically by file name in "Main/SG", "Main/TG", "Main/Reward", "Main/Convergence", "Main/Qtable" respectively as a pickle file. Then, the respective pickle files can be used to reproduce the graphs.

Contact

For questions about the codification or paper, please send an email to the first author.

brnes's People

Contributors

tamjidhossain avatar

Watchers

 avatar

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.