forked from benchoi93/TrajGAIL
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.py
42 lines (38 loc) · 1.4 KB
/
main.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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import os
import sys
import argparse
import subprocess
# sys.argv=['']
parser = argparse.ArgumentParser()
parser.add_argument('--model', default="MMC", type=str)
parser.add_argument('--data', default="Single_OD", type=str)
args = parser.parse_args()
datalist = os.listdir("data/" + args.data)
# datalist = datalist[1:]
if args.model == "IRL":
# IRL Test
for data0 in datalist:
print(os.path.join('.','data',args.data,data0))
subprocess.run(["python" ,
os.path.join('.','scripts','irl','demo_shortestpath.py'),
"--data",
os.path.join('.','data',args.data,data0)
])
elif args.model == "MMC":
# MMC Test
for data0 in datalist:
print(os.path.join('.','data',args.data,data0))
subprocess.run(["python" ,
os.path.join('.','scripts','behavior_clone','run_bc_mmc.py'),
"--data",
os.path.join('.','data',args.data,data0)
])
elif args.model == "RNN":
# RNN Test
for data0 in datalist:
print(os.path.join('.','data',args.data,data0))
subprocess.run(["python" ,
os.path.join('.','scripts','behavior_clone','run_bc_rnn.py'),
"--data",
os.path.join('.','data',args.data,data0)
])