Skip to main content

Enzax

Tests Project Status: WIP – Initial development is in progress, but there has not yet been a stable, usable release suitable for the public. Supported Python versions: 3.12 and newer Documentation Status

Enzax is a library of automatically differentiable equations and solvers for modelling networks of enzyme-catalysed reactions, written in JAX.

Enzax provides straightforward, fast and interoperable access to the gradients of realistic metabolic network models, allowing you to incorporate these models in your MCMC and machine learning algorithms when you want to, for example, predict the effect of down-regulating an enzyme on the yield of a fermentation experiment.

Installation

pip install enzax

Usage

Find a kinetic model's steady state

from enzax.examples import methionine
from enzax.steady_state import get_steady_state
from jax import numpy as jnp

guess = jnp.full((len(model.balanced_species),), 0.01)

steady_state = get_steady_state(methionine.model, guess, methionine.parameters)

get_steady_state_hybrid takes the same arguments and tries a short Newton solve first, which skips the integration when the guess is already good.

Find a steady state's Jacobian with respect to all parameters

import jax
from enzax.examples.methionine import model, parameters
from enzax.parameters import get_parameter_position
from enzax.steady_state import get_steady_state
from jax import numpy as jnp

guess = jnp.full((len(model.balanced_species),), 0.01)

jacobian = jax.jacrev(get_steady_state, argnums=2)(model, guess, parameters)
# Each parameter is one flat array, so ask the model's labels which column
# belongs to GNMT1's turnover number.
pos = get_parameter_position(model.parameter_labelling, "log_kcat", "GNMT1")
jacobian["log_kcat"][:, pos]
Array([-3.83561719e-07, -9.66801513e-06,  3.38183091e-10,  3.15564888e-09,
        5.28588199e-08], dtype=float64)

Load a kinetic model from an sbml file

from enzax.sbml import load_libsbml_model_from_url, sbml_to_enzax

url = "https://raw.githubusercontent.com/dtu-qmcm/enzax/refs/heads/main/tests/data/exampleode.xml"

libsbml_model = load_libsbml_model_from_url(url)
# or to load an sbml file from your computer:
# libsbml_model = load_libsbml_model_from_file(path_to_file)

model, parameters = sbml_to_enzax(libsbml_model)

Metadata

Release files for enzax 0.4.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for enzax 0.4.0
File Size Uploaded
enzax-0.4.0.tar.gz 298.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for enzax 0.4.0
File Interpreter ABI Platform
enzax-0.4.0-py3-none-any.whl Python 3 none any Details

Total release size: 407.0 kB

Release files / enzax-0.4.0.tar.gz

Download URL enzax-0.4.0.tar.gz
Size 298.2 kB
Tags Source
SHA-256 checksum
How to use checksums
87201073e2a6ded27e1d209dcd7d80775e5f9768c84b6e1bfd37626079b669ed
BLAKE2b-256 checksum
How to use checksums
8d547ad7947f07c24e2321747f0b2afc9e5f0c21c979213680048acf2bd5293a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 28, 2026.

Transparency log

Release files / enzax-0.4.0-py3-none-any.whl

Download URL enzax-0.4.0-py3-none-any.whl
Size 108.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a613e23e50bbf1732cda2e2009dc8acccd354ad4ad5cc835318b285fb5b83b1c
BLAKE2b-256 checksum
How to use checksums
63972e22fc15bf25add09e25f27d8855fe02b3738c8b07e7302714275e1cb27b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 28, 2026.

Transparency log

Release history Release notifications | RSS feed

0.5.0

2 release files

This release

0.4.0 This release

2 release files

0.3.0

2 release files

0.2.3

2 release files

0.2.2

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page