File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change 1616def sympify_petab (expr : str | int | float | sp .Basic ) -> sp .Expr | sp .Basic :
1717 """Convert PEtab math expression to sympy expression.
1818
19- .. note::
20-
21- All symbols in the returned expression will have the ``real=True``
22- assumption.
2319
2420 Args:
2521 expr: PEtab math expression.
@@ -31,6 +27,11 @@ def sympify_petab(expr: str | int | float | sp.Basic) -> sp.Expr | sp.Basic:
3127 Returns:
3228 The sympy expression corresponding to `expr`.
3329 Boolean values are converted to numeric values.
30+
31+ .. note::
32+
33+ All symbols in the returned expression will have the ``real=True``
34+ assumption.
3435 """
3536 if isinstance (expr , sp .Basic ):
3637 return sympify_petab (petab_math_str (expr ))
Original file line number Diff line number Diff line change @@ -29,7 +29,6 @@ def test_assumptions():
2929 assert sympify_petab ("x" ).is_real
3030
3131 # non-real symbols are changed to real
32- # TODO: should we raise an error instead?
3332 assert sympify_petab (sp .Symbol ("x" , real = False )).is_real
3433
3534
You can’t perform that action at this time.
0 commit comments