Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[RLlib] MADDPG TrainerConfig objects. #25255

Merged
merged 55 commits into from
May 30, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
9162935
config objects for ddpg and simple q
maxpumperla Apr 29, 2022
2167961
Apply suggestions from code review
sven1977 Apr 29, 2022
38652d1
rm circ imports
maxpumperla May 2, 2022
6c5ad4d
Merge branch 'mp_ddpg_config_objects' of github.com:ray-project/ray i…
maxpumperla May 2, 2022
89beffa
lint
maxpumperla May 2, 2022
6abd002
Merge branch 'master' into mp_ddpg_config_objects
maxpumperla May 2, 2022
57a91fa
fix some tests
maxpumperla May 2, 2022
8ba967d
Merge branch 'mp_ddpg_config_objects' of github.com:ray-project/ray i…
maxpumperla May 2, 2022
2769673
Merge branch 'master' into mp_ddpg_config_objects
maxpumperla May 2, 2022
bd9f42f
lint
maxpumperla May 2, 2022
20d2fc8
fix
maxpumperla May 2, 2022
049d699
Merge branch 'master' into mp_ddpg_config_objects
maxpumperla May 2, 2022
cea8824
fix test
maxpumperla May 2, 2022
7d5939b
xMerge branch 'mp_ddpg_config_objects' of github.com:ray-project/ray …
maxpumperla May 2, 2022
bfefae1
Merge branch 'master' into mp_ddpg_config_objects
maxpumperla May 4, 2022
a784f41
fix exploration config
maxpumperla May 4, 2022
b8c1e91
Merge branch 'mp_ddpg_config_objects' of github.com:ray-project/ray i…
maxpumperla May 4, 2022
33ffdcf
wip.
sven1977 May 5, 2022
d076c96
wip.
sven1977 May 5, 2022
0e8dc19
Merge branch 'master' of https://github.com/ray-project/ray into mp_d…
sven1977 May 5, 2022
2782efd
wip.
sven1977 May 5, 2022
1e0142a
wip.
sven1977 May 5, 2022
830f08f
wip.
sven1977 May 5, 2022
8612872
Merge branch 'master' of https://github.com/ray-project/ray into mp_d…
sven1977 May 5, 2022
1e43f00
wip.
sven1977 May 5, 2022
d5b3d3c
Merge branch 'master' of https://github.com/ray-project/ray into mp_d…
sven1977 May 6, 2022
f0e00b1
wip.
sven1977 May 6, 2022
282dee9
wip.
sven1977 May 6, 2022
047f849
wip.
sven1977 May 6, 2022
5fb157e
wip.
sven1977 May 6, 2022
efc770e
wip.
sven1977 May 6, 2022
97f879d
wip.
sven1977 May 6, 2022
60587f8
wip.
sven1977 May 6, 2022
5cd6851
wip.
sven1977 May 6, 2022
595bdce
wip.
sven1977 May 6, 2022
3fc9d30
Merge branch 'master' of https://github.com/ray-project/ray into mp_d…
sven1977 May 6, 2022
eeca30b
Merge branch 'master' of https://github.com/ray-project/ray into mp_d…
sven1977 May 7, 2022
84d01e4
wip.
sven1977 May 7, 2022
a0900cb
wip.
sven1977 May 7, 2022
68d3ee3
wip.
sven1977 May 7, 2022
9111531
wip.
sven1977 May 7, 2022
0f8880f
wip.
sven1977 May 8, 2022
bd5154f
wip.
sven1977 May 9, 2022
4929134
merge
sven1977 May 9, 2022
9e75d36
wip
sven1977 May 9, 2022
bb02896
wip
sven1977 May 9, 2022
949ff89
Merge branch 'master' of https://github.com/ray-project/ray into mp_d…
sven1977 May 10, 2022
0e7996f
wip.
sven1977 May 10, 2022
88d1823
Merge branch 'master' of https://github.com/ray-project/ray into mp_d…
sven1977 May 11, 2022
83110fb
wip.
sven1977 May 11, 2022
33f03af
Merge branch 'master' of https://github.com/ray-project/ray into mp_d…
sven1977 May 12, 2022
e6af692
wip.
sven1977 May 12, 2022
b38f586
wip.
sven1977 May 12, 2022
a1cb95b
Merge branch 'master' of https://github.com/ray-project/ray into maml…
sven1977 May 27, 2022
d8bb116
wip
sven1977 May 27, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 0 additions & 18 deletions rllib/algorithms/ddpg/tests/test_ddpg.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import numpy as np
import re
import unittest
from tempfile import TemporaryDirectory

import ray
import ray.rllib.algorithms.ddpg as ddpg
Expand Down Expand Up @@ -64,23 +63,6 @@ def test_ddpg_compilation(self):
check(a, 500)
trainer.stop()

def test_ddpg_checkpoint_save_and_restore(self):
"""Test whether a DDPGTrainer can save and load checkpoints."""
config = ddpg.DEFAULT_CONFIG.copy()
config["num_workers"] = 1
config["num_envs_per_worker"] = 2
config["replay_buffer_config"]["learning_starts"] = 0
config["exploration_config"]["random_timesteps"] = 100

# Test against all frameworks.
for _ in framework_iterator(config, with_eager_tracing=True):
trainer = ddpg.DDPGTrainer(config=config, env="Pendulum-v1")
trainer.train()
with TemporaryDirectory() as temp_dir:
checkpoint = trainer.save(temp_dir)
trainer.restore(checkpoint)
trainer.stop()

def test_ddpg_exploration_and_with_random_prerun(self):
"""Tests DDPG's Exploration (w/ random actions for n timesteps)."""

Expand Down
8 changes: 6 additions & 2 deletions rllib/algorithms/maddpg/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
from ray.rllib.algorithms.maddpg.maddpg import MADDPGTrainer, DEFAULT_CONFIG
from ray.rllib.algorithms.maddpg.maddpg import (
MADDPGConfig,
MADDPGTrainer,
DEFAULT_CONFIG,
)

__all__ = ["MADDPGTrainer", "DEFAULT_CONFIG"]
__all__ = ["MADDPGConfig", "MADDPGTrainer", "DEFAULT_CONFIG"]
Loading