Gizmos for ontology development
Project description
gizmos
Utilities for ontology development
Testing
For development, we recommend installing and testing using:
python3 -m pip install -e .
python3 setup.py pytest
There are some dependencies that are test-only (e.g., will not be listed in the project requirements). If you try and run pytest
alone, it may fail due to missing dependencies.
Modules
gizmos.tree
The tree
module produces a CGI tree browser for a given term contained in a SQL database. The SQL database should be created from OWL using rdftab to ensure it is in the right format.
Usage in the command line:
python3 -m gizmos.tree [path-to-database] [term] > [output-html]
The term
should be a CURIE with a prefix already defined in the prefix
table of the database. If the term
is not included, the output will show a tree starting at owl:Thing
.
The links in the tree return query strings with the ID of the term:
?id=FOO:123
If you provide the -i
/--include-db
flag, you will also get the db
parameter in the query string. The value of this parameter is the base name of the database file.
?db=bar&id=FOO:123
This can be useful when writing scripts that return trees from different databases.
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
Hashes for ontodev_gizmos-0.1.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 04054bf94fc8d7f7fb7eda920ef3c8d001d04408f6779962656a8c3eed739c59 |
|
MD5 | 35f1abbe30e2ea57de0d25ae08ecd330 |
|
BLAKE2b-256 | 157526fedf26ed8f5fdae15d8a5748bccd1237d32a5e74b33c1dc3daee310028 |