Phase 5: enzyme usage by system - #7
Merged
Merged
Conversation
edkerk
force-pushed
the
feat/py-phase4-ribosome
branch
from
September 20, 2026 09:17
bd6ab8a to
698edac
Compare
edkerk
force-pushed
the
feat/py-phase5-enzyme-usage
branch
from
September 20, 2026 09:17
c671222 to
309c3a3
Compare
Merged
Capacity usage per enzyme and condition, the annotated systems drawn one panel per pathway, and the numbers written beside the figure. The transformation from per-enzyme usage to capacity usage per system is pure arithmetic on a table, so it is checked against the published output: fed the committed enzymeUsages.txt it reproduces the committed capUsage.txt exactly, to the row order.
edkerk
force-pushed
the
feat/py-phase4-ribosome
branch
from
September 25, 2026 11:33
698edac to
67eaec3
Compare
edkerk
force-pushed
the
feat/py-phase5-enzyme-usage
branch
from
September 25, 2026 11:33
309c3a3 to
d6f163e
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #6. Per enzyme and condition: how much of it the model uses
(mg/gDW) and what fraction of what was available that is. Then the annotated
systems, summarised and drawn.
python -m overflow.analyze_usagewritesenzymeUsages.tsv,capUsage.tsv,systemMedians.tsvand the two figures.Exact parity on the part that can have it
The step from per-enzyme usage to capacity usage per system is pure arithmetic
on a table, so it is checked against the published output rather than described:
fed the committed
enzymeUsages.txt, it reproduces the committedcapUsage.txtexactly — 201 rows, every value, every GO term, in the same row order.
That also pinned a detail worth having in a test: 30 of the 525 annotation rows
are proteins listed under two systems (ADE3 under both amino acid metabolism and
the THF cycle). R's
matchtakes the first, so this does too.Result, against the published one
Median capacity usage per system, GECKO 2 / this pipeline (rate-fitted
models, see #5):
The ribosome trend survives and sharpens. Capacity usage rises monotonically
with dilution rate (26.3, 28.2, 47.3, 57.3, 74.0), where the GECKO 2 models were
flat across the four chemostats (28.8, 33.9, 33.7, 33.6) and only rose at hGR.
The ETC saturates at CN38, CN75 and hGR, as in the published models, and
rises with growth rate. CN4 (40.6) and CN22 (66.8) stay well below the published
100 and 96; I have not traced why.
The respiratory kcats in this model, against GECKO 2's (read from the
prot_coefficients in its S matrix) and the tutorial model the first version of this PR
used:
r_0438r_0439r_1021r_0226The tutorial model's 6000 /s for complex IV made the ETC look cheap and unsaturated
(median 10–17% at the low-uptake conditions). It comes from a bug in geckopy's
and GECKO's kcat matcher, which divides a substrate-specific BRENDA value by the
smallest coefficient in the reaction instead of the matched substrate's own
(BRENDA's 1500 /s divided by oxygen's 0.25); the fix is in
GECKO#484 and
geckopy#57. In this model the
value is 1376 /s.
Reading kcats out of GECKO 2 needs care: its coefficients are
stoichiometry / kcat, so the smallest implied value belongs to thehighest-stoichiometry subunit, not to the enzyme. Taken at face value it makes
ATP synthase look like 12 /s, which is really the c-ring at stoichiometry 10.
The PP shunt and TCA medians fall to about zero where the published ones do
not. The shunt is off at CN38 and CN75 because NADPH comes from IDP2 and
aldehyde dehydrogenase instead (see #5); the TCA median at hGR is 0.1% because
7 of the 21 annotated TCA enzymes are unused there, which puts the median on an
unused one. A median over a handful of enzymes moves a lot when a few switch off.
Figures
Ported from
boxplotEnzymeUsage.R: one panel per pathway, one box percondition, panels sharing a 0-100 axis. The publication's own four colours fail
a colourblind-safety check on two counts and put the beige at 1.83:1 against the
surface, so these use a validated four-slot palette instead; colour is redundant
with the panel title either way, and the numbers behind every panel are written
beside the figure as
capUsage.tsv.Tests
158 tests in this branch.