7.1.2.4. pta.flux_space

Description of the flux space of a metabolic network.

7.1.2.4.1. Module Contents

class pta.flux_space.FluxSpace(S: numpy.ndarray, lb: numpy.ndarray, ub: numpy.ndarray, reaction_ids: List[str], metabolite_ids: List[str])[source]

Description of the flux space of a metabolic network.

Parameters:
  • S (np.ndarray) – Stoichiometric matrix of the network.

  • lb (np.ndarray) – Vector of lower bounds on the reaction fluxes.

  • ub (np.ndarray) – Vector of upper bounds on the reaction fluxes.

  • reaction_ids (List[str]) – Identifiers of the reactions in the network.

  • metabolite_ids (List[str]) – Identifiers of the metabolites in the network.

property S: numpy.ndarray[source]

Gets the stoichiometric matrix of the network.

property lb: numpy.ndarray[source]

Gets the vector of lower bounds on the reaction fluxes.

property ub: numpy.ndarray[source]

Gets the vector of upper bounds on the reaction fluxes.

property reaction_ids: List[str][source]

Gets the IDs of the reactions in the flux space.

property metabolite_ids: List[str][source]

Gets the IDs of the metabolites in the flux space.

property n_metabolites: int[source]

Gets the number of metabolites in the network.

property n_reactions: int[source]

Gets the number of reactions in the network.

property n_reversible_reactions: int[source]

Gets the number of reversible reactions in the network.

copy() FluxSpace[source]

Create a copy of this object.

Returns:

A copy of this object.

Return type:

FluxSpace

static from_cobrapy_model(model: cobra.Model) FluxSpace[source]

Creates an instance of this class from a cobrapy model.

Parameters:

model (cobra.Model) – The input model.

Returns:

The constructed object.

Return type:

FluxSpace

class pta.flux_space.FluxSpaceBasis(flux_space: FluxSpace)[source]

Bases: object

Full-dimensional basis of the flux space. The parametrization is automatically rounded using PolyRound.

property G: numpy.ndarray[source]

Gets the left-hand side of the constraints of the flux space.

property h: numpy.ndarray[source]

Gets the right-hand side of the constraints of the flux space.

property to_fluxes_transform: Tuple[numpy.ndarray, numpy.ndarray][source]

Gets the transform from a point in the model to a point in the flux space.

property dimensionality: int[source]

Gets the dimensionality of the flux space.