GithubHelp home page GithubHelp logo

solving-minesweeper-by-tensorflow's Introduction

TensorFlow solve minesweeper

簡介

使用 TensorFlow 訓練 model 解 minesweeper (踩地雷)

model 正確率達到 94% (E(in) = 97.69% E(out) = 94.34

開發環境

Ubuntu 17 + Python 3.5

檔案簡介

檔案 簡介
model-gamma.py model 定義 & 訓練 model
gui.py 視覺化 model 解採地雷
minesweeper.py minesweeper 遊戲邏輯 & API
dataset.py 將 minesweeper.py 產生的遊戲內容轉換並包裝成訓練資料
packages 專案用到 python 的套件 (pip freeze > packages)
model/readymade/ 預先訓練完的 model
data 預先產生的 dataset

使用方法

注意事項

以 CPU 訓練 model 訓練時間約 1 小時 50 分鐘

訓練完成後 checkpoint & model 會儲存在 ./model/model-gamma/run-{date}-{time}

由於 TensorFlow 管理檔案的方式,預先訓練的模型會沒有 GRAPH

  • 使用預先訓練的 model
$> python gui.py -t ./model/readymade/model-gamma-3500.meta -m model-gamma.py
  • 訓練 model
$> python model-gamma.py
  • 查看訓練結果
$> python gui.py -t ./model/model-gamma/run-{date}-{time}/model-gamma-{check-point}.meta -m model-gamma.py
  • 使用 TensorBoard 查看結果
$> tensorboard --logdir ./model/model-gamma/run-{date}-{time}/

solving-minesweeper-by-tensorflow's People

Contributors

staytime avatar

Watchers

 avatar  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.