From e58a09e2901d705b1bc5ddf58c7a5f2eb90377e5 Mon Sep 17 00:00:00 2001 From: Daniel Weindl Date: Tue, 27 Feb 2024 00:08:48 +0100 Subject: [PATCH] .. --- python/sdist/amici/de_export.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/python/sdist/amici/de_export.py b/python/sdist/amici/de_export.py index e7aa3fd146..0f11bd484b 100644 --- a/python/sdist/amici/de_export.py +++ b/python/sdist/amici/de_export.py @@ -1663,11 +1663,15 @@ def static_indices(self, name: str) -> list[int]: not self._splines or "AmiciSpline" not in str(expr) ) and ( + # If the expression contains dynamic symbols, it might + # still be static. However, checking the derivative + # is currently too expensive, and we rather accept + # false negatives. not expr.has(*dynamic_syms) - or all( - expr.diff(dyn_sym).is_zero - for dyn_sym in dynamic_syms - ) + # or all( + # expr.diff(dyn_sym).is_zero + # for dyn_sym in dynamic_syms + # ) ) ) ]