Commit 599d89f9 authored by Unknown's avatar Unknown

success check for high level policy

parent 788a93ad
...@@ -383,9 +383,10 @@ class DQNLearner(LearnerBase): ...@@ -383,9 +383,10 @@ class DQNLearner(LearnerBase):
termination_reason_counter[termination_reason] += 1 termination_reason_counter[termination_reason] += 1
else: else:
termination_reason_counter[termination_reason] = 1 termination_reason_counter[termination_reason] = 1
env.reset() #TODO: remove below env-specific code
if episode_reward >= success_reward_threshold: if env.env.goal_achieved:
success_count += 1 success_count += 1
env.reset()
print("Episode {}: steps:{}, reward:{}".format( print("Episode {}: steps:{}, reward:{}".format(
n + 1, step, episode_reward)) n + 1, step, episode_reward))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment