Giter VIP home page Giter VIP logo

alphaze's Introduction

⚠️ NOTE: AlphaZe** is now part of the official CrazyAra framework. ⚠️

AlphaZe**

AlphaZe** is an adaptation of AlphaZero and combines is with our own version of the so-called Perfect Information Monte-Carlo algorithm to deal with imperfect information games, such as DarkHex or Stratego.

This project is build on the improved AlphaZero implementation of Johannes Czech, called CrazyAra. It is also full integrated and part of the original CrazyAra reporsitory now. It is written in python as well as C++ and still maintained. For information about the backend, the model architecture we used in this work or installation steps, we would recommend to read the CrazyAra wiki.

AlphaZe** is completely trained via reinforcement learning and do not us any form of supervised learning, this makes RL instructions especially helpful.

How to use AlphaZe**

First you have to download or build the binary to execute. An example binary can be found here

We cannot guarantee that the binaries will run out of the box on every system. We provide a dockerfile to create an environment in which the binaries work. We distinguish between binaries, with and without the ability to be trained using RL. To use a binary, it must always be used with a suitable model. Such models can be downloaded separately from the following link. For Hex and Darkhex we also provide a model that is not trained at all and can be used to test training.

Copy the appropriate folder named model/... into the directory of the binary. Afterwards you can start the binary and use it with the instructions of CrazyAra. Instead of a correct FEN String (like in chess or CrazyAra), it is possible to use one of the FENfS Strings from the following examples to define a starting position for Stratego.

  • aaaaaaaaKMaaaaaaaaEBaaaaaaaaaaDaaCLaaaaDaa__aa__aaaa__aa__aaaaaaOWaaNQaaaaaaaaaaaaaaaaaaXPaaaaaaaaPY r 0
  • MBaaaaaaaaCEaaaaaaaaKLaaaaaaaaaDaaDaaaaaaa__aa__aaaa__aa__aaOWaaXPaaQaaaaaaaaaaaPaaaaaaaaaNYaaaaaaaa r 0
  • MDaaaaaaaaCaaaaaaaaaaaaaaaaaaaKBaDLEaaaaaa__aa__aaaa__aa__aaaaaaaaaaaaaaaaaaaaWPaaaaaaaQXOaaaaaaaPYN r 0

Building your own binary

To build your own binary it is neccessary to install some additional libaries (which are also described in the dockerfile) It is neccessary to change the game within the CMakeList.txt. Stratego can be played, using MODE_STRATEGO, DarkHex and Hex via the MODE_OPEN_SPIEL parameter. Be careful, only one mode can be active at the same time. The binary is named after the active mode, i.e. StrategoAra is a binary able to play Stratego, OpenSpielAra, is able to play Hex.

How to train a model

To train a new model follow the instructions described by CrazyAra. It is also necessary to activate USE_RL in the CMakeList and provide a initialized model, describing the architecture.

alphaze's People

Contributors

queensgambit avatar matuiss2 avatar bluemlj avatar magehrke avatar noelben avatar bingobongomann avatar codacy-badger avatar mlanher avatar

Stargazers

Nimit Pattanasri 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.