Skip to content

Latest commit

 

History

History
 
 

README.md

Minigui

A UI for Minigo

Simple Instructions

  1. Make sure you have Docker installed

  2. Pick a model from Cloudy Go. Make note of the Model Name and the Board Size.

    export MINIGUI_BOARD_SIZE=9
    export MINIGUI_MODEL=000360-grown-teal
  3. From the root directory, run:

    cluster/minigui/run-local.sh
  4. Navigate to localhost:5001

Advanced Instructions

  1. Install the minigo python requirements: pip install -r requirements.txt (or pip3 ... depending how you've set things up).

  2. Install TensorFlow (here, we use the CPU install): pip install "tensorflow>=1.7,<1.8"

  3. Install the minigui python requirements: pip install -r minigui/requirements.txt

  4. Install the Google Cloud SDK

  5. Pick a model. See http://cloudygo.com/ for the available models.

  6. Change the variables you want (these are the defaults):

    export MINIGUI_BUCKET_NAME=minigo-pub
    export MINIGUI_GCS_DIR=v5-19x19/models
    export MINIGUI_MODEL=000363-auriga
    export MINIGUI_MODEL_TMPDIR=/tmp/minigo-models
    export MINIGUI_BOARD_SIZE=19
  7. Run source minigui-common.sh

  8. Compile the Typescript to JavaSCript. (Requires typescript compiler). From the minigui directory run: tsc

  9. Run ./fetch-and-run.sh

  10. open localhost:5001 (or whatever value you used for $PORT).

  11. The buttons in the upper right that say 'Human' can be toggled to set which color Minigo will play.

C++ Engine

  1. By default, Minigui will use the Python Minigo engine. You can use the C++ engine by first compiling it (see the README), then passing --engine=cc when starting minigui/serve.py. You will need to pass a frozen GraphDef proto as the --model command line argument instead of the saved parameter data that the Python backend requires.

    Note: Compiling tensorflow from scratch can take 2+ hours if your machine is not terribly beefy, So you might want to kick off the build and get a coffee.

  2. Before running, you'll need to freeze a model so the C++ job can consume it. This assumes a converted model from above.

    python main.py freeze-graph $MODEL_DIR/$MODEL.converted
  3. Here's an example, note that we specify the board size when compiling the C++ engine binary, not when running the Minigui server:

    bazel build --define=board_size=19 cc:main
    python minigui/serve.py --port=8888 --model=$MODEL_DIR/$MODEL.converted.pb --engine=cc