Skip to content

Commit

Permalink
[RLlib] Fix waterworld example and test (ray-project#32117)
Browse files Browse the repository at this point in the history
* Remove empty parser.add_argument() in test file
* remove --framework=torch
* fix BUILD
* use training_iteration as stopping cirterion

Signed-off-by: Artur Niederfahrenhorst <[email protected]>
  • Loading branch information
ArturNiederfahrenhorst authored Jan 31, 2023
1 parent 2137945 commit 12ff13d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion rllib/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -3344,7 +3344,7 @@ py_test(
tags = ["team:rllib", "examples"],
size = "medium",
srcs = ["examples/multi_agent_independent_learning.py"],
args = ["--stop-iters=4", "--framework=torch"]
args = ["--num-gpus=0", "--as-test"]
)

py_test(
Expand Down
3 changes: 1 addition & 2 deletions rllib/examples/multi_agent_independent_learning.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
help="Whether this script should be run as a test: Only one episode will be "
"sampled.",
)
parser.add_argument()

if __name__ == "__main__":
args = parser.parse_args()
Expand All @@ -45,7 +44,7 @@ def env_creator(args):

if args.as_test:
# Only a compilation test of running waterworld / independent learning.
stop = {"iterations": 1}
stop = {"training_iteration": 1}
else:
stop = {"episodes_total": 60000}

Expand Down

0 comments on commit 12ff13d

Please sign in to comment.