Skip to main content

CBMPy: PySCeS Constraint Based Modelling

Project description

PySCeS CBMPy (http://cbmpy.sourceforge.net) is a new platform for constraint based modelling and analysis. It has been designed using principles developed in the PySCeS simulation software project: usability, flexibility and accessibility. Its architecture is both extensible and flexible using data structures that are intuitive to the biologist (metabolites, reactions, compartments) while transparently translating these into the underlying mathematical structures used in advanced analysis (LP’s, MILP’s).

PySCeS CBMPy implements popular analyses such as FBA, FVA, element/charge balancing, network analysis and model editing as well as advanced methods developed specifically for the ecosystem modelling: minimal distance methods, flux minimization and input selection. To cater for a diverse range of modelling needs PySCeS CBMPy supports user interaction via:

  • interactive console, scripting for advanced use or as a library for software development

  • GUI, for quick access to a visual representation of the model, analysis methods and annotation tools

  • SOAP based web services: using the Mariner framework much high level functionality is exposed for integration into web tools

For more information on the development and use of PySCeS CBMPy feel free to contact me:

PySCeS-CBMPy has been tested on Windows 7 and 8.1, Mac OSX and Ubuntu Linux 12.04, 14.04, 16.04. It is compatible with both Python 2.7+ and includes experimental support for Python 3.4+ It is highly recommend to use Python 2.7 as not all Python package dependencies (extended functionality) are available for Python 3.

PySCeS CBMPy is now accessible as a Python module cbmpy in place of the the previously used pyscescbm. This release contains both modules with a reminder to update old scripts to new. CBMPy includes support for reading/writing models in SBML3 FBC versions 1 and 2 as well as COBRA dialect, Excel spreadsheets and Python.

To use follow the installation instructions given below and try the following in a Python shell:

import cbmpy
cmod = cbmpy.readSBML3FBC('cbmpy_test_core')
cbmpy.doFBA(cmod)

New Ipython notebook tutorials will be available soon. Happy modelling!

The following installation instructions are for Ubuntu 14.04 but should be adaptable to any Linux package managment system, OSX, Debian, etc. Except for GLPK (4.47) and SymPy (0.7.4 or newer) no specific library version is required. For more detailed installation instructions and Windows please see the online documentation http://cbmpy.sourceforge.net/reference/install_doc.html

Python2

First we create a scientific Python workbench:

sudo apt-get install python-dev python-numpy python-scipy python-matplotlib  python-pip
sudo apt-get install python-sympy python-suds python-xlrd python-xlwt python-h5py
sudo apt-get install python-wxgtk2.8 python-qt4
sudo apt-get install ipython ipython-notebook

libSBML

Installing libSBML is now easy using Pip:

sudo apt-get install libxml2 libxml2-dev
sudo apt-get install zlib1g zlib1g-dev
sudo apt-get install bzip2 libbz2-dev

sudo pip install python-libsbml-experimental

glpk/python-glpk

GLPK needs to be version 4.47 to work with glpk-0.3:

sudo apt-get install libgmp-dev

cd GLPK source (e.g. glpk-4.47):

./configure --with-gmp
make
make check
sudo make install
sudo ldconfig

cd to python-glpk source (glpk-0.3):

make
sudo make install

CBMPy

Finally, install CBMPy:

python setup.py build sdist
sudo python setup.py install

Python3 (experimental)

Not all dependencies are available for Python3:

sudo apt-get install python3-dev python3-numpy python3-scipy python3-matplotlib  python3-pip
sudo apt-get install python3-xlrd python3-h5py

# need to find out what is going on with Python3 and xlwt suds
# easy_install3 sympy ???
# wxPython and PyQt4 not in Ubuntu P3 builds yet

sudo apt-get install ipython3 ipython3-notebook

sudo apt-get install libxml2 libxml2-dev
sudo apt-get install zlib1g zlib1g-dev
sudo apt-get install bzip2 libbz2-dev

sudo pip3 install python-libsbml-experimental

sudo apt-get install python-qt4 python-qt4-dev python-sip python-sip-dev build-essential

More information in the docs/ directory.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

cbmpy-0.7.4.zip (7.2 MB view details)

Uploaded Source

cbmpy-0.7.4.tar.gz (6.9 MB view details)

Uploaded Source

Built Distributions

cbmpy-0.7.4.win-amd64.msi (4.4 MB view details)

Uploaded Source

cbmpy-0.7.4.win-amd64.exe (4.4 MB view details)

Uploaded Source

File details

Details for the file cbmpy-0.7.4.zip.

File metadata

  • Download URL: cbmpy-0.7.4.zip
  • Upload date:
  • Size: 7.2 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for cbmpy-0.7.4.zip
Algorithm Hash digest
SHA256 f475c41c250015e69b1f985327ae833b3f5032bb74ec859ea9c8d67f839cb00e
MD5 6bb67c8a47277cae87a19b15ad7a7d96
BLAKE2b-256 0ab82a54ff57ffc9e3ce16fd8d83e373300bba0b1bfae3d7ace946fb2a8159a9

See more details on using hashes here.

File details

Details for the file cbmpy-0.7.4.tar.gz.

File metadata

  • Download URL: cbmpy-0.7.4.tar.gz
  • Upload date:
  • Size: 6.9 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for cbmpy-0.7.4.tar.gz
Algorithm Hash digest
SHA256 29a0fb6d927a0906ce6491fd99e3dfd039803669fa1fcc72d79abd2534204667
MD5 ba9773747fe45fddbff67f1d9e4a2b24
BLAKE2b-256 04ba52736ef1763864ef6db2f8f30f831890ae2253ffe84b8d3628a79cb0a53e

See more details on using hashes here.

File details

Details for the file cbmpy-0.7.4.win-amd64.msi.

File metadata

File hashes

Hashes for cbmpy-0.7.4.win-amd64.msi
Algorithm Hash digest
SHA256 406c544d5317529183a46f7c312bd4f24191a4fbabebea8550a97c083cb5162e
MD5 bf4b6d334c2d95473af6f17d0b28afb3
BLAKE2b-256 5d5ce0c1f324f84628b7990d71f22ae4f176a2f2e185bac23877407d305e2029

See more details on using hashes here.

File details

Details for the file cbmpy-0.7.4.win-amd64.exe.

File metadata

File hashes

Hashes for cbmpy-0.7.4.win-amd64.exe
Algorithm Hash digest
SHA256 18354a05b0d58d8abc3df8de6f5b0778af34f345aff14664e946be08b7337f9d
MD5 0abe1ad516d6bf7cdeb601662afecf43
BLAKE2b-256 2ab5f30e772196d099e14d8f9fe44eb6807c76010073c2ede5af8718f6db5c74

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page