Skip to content

Commit

Permalink
..
Browse files Browse the repository at this point in the history
  • Loading branch information
dweindl committed Feb 26, 2024
1 parent 2b717f7 commit d855766
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions python/sdist/amici/de_export.py
Original file line number Diff line number Diff line change
Expand Up @@ -1562,8 +1562,8 @@ def static_indices(self, name: str) -> list[int]:
return res

if name == "w":
dwdx = self.eq("dwdx")
dwdw = self.eq("dwdw")
dwdx = self.sym("dwdx")
dwdw = self.sym("dwdw")
w = self.eq("w")

# Check for direct (via `t`) or indirect (via `x`, `h`, or splines)
Expand Down Expand Up @@ -1662,8 +1662,12 @@ def static_indices(self, name: str) -> list[int]:
# splines: non-static
not self._splines or "AmiciSpline" not in str(expr)
)
and all(
expr.diff(dyn_sym).is_zero for dyn_sym in dynamic_syms
and (
not expr.has(dynamic_syms)
or all(
expr.diff(dyn_sym).is_zero
for dyn_sym in dynamic_syms
)
)
)
]
Expand Down

0 comments on commit d855766

Please sign in to comment.