You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think it would be nice to register your custom environment and
use it like below code for portability.
import gym
import slitherinenv
env = gym.make('SlitherinEnv-v0')
env.__init__(num_agents=1)
env.reset()
for i_episode in range(20):
observation = env.reset()
for t in range(100):
env.render()
#print(observation)
action = env.action_space.sample()
observation, reward, done, info = env.step(action)
if done:
print("Episode finished after {} timesteps".format(t+1))
break
The text was updated successfully, but these errors were encountered:
I think it would be nice to register your custom environment and
use it like below code for portability.
The text was updated successfully, but these errors were encountered: