diff --git a/network.py b/network.py index 86e0fe2..10d238f 100644 --- a/network.py +++ b/network.py @@ -307,6 +307,7 @@ class Network: list_of_moves = [] + # Prepping of data for idx, board in enumerate(boards): all_board_moves = [] for roll in all_rolls: @@ -317,14 +318,16 @@ class Network: list_of_moves.append(np.array(all_board_moves)) + print(time.time() - start) + + start = time.time() + # Running data through networks all_scores = [self.model.predict_on_batch(board) for board in list_of_moves] transformed_scores = [x if player == 1 else (1-x) for x in all_scores] scores_means = [tf.reduce_mean(score) for score in all_scores] transformed_means = [tf.reduce_mean(score) for score in transformed_scores] - print(time.time() - start) - return ([scores_means, transformed_means])