aboutsummaryrefslogtreecommitdiffstats
path: root/python/MCTS.py
diff options
context:
space:
mode:
authorMatt Strapp <strap012@umn.edu>2021-04-26 10:53:43 -0500
committerMatt Strapp <strap012@umn.edu>2021-04-26 15:03:24 -0500
commit7535ef51e84067e27f1a4c53f8889047f3a9a098 (patch)
treee5f1f9da55fb2ba2b2c482a608a328f68ddbd012 /python/MCTS.py
parentTest commit (diff)
downloadcsci4511w-7535ef51e84067e27f1a4c53f8889047f3a9a098.tar
csci4511w-7535ef51e84067e27f1a4c53f8889047f3a9a098.tar.gz
csci4511w-7535ef51e84067e27f1a4c53f8889047f3a9a098.tar.bz2
csci4511w-7535ef51e84067e27f1a4c53f8889047f3a9a098.tar.lz
csci4511w-7535ef51e84067e27f1a4c53f8889047f3a9a098.tar.xz
csci4511w-7535ef51e84067e27f1a4c53f8889047f3a9a098.tar.zst
csci4511w-7535ef51e84067e27f1a4c53f8889047f3a9a098.zip
change base???
Diffstat (limited to 'python/MCTS.py')
-rw-r--r--python/MCTS.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/python/MCTS.py b/python/MCTS.py
index 6c71ba9..ec6e6c1 100644
--- a/python/MCTS.py
+++ b/python/MCTS.py
@@ -1,6 +1,10 @@
import math
from copy import deepcopy
+<<<<<<< HEAD
from time import perf_counter
+=======
+from time import clock
+>>>>>>> f6e623d... change base???
from random import choice
from GameState import GameState
@@ -135,8 +139,13 @@ class MCTSGameController(GameController):
self.root_node = MCTSNode(state)
iterations = 0
+<<<<<<< HEAD
start_time = perf_counter()
while perf_counter() < start_time + time_allowed:
+=======
+ start_time = clock()
+ while clock() < start_time + time_allowed:
+>>>>>>> f6e623d... change base???
node = self.select()
if node.pending_moves != set():