-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdata.py
27 lines (24 loc) · 855 Bytes
/
data.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
import sys
import gym
import ic3net_envs
from env_wrappers import *
def init(env_name, args, final_init=True):
if env_name == 'predator_prey':
env = gym.make('PredatorPrey-v0', disable_env_checker=True) #JenniBN, edited to work with latest gym
if args.display:
env.init_curses()
env.multi_agent_init(args)
env = GymWrapper(env)
elif env_name == 'traffic_junction':
env = gym.make('TrafficJunction-v0', disable_env_checker=True) #JenniBN, edited to work with latest gym
if args.display:
env.init_curses()
env.multi_agent_init(args)
env = GymWrapper(env)
elif env_name == 'grf':
env = gym.make('GRFWrapper-v0')
env.multi_agent_init(args)
env = GymWrapper(env)
else:
raise RuntimeError("wrong env name")
return env