A library for working with molecular maps
Project description
momapy
momapy is a library for working with molecular maps. It currently supports SBGN and CellDesigner maps. Its key feature is its definition of a map, that is formed of two entities: a model, that describes what concepts are represented, and a layout, that describes how these concepts are represented. This definition is borrowed from SBML and its extensions layout+render, that allow users to add a layout to an SBML model. momapy aims at extending this definition to SBGN and CellDesigner maps.
Features of momapy include the following:
- support for SBGN PD and AF maps (read/write SBGN-ML with annotations, rendering information, and notes) and CellDesigner (read only, with annotations)
- decomposition of a map object into:
- a model object;
- a layout object;
- a mapping from layout element objects to model element objects.
- map, model, layout and mapping objects comparison; fast object in set checking
- rendering of maps to images (SVG, PDF, JPEG, PNG, WebP) and other surfaces (e.g. GLFW window)
- support for styling and CSS like stylesheets (including effects such as shadows)
- automatic geometry and anchors (for arcs, shape borders)
- local positioning (e.g. right of shape, fit set of shapes)
- easy extension with new model and layout element types
Installation
momapy is available as a Python package and can be installed with pip as follows:
pip install momapy
Usage
Typical usage of momapy includes reading a map and exploring its model:
import momapy.sbgn.io.sbgnml
from momapy.io import read
map_ = read("my_map.sbgn").obj
for process in map_.model.processes:
print(process)
Or rendering its layout:
import momapy.rendering.skia
from momapy.rendering.core import render_map
render_map(map_, "my_file.pdf", format_="pdf", renderer="skia")
Documentation
The documentation for momapy can be found here.
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 Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file momapy-0.1.3.tar.gz.
File metadata
- Download URL: momapy-0.1.3.tar.gz
- Upload date:
- Size: 133.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9328f810021fe5f26df777b92940deed25493b339c2b8cf66ca804e1d8dd8bc1
|
|
| MD5 |
3313ab5d45b1a0d5e6b42b13a0e60cfb
|
|
| BLAKE2b-256 |
a30f5e00ce7c2a6199c9d6fab94304432b738bc31e73118fc98878dfd3237d89
|
Provenance
The following attestation bundles were made for momapy-0.1.3.tar.gz:
Publisher:
release.yml on adrienrougny/momapy
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
momapy-0.1.3.tar.gz -
Subject digest:
9328f810021fe5f26df777b92940deed25493b339c2b8cf66ca804e1d8dd8bc1 - Sigstore transparency entry: 444058335
- Sigstore integration time:
-
Permalink:
adrienrougny/momapy@c00cd9092ce555587a1e91f068365c1657102a79 -
Branch / Tag:
refs/tags/v0.1.3 - Owner: https://github.com/adrienrougny
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@c00cd9092ce555587a1e91f068365c1657102a79 -
Trigger Event:
push
-
Statement type:
File details
Details for the file momapy-0.1.3-py3-none-any.whl.
File metadata
- Download URL: momapy-0.1.3-py3-none-any.whl
- Upload date:
- Size: 149.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
76fbe23005ae462989315d11071f6305286c05dea44d6dbd2930f6bcce8a52ce
|
|
| MD5 |
87c86ab968620728242c0fdaa449762c
|
|
| BLAKE2b-256 |
b033e23cd68e78e0b9a1c924736af155277edc573d78f79d22ef9d482bdd08ae
|
Provenance
The following attestation bundles were made for momapy-0.1.3-py3-none-any.whl:
Publisher:
release.yml on adrienrougny/momapy
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
momapy-0.1.3-py3-none-any.whl -
Subject digest:
76fbe23005ae462989315d11071f6305286c05dea44d6dbd2930f6bcce8a52ce - Sigstore transparency entry: 444058341
- Sigstore integration time:
-
Permalink:
adrienrougny/momapy@c00cd9092ce555587a1e91f068365c1657102a79 -
Branch / Tag:
refs/tags/v0.1.3 - Owner: https://github.com/adrienrougny
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@c00cd9092ce555587a1e91f068365c1657102a79 -
Trigger Event:
push
-
Statement type: