ray/doc/source/ray-overview/doc_test/ray_rllib.py

9 lines
207 B
Python
Raw Normal View History

from ray import tune
from ray.rllib.agents.ppo import PPOTrainer
tune.run(
PPOTrainer,
stop={"episode_len_mean": 20},
config={"env": "CartPole-v0", "framework": "torch", "log_level": "INFO"},
)