Package: bioontologies
BioontologiesTools for biomedical ontologies.💪 Getting StartedThis package lets you get OBO Graphs from ontologies based on their OWL
files, OBO files, orBioregistryprefixes. Internally,
it usesROBOTto convert from these formats
toOBO Graph JSON.importbioontologies# Get an ontology and convert to OBO Graph object via an OWL IRIowl_iri="http://purl.obolibrary.org/obo/go.owl"parse_results=bioontologies.convert_to_obograph(owl_iri)# Get an ontology and convert to OBO Graph object via an OBO IRIobo_iri="http://purl.obolibrary.org/obo/go.obo"parse_results=bioontologies.convert_to_obograph(obo_iri)# Get an ontology by its Bioregistry prefixparse_results=bioontologies.get_obograph_by_prefix("go")go_graph_document=parse_results.graph_document🚀 InstallationThe most recent release can be installed fromPyPIwith:$pipinstallbioontologiesThe most recent code and data can be installed directly from GitHub with:$pipinstallgit+https://github.com/biopragmatics/bioontologies.git👐 ContributingContributions, whether filing an issue, making a pull request, or forking, are appreciated. SeeCONTRIBUTING.mdfor more information on getting involved.👋 Attribution⚖️ LicenseThe code in this package is licensed under the MIT License.🎁 SupportThe Bioregistry was developed by theINDRA Lab, a part of theLaboratory of Systems Pharmacologyand theHarvard Program in Therapeutic Science (HiTS)atHarvard Medical School.💰 FundingThe development of this package is funded by the DARPA Young Faculty Award W911NF2010255 (PI: Benjamin M. Gyori).🍪 CookiecutterThis package was created with@audreyfeldroy'scookiecutterpackage using@cthoyt'scookiecutter-snekpacktemplate.🛠️ For DevelopersSee developer instructionsThe final section of the README is for if you want to get involved by making a code contribution.Development InstallationTo install in development mode, use the following:$gitclonegit+https://github.com/biopragmatics/bioontologies.git
$cdbioontologies
$pipinstall-e.🥼 TestingAfter cloning the repository and installingtoxwithpip install tox, the unit tests in thetests/folder can be
run reproducibly with:$toxAdditionally, these tests are automatically re-run with each commit in aGitHub Action.📖 Building the DocumentationThe documentation can be built locally using the following:$gitclonegit+https://github.com/biopragmatics/bioontologies.git
$cdbioontologies
$tox-edocs
$opendocs/build/html/index.htmlThe documentation automatically installs the package as well as thedocsextra specified in thesetup.cfg.sphinxplugins
liketexextcan be added there. Additionally, they need to be added to theextensionslist indocs/source/conf.py.📦 Making a ReleaseAfter installing the package in development mode and installingtoxwithpip install tox, the commands for making a new release are contained within thefinishenvironment
intox.ini. Run the following from the shell:$tox-efinishThis script does the following:UsesBump2Versionto switch the version number in thesetup.cfg,src/bioontologies/version.py, anddocs/source/conf.pyto not have the-devsuffixPackages the code in both a tar archive and a wheel usingbuildUploads to PyPI usingtwine. Be sure to have a.pypircfile configured to avoid the need for manual input at this
stepPush to GitHub. You'll need to make a release going with the commit where the version was bumped.Bump the version to the next patch. If you made big changes and want to bump the version by minor, you can
usetox -e bumpversion minorafter.