-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathhyperprob.py
More file actions
31 lines (27 loc) · 1.09 KB
/
Copy pathhyperprob.py
File metadata and controls
31 lines (27 loc) · 1.09 KB
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
from hyperprob.inputparser import parseArguments
from hyperprob.utility import common
from hyperprob.propertyparser import Property
from hyperprob.modelparser import Model
from hyperprob.modelchecker import ModelChecker
import traceback
def main():
try:
input_args = parseArguments()
if input_args.checkProperty:
hyperproperty = Property(input_args.hyperString)
hyperproperty.parseProperty(True)
if input_args.checkModel:
model = Model(input_args.modelPath)
model.parseModel(False)
if not input_args.checkModel and not input_args.checkProperty:
hyperproperty = Property(input_args.hyperString)
hyperproperty.parseProperty(False)
model = Model(input_args.modelPath)
model.parseModel(True)
modelchecker = ModelChecker(model, hyperproperty)
modelchecker.modelCheck()
print("\n")
except Exception as err:
common.colourerror("Unexpected error encountered: " + str(err) + "\n" + str(traceback.print_exc()))
if __name__ == "__main__":
main()