Skip to main content

momapy_kb

License A library to integrate SBGN and CellDesigner maps into graph databases and logic programs. This library relies on momapy for handling maps.

Features

  • Multiple Labelled Property Graph backends: save maps in a Neo4j, FalkorDB or FalkorDBLite (embedded) database
  • A Clingo/ASP backend: convert maps to logic programming facts
  • Collection management: organize maps into named collections
  • Layout element queries: query model elements and retrieve corresponding layout elements for rendering

Installation

pip install momapy-kb[neo4j]        # Neo4j support
pip install momapy-kb[falkordb]     # FalkorDB support
pip install momapy-kb[falkordblite] # FalkorDBLite (embedded) support
pip install momapy-kb[clingo]       # Clingo/ASP support
pip install momapy-kb[all]          # Everything

Quick example

import momapy_kb.lpg.session
import momapy_kb.lpg.backends.neo4j

backend = momapy_kb.lpg.backends.neo4j.Neo4jBackend(
    hostname="localhost",
    username="neo4j",
    password="password",
)

with momapy_kb.lpg.session.Session(backend) as session:
    # save a CellDesigner map to the Neo4j database
    session.save_from_file("model.xml", integration_mode="hash")

    # query model elements, return them as momapy objects
    results = session.execute_query_as_objects(
        "MATCH (n:Protein) RETURN n"
    )

    # query model elements, return corresponding layout elements
    layout_results = session.execute_query_as_layout_elements(
        "MATCH (n:Reaction) RETURN n"
    )

Documentation

Full documentation is available at https://adrienrougny.github.io/momapy_kb/.

Download files

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

Source Distribution

momapy_kb-0.5.0.tar.gz (285.7 kB view details)

Uploaded Source

Built Distribution

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

momapy_kb-0.5.0-py3-none-any.whl (30.9 kB view details)

Uploaded Python 3

File details

Details for the file momapy_kb-0.5.0.tar.gz.

File metadata

  • Download URL: momapy_kb-0.5.0.tar.gz
  • Upload date:
  • Size: 285.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for momapy_kb-0.5.0.tar.gz
Algorithm Hash digest
SHA256 3f5977ebc5d05b19c0e6706b23830bcdf6c8f3a0dc7fd7a621df0cb458428e4f
MD5 dc7dc73b8444d09f13fac92da6fc2789
BLAKE2b-256 9b23b03c4ebe98b1b39df70513e90a06dd6d4dee1ea56b082f0edd92d8f07e56

See more details on using hashes here.

Provenance

The following attestation bundles were made for momapy_kb-0.5.0.tar.gz:

Publisher: release.yml on adrienrougny/momapy_kb

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

File details

Details for the file momapy_kb-0.5.0-py3-none-any.whl.

File metadata

  • Download URL: momapy_kb-0.5.0-py3-none-any.whl
  • Upload date:
  • Size: 30.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for momapy_kb-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a2ab6c26866c7367335e106df427736d68d93f0297f82ca3b0c96f452781bc90
MD5 886e8f42af85b2eb8c8ceae591614de2
BLAKE2b-256 8374644f85cbb5e5c29b2e9baec9b95886434424698125623814dc8a7a3150fb

See more details on using hashes here.

Provenance

The following attestation bundles were made for momapy_kb-0.5.0-py3-none-any.whl:

Publisher: release.yml on adrienrougny/momapy_kb

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

Release history Release notifications | RSS feed

This release

0.5.0 This release

2 files

0.4.1

2 files

0.4.0

2 files

0.3.0

2 files

0.2.2

2 files

0.2.1

2 files

0.2.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page