mirror of
https://github.com/vale981/ray
synced 2025-03-04 17:41:43 -05:00
[RLlib] 2 RLlib Flaky Tests (#14930)
This commit is contained in:
parent
b90cc51c27
commit
b84575c092
2 changed files with 5 additions and 5 deletions
|
@ -88,7 +88,7 @@ def learn_test_plus_rollout(algo, env="CartPole-v0"):
|
|||
rllib_dir, tmp_dir, algo) +
|
||||
"--config=\"{\\\"num_gpus\\\": 0, \\\"num_workers\\\": 1, "
|
||||
"\\\"evaluation_config\\\": {\\\"explore\\\": false}" + fw_ +
|
||||
"}\" " + "--stop=\"{\\\"episode_reward_mean\\\": 190.0}\"" +
|
||||
"}\" " + "--stop=\"{\\\"episode_reward_mean\\\": 150.0}\"" +
|
||||
" --env={}".format(env))
|
||||
|
||||
# Find last checkpoint and use that for the rollout.
|
||||
|
@ -127,7 +127,7 @@ def learn_test_plus_rollout(algo, env="CartPole-v0"):
|
|||
num_episodes += 1
|
||||
mean_reward /= num_episodes
|
||||
print("Rollout's mean episode reward={}".format(mean_reward))
|
||||
assert mean_reward >= 190.0
|
||||
assert mean_reward >= 150.0
|
||||
|
||||
# Cleanup.
|
||||
os.popen("rm -rf \"{}\"".format(tmp_dir)).read()
|
||||
|
@ -170,7 +170,7 @@ def learn_test_multi_agent_plus_rollout(algo):
|
|||
"policy_mapping_fn": policy_fn,
|
||||
},
|
||||
}
|
||||
stop = {"episode_reward_mean": 180.0}
|
||||
stop = {"episode_reward_mean": 150.0}
|
||||
tune.run(
|
||||
algo,
|
||||
config=config,
|
||||
|
@ -220,7 +220,7 @@ def learn_test_multi_agent_plus_rollout(algo):
|
|||
num_episodes += 1
|
||||
mean_reward /= num_episodes
|
||||
print("Rollout's mean episode reward={}".format(mean_reward))
|
||||
assert mean_reward >= 190.0
|
||||
assert mean_reward >= 150.0
|
||||
|
||||
# Cleanup.
|
||||
os.popen("rm -rf \"{}\"".format(tmp_dir)).read()
|
||||
|
|
|
@ -3,7 +3,7 @@ cartpole-es:
|
|||
run: ES
|
||||
stop:
|
||||
episode_reward_mean: 100
|
||||
timesteps_total: 1000000
|
||||
timesteps_total: 500000
|
||||
config:
|
||||
# Works for both torch and tf.
|
||||
framework: tf
|
||||
|
|
Loading…
Add table
Reference in a new issue