Skip to content

Phase 5: enzyme usage by system - #7

Merged
edkerk merged 1 commit into
masterfrom
feat/py-phase5-enzyme-usage
Sep 25, 2026
Merged

edkerk merged 1 commit into
masterfrom
feat/py-phase5-enzyme-usage

Conversation

@edkerk

@edkerk edkerk commented Sep 19, 2026 •

Copy link
Copy Markdown
Member

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_usage writes enzymeUsages.tsv, capUsage.tsv,
systemMedians.tsv and 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 committed capUsage.txt
exactly — 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 match takes 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):

system CN4 CN22 CN38 CN75 hGR
Ribosome 28.8 / 26.3 33.9 / 28.2 33.7 / 47.3 33.6 / 57.3 66.4 / 74.0
ETC 100.0 / 40.6 96.0 / 66.8 100.0 / 100.0 70.6 / 100.0 99.5 / 100.0
PP shunt 5.6 / 11.0 11.7 / 1.9 20.5 / 0.0 20.6 / 0.0 41.7 / 6.1
Glycolysis 0.4 / 1.7 0.5 / 3.1 5.8 / 5.8 10.3 / 11.5 24.1 / 29.2
TCA cycle 2.1 / 3.7 2.1 / 7.1 2.2 / 16.1 0.0 / 43.9 9.2 / 0.1
Amino acid metabolism 1.7 / 1.3 4.6 / 1.9 2.1 / 2.8 3.2 / 3.4 5.6 / 7.8
Nitrogen metabolism 10.3 / 0.9 1.7 / 7.1 2.3 / 0.1 4.8 / 0.1 18.0 / 0.1
THF cycle 11.9 / 4.0 1.6 / 6.0 9.2 / 12.9 0.3 / 12.6 5.9 / 16.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:

reaction GECKO 2 kcat tutorial model this model
r_0438 cytochrome c oxidase (complex IV) 693.5 /s 6000 /s 1376 /s
r_0439 ubiquinol:cytochrome c reductase (complex III) 110 /s 240 /s 290 /s
r_1021 succinate dehydrogenase 167 /s 250–260 /s 250–260 /s
r_0226 ATP synthase 120 /s 120 /s 85 /s forward, 120 /s reverse

The 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 the
highest-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 per
condition, 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.

@edkerk
edkerk force-pushed the feat/py-phase4-ribosome branch from bd6ab8a to 698edac Compare September 20, 2026 09:17
@edkerk
edkerk force-pushed the feat/py-phase5-enzyme-usage branch from c671222 to 309c3a3 Compare September 20, 2026 09:17
@edkerk edkerk mentioned this pull request Sep 20, 2026
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
edkerk force-pushed the feat/py-phase4-ribosome branch from 698edac to 67eaec3 Compare September 25, 2026 11:33
@edkerk
edkerk force-pushed the feat/py-phase5-enzyme-usage branch from 309c3a3 to d6f163e Compare September 25, 2026 11:33
@edkerk
edkerk changed the base branch from feat/py-phase4-ribosome to master September 25, 2026 13:12
@edkerk
edkerk merged commit 78b46c9 into master Sep 25, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant