Skip to content

Commit

Permalink
Merge branch 'master' into runpod-rl_hopper
Browse files Browse the repository at this point in the history
  • Loading branch information
PVirie committed Dec 25, 2024
2 parents b0be8c1 + 0930249 commit 198cda2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tasks/rl_hopper.py
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ def prepare_data_tuples(states, actions, rewards, num_layers, skip_steps):
total_steps = 0
num_trials = 2000
print_steps = max(1, num_trials // 100)
epsilon = 0.2 + 0.7 * (course + 1) / num_courses
epsilon = 1 - 0.5 * (course + 1) / num_courses

next_best_targets = np.zeros((len(goals), len(goals[0][0])), dtype=np.float32)
next_best_target_diffs = np.ones((len(goals), 1), dtype=np.float32) * 1e4
Expand All @@ -258,7 +258,7 @@ def prepare_data_tuples(states, actions, rewards, num_layers, skip_steps):
actions = []
rewards = []
for _ in range(200):
if random.random() >= epsilon or course == 0:
if random.random() <= epsilon or course == 0:
selected_action = env.action_space.sample()
else:
a = model.react(alg.State(observation.data), stable_state)
Expand Down

0 comments on commit 198cda2

Please sign in to comment.