update
This commit is contained in:
@@ -220,9 +220,9 @@ end
|
||||
|
||||
# Arguments
|
||||
- `node::MCTSNode`
|
||||
node of a search tree
|
||||
leaf node of a search tree
|
||||
- `simTrajectoryReward::T`
|
||||
total reward from all node in simulation trajectory
|
||||
total reward from trajectory simulation
|
||||
|
||||
# Return
|
||||
- `No return`
|
||||
@@ -236,6 +236,9 @@ julia>
|
||||
"""
|
||||
function backpropagate(node::MCTSNode, simTrajectoryReward::T;
|
||||
discountRewardCoeff::AbstractFloat=0.9) where {T<:Number}
|
||||
# [WORKING] store best trajectory
|
||||
isLeafNodeTerminalState = true
|
||||
terminalStateReward = node.reward
|
||||
while !isroot(node)
|
||||
# Update the statistics of the current node based on the result of the playout
|
||||
node.visits += 1
|
||||
|
||||
Reference in New Issue
Block a user