Tianshou/AlphaGo/test.py

35 lines
671 B
Python
Raw Normal View History

2017-11-20 12:44:29 +08:00
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
# $File: test.py
2017-12-01 01:37:55 +08:00
# $Date: Fri Dec 01 01:3722 2017 +0800
2017-11-20 12:44:29 +08:00
# $Author: renyong15 © <mails.tsinghua.edu.cn>
#
from game import Game
from engine import GTPEngine
2017-11-28 01:15:46 +08:00
import utils
2017-11-20 12:44:29 +08:00
g = Game()
2017-11-26 13:36:52 +08:00
e = GTPEngine(game_obj=g)
2017-11-20 12:44:29 +08:00
2017-12-04 11:01:49 +08:00
e.run_cmd("genmove BLACK")
2017-12-01 01:37:55 +08:00
g.show_board()
2017-12-04 11:01:49 +08:00
e.run_cmd("genmove WHITE")
g.show_board()
e.run_cmd("genmove BLACK")
g.show_board()
e.run_cmd("genmove WHITE")
g.show_board()
e.run_cmd("genmove BLACK")
g.show_board()
e.run_cmd("genmove WHITE")
g.show_board()
e.run_cmd("genmove BLACK")
g.show_board()
e.run_cmd("genmove WHITE")
g.show_board()
e.run_cmd("genmove BLACK")
g.show_board()
e.run_cmd("genmove WHITE")
2017-12-01 01:37:55 +08:00
g.show_board()