Giter VIP home page Giter VIP logo

zerofish's Introduction

ZeroFish

An implementation of the AlphaZero algorithm for chess

Currently under construction.

Currently uses a completely different model than the one from the paper! This model has a very different layout than the one from the paper. Significantly reduced number of parameters in value and policy output heads. Completely different action space. Does not deal with under-promotions. Action space is absolute compared to the relative to moving piece action spaced used in the paper.

Short guide to the different files

adapter.py - Acts a layer between the python-chess package and numpy. Supposed to handle all traffic between chess.Board and chess.Move to our neural network data and labels.

config.py - Handles all default values and the argument parser.

game_state.py - Acts as a layer of abstraction for chess/adapter to provide a game state that only deals with action indices.

input_fn.py - Handles the different types of input formats for tensorflow (placeholders, tfrecords data-sets).

mcts.py - Handles the MCTS algorithm.

model_fn.py - Contains the definition of our inference/evaluation/training model.

model.py - Handles building inference/evaluation/training specifications and acts as a layer of abstraction for our model_fn. Large parts of this could be replaced with tf.Estimator when the API matures.

output_fn.py - Handles output for the tfrecords format.

pgn_to_records.py - WIP supposed to handle reading pgn files and outputting tfrecords.

self_play.py - Plays one game of self-play and outputs tfrecords and pgn files.

train.py - Trains by reading tfrecords files from a directory.

visualize_filters.py - Shows image representations of the learned filters.

zerofish's People

Contributors

crypt3lx2k avatar dependabot[bot] 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.