Quantcast
Channel: Hacker News
Viewing all articles
Browse latest Browse all 25817

OpenAI Universe

$
0
0
import gymimport universe # register the universe environments

env = gym.make('flashgames.DuskDrive-v0')
env.configure(remotes=1) # create one flashgames Docker container
observation_n = env.reset()whileTrue:# your agent generates action_n at 60 frames per second
  action_n = [[('KeyEvent', 'ArrowUp', True)] for ob in observation_n]
  observation_n, reward_n, done_n, info = env.step(action_n)
  env.render()

Viewing all articles
Browse latest Browse all 25817

Trending Articles