You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Note the use of 0.0 instead of 0 in the conditioning event.
It appears to be an error from Sympy.
>>> sympy.Intersection(sympy.Range(10,11,1), sympy.Interval(-sympy.oo, 0.0))
Traceback (most recent call last):
File "/home/fsaad/sum-product-dsl/.venv/lib/python3.6/site-packages/sympy/core/compatibility.py", line 410, in as_int
raise TypeError
TypeError
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/fsaad/sum-product-dsl/.venv/lib/python3.6/site-packages/sympy/sets/fancysets.py", line 426, in __new__
for w in (start, stop, step)]
File "/home/fsaad/sum-product-dsl/.venv/lib/python3.6/site-packages/sympy/sets/fancysets.py", line 426, in <listcomp>
for w in (start, stop, step)]
File "/home/fsaad/sum-product-dsl/.venv/lib/python3.6/site-packages/sympy/core/compatibility.py", line 416, in as_int
raise ValueError('%s is not an integer' % (n,))
ValueError: 1.00000000000000 is not an integer
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/fsaad/sum-product-dsl/.venv/lib/python3.6/site-packages/sympy/sets/sets.py", line 1213, in __new__
return simplify_intersection(args)
File "/home/fsaad/sum-product-dsl/.venv/lib/python3.6/site-packages/sympy/sets/sets.py", line 1966, in simplify_intersection
new_set = intersection_sets(s, t)
File "/home/fsaad/sum-product-dsl/.venv/lib/python3.6/site-packages/sympy/multipledispatch/dispatcher.py", line 198, in __call__
return func(*args, **kwargs)
File "/home/fsaad/sum-product-dsl/.venv/lib/python3.6/site-packages/sympy/sets/handlers/intersection.py", line 104, in intersection_sets
return intersection_sets(a, Range(start, end + 1))
File "/home/fsaad/sum-product-dsl/.venv/lib/python3.6/site-packages/sympy/sets/fancysets.py", line 431, in __new__
[0, 1/10, 1/5].'''))
ValueError:
Finite arguments to Range must be integers; `imageset` can define
other cases, e.g. use `imageset(i, i/10, Range(3))` to give [0, 1/10,
1/5].
The text was updated successfully, but these errors were encountered:
When running
spn.prob(GPA <= 0.0)
on Indian GPA, error is encountered at this linehttps://github.com/probcomp/sum-product-dsl/blob/aafed1006b8f28708290911dbf946765139dd495/src/spn.py#L961
Note the use of
0.0
instead of0
in the conditioning event.It appears to be an error from Sympy.
The text was updated successfully, but these errors were encountered: