fix bug in robustness calculation + move synth for it's on module
This commit is contained in:
parent
9b42d9bb57
commit
da669f088d
4 changed files with 58 additions and 52 deletions
|
|
@ -11,13 +11,15 @@ ex1 = ("2*A > 3", -1)
|
|||
ex2 = ("F[0, 1](2*A > 3)", 5)
|
||||
ex3 = ("F[1, 0](2*A > 3)", -oo)
|
||||
ex4 = ("G[1, 0](2*A > 3)", oo)
|
||||
ex5 = ("(A < 0)", -1)
|
||||
ex6 = ("G[0, 0.1](A < 0)", -1)
|
||||
x = pd.DataFrame([[1,2], [1,4], [4,2]], index=[0,0.1,0.2],
|
||||
columns=["A", "B"])
|
||||
|
||||
|
||||
|
||||
class TestSTLRobustness(unittest.TestCase):
|
||||
@params(ex1, ex2, ex3, ex4)
|
||||
@params(ex1, ex2, ex3, ex4, ex5, ex6)
|
||||
def test_stl(self, phi_str, r):
|
||||
phi = stl.parse(phi_str)
|
||||
stl_eval = stl.robustness.pointwise_robustness(phi)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue