In [1]:
%%html
<style>
img {float:left}
</style>
sbmlutils is a collection of python utilities for working with SBML models
implemented on top of the libSBML python bindings.
Features among others
The project code is available from https://github.com/matthiaskoenig/sbmlutils
Slides available at http://bit.ly/sbmlutils-flash
pip install sbmlutils
In [2]:
from sbmlutils.report import sbmlreport
sbmlreport.create_sbml_report('./examples/glucose/Hepatic_glucose_3.xml',
out_dir='./examples/glucose', validate=True)
Parameters for AssignmentRules)fbc and comp helpershttps://sbmlutils.readthedocs.io/en/latest/notebooks/modelcreator.html#Create-FBA-Model
core, comp and fbc
In [3]:
from __future__ import absolute_import, print_function
import os
import tempfile
import sbmlutils
from sbmlutils import dfba
from sbmlutils.dfba import utils
from sbmlutils.dfba.toy_wholecell import settings as toysettings
from sbmlutils.dfba.toy_wholecell import model_factory as toyfactory
from sbmlutils.dfba.toy_wholecell import simulate as toysimulate
test_dir = tempfile.mkdtemp()
# create toy model
toyfactory.create_model(test_dir)
sbml_path = os.path.join(utils.versioned_directory(test_dir, toyfactory.version),
toysettings.top_file)
print(sbml_path)
In [4]:
from IPython.display import display, HTML
# simulate
dfs = toysimulate.simulate_toy(sbml_path, test_dir, dts=[1.0], figures=False)
display(dfs[0].head(10))
toysimulate.print_species(dfs=dfs)
toysimulate.print_fluxes(dfs=dfs)