Skip to content
This repository was archived by the owner on May 6, 2021. It is now read-only.

Commit 69b77b4

Browse files
authored
DQN: take into account the update_horizon to know if we can update (#162)
1 parent e4d2df9 commit 69b77b4

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/algorithms/dqns/common.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
const PERLearners = Union{PrioritizedDQNLearner,RainbowLearner,IQNLearner}
66

77
function RLBase.update!(learner::Union{DQNLearner,PERLearners}, t::AbstractTrajectory)
8-
length(t[:terminal]) < learner.min_replay_history && return
8+
length(t[:terminal]) - learner.sampler.n <= learner.min_replay_history && return
99

1010
learner.update_step += 1
1111

0 commit comments

Comments
 (0)