Skip to main content

FBC reference files for SBML model curation.

Project description

fbc_curation: FROG analysis in Python

FROG logo

GitHub Actions CI/CD Status PyPI Version Python Versions License: MIT Zenodo DOI

The project fbc_curation implements the FROG analysis for reproducibility of constraint-based models in Python. FROG can be run

The FROG analysis creates standardized reference files for a given constraint-based computational model. The FROG files can be used in the model curation process for validating model behavior, e.g., when submitting the model to BioModels.

fbc_curation provides two implementations of FROG using

  • cobrapy — Constraint-Based Reconstruction and Analysis in Python
  • cameo — Computer Aided Metabolic Engineering and Optimization

For more information see the following resources:

If you have any questions or issues please open an issue.

How to cite

If you use fbc_curation or runfrog please cite us via

Zenodo DOI

Installation

fbc_curation is available from PyPI and can be installed via:

pip install fbc-curation

Run FROG

Command line tool

After installation, FROG analysis can be performed using the runfrog command line tool:

$ runfrog

──────────────────────────────────────────────────────────────────────────────────
🐸 FBC CURATION FROG ANALYSIS 🐸
Version 0.3.1 (https://github.com/matthiaskoenig/fbc_curation)
Citation https://doi.org/10.5281/zenodo.3708271
──────────────────────────────────────────────────────────────────────────────────
Required argument '--input' missing
Usage: runfrog [options]

Options:
  -h, --help            show this help message and exit
  -i INPUT_PATH, --input=INPUT_PATH
                        (required) path to COMBINE archive (OMEX) with SBML
                        model or an SBML model
  -o OUTPUT_PATH, --output=OUTPUT_PATH
                        (required) omex output path to write FROG
──────────────────────────────────────────────────────────────────────────────────

Website

FROG can be easily executed via the website https://runfrog.de.

REST API

FROG can be executed via the REST API https://runfrog.de/docs.

Python

To run FROG programmatically via Python use the run_frog function:

from fbc_curation.worker import run_frog

run_frog(model_path, omex_path)

Here is a complete example with comparison of the FROG results:

"""FROG example using `fbc_curation`."""
from pathlib import Path

from fbc_curation.compare import FrogComparison
from fbc_curation.worker import run_frog


def create_frog(model_path: Path, omex_path: Path) -> None:
    """Create FROG report and write OMEX for given model."""

    # create FROG and write to COMBINE archive
    run_frog(
        source_path=model_path,
        omex_path=omex_path,
    )

    # compare FROG results in created COMBINE archive
    model_reports = FrogComparison.read_reports_from_omex(omex_path=omex_path)
    for _, reports in model_reports.items():
        FrogComparison.compare_reports(reports=reports)


if __name__ == "__main__":
    base_path = Path(".")
    create_frog(
        model_path=base_path / "e_coli_core.xml",
        omex_path=base_path / "e_coli_core_FROG.omex",
    )

Typical output of a FROG analysis is shown below:

runfrog -i e_coli_core.xml -o e_coli_core.omex

───────────────────────────────────────────────────────────────────────────────────────
🐸 FBC CURATION FROG ANALYSIS 🐸
Version 0.2.3 (https://github.com/matthiaskoenig/fbc_curation)
Citation https://doi.org/10.5281/zenodo.3708271
───────────────────────────────────────────────────────────────────────────────────────
INFO     Loading 'e_coli_core.xml'                                         worker.py:70
WARNING  Omex path 'e_coli_core.xml' is not a zip archive.                  omex.py:500
───────────────────────────────── FROG CuratorCobrapy ────────────────────────────────
INFO     * metadata                                                      curator.py:107
INFO     * objectives                                                    curator.py:110
INFO     * fva                                                           curator.py:113
INFO     * reactiondeletions                                             curator.py:116
INFO     * genedeletions                                                 curator.py:119
INFO     FROG created in '0.977' [s]                                      worker.py:178
────────────────────────────────── FROG CuratorCameo ─────────────────────────────────
INFO     * metadata                                                      curator.py:107
INFO     * objectives                                                    curator.py:110
INFO     * fva                                                           curator.py:113
INFO     * reactiondeletions                                             curator.py:116
INFO     * genedeletions                                                 curator.py:119
INFO     FROG created in '1.219' [s]                                      worker.py:178
───────────────────────────────────── Write OMEX ─────────────────────────────────────
WARNING  Existing omex is overwritten: 'e_coli_core.omex'                   omex.py:680
INFO     Reports in omex:                                                 compare.py:60
         {'./e_coli_core.xml': ['cobrapy', 'cobrapy_tsv', 'cameo',
         'cameo_tsv']}
────────────────────────────── Comparison of FROGReports ─────────────────────────────
--- objective ---
             cobrapy  cobrapy_tsv  cameo  cameo_tsv
cobrapy            1            1      1          1
cobrapy_tsv        1            1      1          1
cameo              1            1      1          1
cameo_tsv          1            1      1          1
--- fva ---
             cobrapy  cobrapy_tsv  cameo  cameo_tsv
cobrapy            1            1      1          1
cobrapy_tsv        1            1      1          1
cameo              1            1      1          1
cameo_tsv          1            1      1          1
--- reaction_deletion ---
             cobrapy  cobrapy_tsv  cameo  cameo_tsv
cobrapy            1            1      1          1
cobrapy_tsv        1            1      1          1
cameo              1            1      1          1
cameo_tsv          1            1      1          1
--- gene_deletion ---
             cobrapy  cobrapy_tsv  cameo  cameo_tsv
cobrapy            1            1      1          1
cobrapy_tsv        1            1      1          1
cameo              1            1      1          1
cameo_tsv          1            1      1          1
───────────────────────────────────────────────────────────────────────────────────────
Equal: True
───────────────────────────────────────────────────────────────────────────────────────

License

Funding

Matthias König (MK) was supported by the Federal Ministry of Education and Research (BMBF, Germany) within the research network Systems Medicine of the Liver (LiSyM, grant number 031L0054). MK is supported by the Federal Ministry of Education and Research (BMBF, Germany) within ATLAS by grant number 031L0304B and by the German Research Foundation (DFG) within the Research Unit Program FOR 5151 QuaLiPerF (Quantifying Liver Perfusion-Function Relationship in Complex Resection - A Systems Medicine Approach) by grant number 436883643 and by grant number 465194077 (Priority Programme SPP 2311, Subproject SimLivA).

© 2020–2025 Matthias König

Project details


Download files

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

Source Distribution

fbc_curation-0.3.2.tar.gz (8.4 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fbc_curation-0.3.2-py3-none-any.whl (4.1 MB view details)

Uploaded Python 3

File details

Details for the file fbc_curation-0.3.2.tar.gz.

File metadata

  • Download URL: fbc_curation-0.3.2.tar.gz
  • Upload date:
  • Size: 8.4 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for fbc_curation-0.3.2.tar.gz
Algorithm Hash digest
SHA256 70c0ff9d1a299f800161e87265d57b4fe97380c2575049930f9921f46b376d40
MD5 d44e39913cf2e8f35c20c9f82aa52bb8
BLAKE2b-256 1db9a2dbd22d0403ca20d5832f7698b057e2898a3c9883402afb06155b79687c

See more details on using hashes here.

Provenance

The following attestation bundles were made for fbc_curation-0.3.2.tar.gz:

Publisher: main.yml on matthiaskoenig/fbc_curation

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fbc_curation-0.3.2-py3-none-any.whl.

File metadata

  • Download URL: fbc_curation-0.3.2-py3-none-any.whl
  • Upload date:
  • Size: 4.1 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for fbc_curation-0.3.2-py3-none-any.whl
Algorithm Hash digest
SHA256 0cf1172046d2bee93a6e6121ef3e219e09f14471cf27ecdc5f3230a3b49c1233
MD5 de5bdb1441a37bea599a320da498898b
BLAKE2b-256 12bd1a34a35c9386528e4fef7d3f8d9734c7083c39facd6400e3c4cb4c3bae1f

See more details on using hashes here.

Provenance

The following attestation bundles were made for fbc_curation-0.3.2-py3-none-any.whl:

Publisher: main.yml on matthiaskoenig/fbc_curation

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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