mirror of
https://github.com/wassname/ray.git
synced 2026-09-11 12:43:20 +08:00
[rllib] Refactor DQN to use an Evaluator abstraction (#1276)
This introduces rllib.Evaluator and rllib.Optimizer classes. Optimizers encapsulate a particular distributed optimization strategy for RL. Evaluators encapsulate the model graph, and once implemented, any Optimizer may be "plugged in" to any algorithm that implements the Evaluator interface.
This commit is contained in:
@@ -105,6 +105,13 @@ docker run --rm --shm-size=10G --memory=10G $DOCKER_SHA \
|
||||
--stop '{"training_iteration": 2}' \
|
||||
--config '{"lr": 1e-3, "schedule_max_timesteps": 100000, "exploration_fraction": 0.1, "exploration_final_eps": 0.02, "dueling": false, "hiddens": [], "model": {"fcnet_hiddens": [64], "fcnet_activation": "relu"}}'
|
||||
|
||||
docker run --rm --shm-size=10G --memory=10G $DOCKER_SHA \
|
||||
python /ray/python/ray/rllib/train.py \
|
||||
--env CartPole-v0 \
|
||||
--run DQN \
|
||||
--stop '{"training_iteration": 2}' \
|
||||
--config '{"async_updates": true, "num_workers": 2}'
|
||||
|
||||
docker run --rm --shm-size=10G --memory=10G $DOCKER_SHA \
|
||||
python /ray/python/ray/rllib/train.py \
|
||||
--env FrozenLake-v0 \
|
||||
|
||||
Reference in New Issue
Block a user