def _DFS(self, nDepth, treenode, state):

		visited = [None] * nDepth

		# Playout to nDepth moves using the full policy network
		for index in xrange(nDepth):
			action_probs = self._policy(state)
			# check for end of game
			if len(action_probs) == 0:
				break
			treenode.expansion(action_probs)
			action, treenode = treenode.selection()
			state.do_move(action)
			visited[index] = treenode

		# leaf evaluation
		v = self._value(state)
		z = self._evaluate_rollout(state, self._rollout_limit)
		leaf_value = (1 - self._lmbda) * v + self._lmbda * z

		# update value and visit count of nodes in this traversal
		# Note: it is important that this happens from the root downward
		# so that 'parent' visit counts are correct
		for node in visited:
			node.update(leaf_value, self._c_puct)
Setup tests for CachedModelAuthBackend
dataset/ETHPy150Open Rochester-NRT/RocAlphaGo/AlphaGo/mcts.py/MCTS._DFS--crossover with--dataset/ETHPy150Open ofa/connect/open_connect/connect_core/tests/test_utils_auth_backends.py/TestCachedModelAuthBackend.setUp