main.py 558 Bytes
Newer Older
navidmokh's avatar
navidmokh committed
1
2
3
4
5
6
7
import json
import sys

from src.core.dryvrmain import verify
from src.common.utils import importSimFunction

from src.plotter.parser import parse
8
9
import random
import numpy as np
navidmokh's avatar
navidmokh committed
10
11
12
13

assert ".json" in sys.argv[-1], "Please provide json input file"
with open(sys.argv[-1], 'r') as f:
	data = json.load(f)
14
15
simFunction = importSimFunction(data["directory"])
safety, reach = verify(data, simFunction)
li213's avatar
li213 committed
16
17
18
19
20
21
if safety == 'SAFE':
	lines = reach.raw.split("\n")
	print(type(lines[0]), lines[0])
	initNode, y_min, y_max = parse(lines)
# elif safety == 'UNSAFE':
	# print('')