A parser for SBML
Project description
rust_sbml
Parser for the Systems Biology Markup Language (SBML):
Getting started
Rust
Add it to your Cargo.toml with no default features to avoid all PyO3 nuisances.
[dependencies.rust_sbml]
version = "0.3.0"
default_features=false
For example,
use rust_sbml::Model;
let example=r#"<?xml version="1.0" encoding="UTF-8"?>
<sbml xmlns="http://www.sbml.org/sbml/level3/version2/core" level="3" version="2">
<model timeUnits="second" extentUnits="mole" substanceUnits="mole">
</model>
</sbml>"#;
let result = Model::parse(example);
println!("{:?}", result.unwrap());
See write_to_file.rs for an example on serializing to a file.
Python
It has only been tested on Linux.
Using pip
pip install rust_sbml
From source
Clone the repository.
git clone https://github.com/carrascomj/rust_sbml.git
You need maturin for building it.
python -m pip install maturin
- Build locally
maturin build --release pip install .
- Build on virtualenv (no pip install required)
# --release can be omitted to speed up compilation time maturin develop --release
Having it installed, you can use it as a normal Python package.
from rust_sbml import Model
sbml = Model("examples/EcoliCore.xml")
reaction = sbml.getListOfReactions()[0]
print(reaction.getListOfReactants())
Milestones
-
getListOfSpecies()
(id, name) -
getListOfCompartments()
(id, name) -
getListOfReactions()
(id, name)-
.getListOfReactants()
(id, name) - .
getListOfProducts()
(id, name)
-
- Capable of retrieving FBC bounds.
- Published to pypi
- Kinetic Laws.
- Metadata.
- Test suite with python calls.
- Test suite with libsbml comparison trough cobrapy.
License
Licensed under either of
- Apache License, Version 2.0, (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)
at your option.
Contribution
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.
README.md is automatically generated on CI using cargo-readme. Please, modify README.tpl or lib.rs instead (check the github worflow for more details).
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Hashes for rust_sbml-0.5.3-cp39-cp39-manylinux2010_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 45c9f74146aec0035b25fa84d0dcd9332257b4f910aba560cdf99f11cc740c45 |
|
MD5 | b4a6646399c3220293b5a31de8b344e1 |
|
BLAKE2b-256 | 644cea6546970350fdfee2ae9569621a63d923d776a29518fd0d6abd75176841 |
Hashes for rust_sbml-0.5.3-cp38-cp38-manylinux2010_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5a6fd40128ba948f7c9d514e027ed066031e261b50769399e4ef357e64dd1f42 |
|
MD5 | 88beb138f3095e2a8735cd326724c576 |
|
BLAKE2b-256 | 3f5f0875a07c87c2f942dea3213b76643355119ab7eaedccc972cdd6975b41a2 |
Hashes for rust_sbml-0.5.3-cp37-cp37m-manylinux2010_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1b96ee1f6ca10e081f3f4ab4231a051ad38de8b0f6ff718c527a40b1633437b6 |
|
MD5 | 8a48854129d855306183ccab9ab85178 |
|
BLAKE2b-256 | 6fdd445e8e4707a40e9cdecbad423d3f9d79d32be4c2612d92bd956eebfa65cb |
Hashes for rust_sbml-0.5.3-cp36-cp36m-manylinux2010_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c940358682588618fee5bf98a66af71935a6dedec9ece70e81cee8000dd92ee3 |
|
MD5 | 01550e61106dd4d70859f4061edcfb9b |
|
BLAKE2b-256 | 6f313b7b8a439af50860c3a171145b86b76377117f312901a58c3fd00925d7d7 |