Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Daniel Weindl <dweindl@users.noreply.github.com>
  • Loading branch information
Fabian Fröhlich and dweindl authored Apr 3, 2022
1 parent 15ea99d commit 836391f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions python/amici/pysb_import.py
Original file line number Diff line number Diff line change
Expand Up @@ -1015,12 +1015,12 @@ def _construct_conservation_from_prototypes(
# x_j = (T - sum_i≠j(a_i * x_i))/a_j
# law: sum_i≠j(a_i * x_i))/a_j
# state: x_j
target_expression = sp.Add(*[
target_expression = sp.Add(*(
sp.Symbol(f'__s{ix}')
* extract_monomers(specie).count(monomer_name)
for ix, specie in enumerate(pysb_model.species)
if ix != target_index
]) / extract_monomers(pysb_model.species[
)) / extract_monomers(pysb_model.species[
target_index
]).count(monomer_name)
# normalize by the stoichiometry of the target species
Expand Down

0 comments on commit 836391f

Please sign in to comment.