pyobo 0.12.0.dev0__tar.gz → 0.12.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/PKG-INFO +76 -118
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/README.md +69 -103
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/pyproject.toml +57 -22
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/.DS_Store +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/__init__.py +1 -3
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/api/alts.py +2 -1
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/api/combine.py +2 -1
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/api/edges.py +1 -1
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/api/hierarchy.py +109 -15
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/api/names.py +10 -9
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/api/properties.py +9 -13
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/api/utils.py +5 -4
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/api/xrefs.py +23 -17
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/cli/cli.py +36 -5
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/cli/database.py +30 -2
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/cli/database_utils.py +7 -13
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/constants.py +0 -1
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/getters.py +26 -79
- pyobo-0.12.1/src/pyobo/gilda_utils.py +74 -0
- pyobo-0.12.1/src/pyobo/identifier_utils/__init__.py +33 -0
- pyobo-0.12.0.dev0/src/pyobo/identifier_utils.py → pyobo-0.12.1/src/pyobo/identifier_utils/api.py +40 -38
- pyobo-0.12.1/src/pyobo/identifier_utils/preprocessing.json +873 -0
- pyobo-0.12.1/src/pyobo/identifier_utils/preprocessing.py +27 -0
- pyobo-0.12.1/src/pyobo/identifier_utils/relations/__init__.py +8 -0
- pyobo-0.12.1/src/pyobo/identifier_utils/relations/api.py +162 -0
- pyobo-0.12.1/src/pyobo/identifier_utils/relations/data.json +5824 -0
- pyobo-0.12.1/src/pyobo/identifier_utils/relations/data_owl.json +57 -0
- pyobo-0.12.1/src/pyobo/identifier_utils/relations/data_rdf.json +1 -0
- pyobo-0.12.1/src/pyobo/identifier_utils/relations/data_rdfs.json +7 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/ner/__init__.py +2 -0
- pyobo-0.12.1/src/pyobo/ner/normalizer.py +33 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/obographs.py +21 -22
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/reader.py +13 -16
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/__init__.py +6 -2
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/bigg/bigg_metabolite.py +74 -19
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/bigg/bigg_reaction.py +7 -1
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/cgnc.py +9 -1
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/chembl/chembl_target.py +16 -8
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/clinicaltrials.py +4 -2
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/drugcentral.py +13 -4
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/flybase.py +5 -5
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/msigdb.py +10 -1
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/nlm/utils.py +13 -2
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/omim_ps.py +4 -4
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/pharmgkb/pharmgkb_chemical.py +5 -1
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/pharmgkb/pharmgkb_gene.py +1 -1
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/ror.py +10 -3
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/signor/signor_complexes.py +2 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/slm.py +5 -4
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/struct/functional/ontology.py +3 -1
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/struct/reference.py +8 -8
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/struct/struct.py +128 -82
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/utils/cache.py +3 -4
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/utils/io.py +38 -14
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/utils/path.py +16 -19
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/version.py +1 -1
- pyobo-0.12.0.dev0/src/pyobo/_reference_tmp.py +0 -35
- pyobo-0.12.0.dev0/src/pyobo/aws.py +0 -163
- pyobo-0.12.0.dev0/src/pyobo/cli/aws.py +0 -47
- pyobo-0.12.0.dev0/src/pyobo/gilda_utils.py +0 -151
- pyobo-0.12.0.dev0/src/pyobo/ner/normalizer.py +0 -226
- pyobo-0.12.0.dev0/src/pyobo/registries/__init__.py +0 -16
- pyobo-0.12.0.dev0/src/pyobo/registries/metaregistry.json +0 -626
- pyobo-0.12.0.dev0/src/pyobo/registries/metaregistry.py +0 -169
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/LICENSE +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/__main__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/api/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/api/metadata.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/api/relations.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/api/species.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/api/typedefs.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/cli/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/cli/lookup.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/cli/utils.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/mocks.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/ner/api.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/plugins.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/py.typed +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/reader_utils.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/resource_utils.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/resources/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/resources/goc.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/resources/goc.tsv +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/resources/ncbitaxon.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/resources/ncbitaxon.tsv.gz +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/resources/ro.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/resources/ro.tsv +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/resources/so.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/resources/so.tsv +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/README.md +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/agrovoc.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/antibodyregistry.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/bigg/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/bigg/bigg_compartment.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/bigg/bigg_model.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/biogrid.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/ccle.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/chebi.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/chembl/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/chembl/chembl_compound.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/civic_gene.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/complexportal.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/conso.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/cpt.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/credit.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/cvx.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/depmap.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/dictybase_gene.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/drugbank/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/drugbank/drugbank.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/drugbank/drugbank_salt.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/expasy.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/famplex.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/gard.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/geonames/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/geonames/features.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/geonames/geonames.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/geonames/utils.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/gmt_utils.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/go.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/gtdb.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/gwascentral/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/gwascentral/gwascentral_phenotype.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/gwascentral/gwascentral_study.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/hgnc/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/hgnc/hgnc.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/hgnc/hgncgenefamily.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/icd/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/icd/icd10.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/icd/icd11.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/icd/icd_utils.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/interpro.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/itis.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/kegg/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/kegg/api.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/kegg/genes.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/kegg/genome.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/kegg/pathway.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/mesh.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/mgi.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/mirbase/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/mirbase/mirbase.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/mirbase/mirbase_constants.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/mirbase/mirbase_family.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/mirbase/mirbase_mature.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/ncbi/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/ncbi/ncbi_gc.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/ncbi/ncbigene.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/nih_reporter.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/nlm/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/nlm/nlm_catalog.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/nlm/nlm_publisher.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/npass.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/pathbank.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/pfam/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/pfam/pfam.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/pfam/pfam_clan.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/pharmgkb/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/pharmgkb/pharmgkb_disease.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/pharmgkb/pharmgkb_pathway.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/pharmgkb/pharmgkb_variant.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/pharmgkb/utils.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/pid.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/pombase.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/pubchem.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/reactome.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/rgd.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/rhea.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/selventa/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/selventa/schem.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/selventa/scomp.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/selventa/sdis.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/selventa/sfam.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/sgd.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/signor/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/signor/download.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/umls/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/umls/__main__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/umls/get_synonym_types.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/umls/sty.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/umls/synonym_types.tsv +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/umls/umls.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/unimod.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/uniprot/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/uniprot/uniprot.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/uniprot/uniprot_ptm.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/utils.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/wikipathways.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/sources/zfin.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/ssg/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/ssg/base.html +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/ssg/index.html +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/ssg/term.html +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/ssg/typedef.html +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/struct/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/struct/functional/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/struct/functional/dsl.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/struct/functional/macros.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/struct/functional/obo_to_functional.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/struct/functional/utils.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/struct/struct_utils.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/struct/typedef.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/struct/utils.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/struct/vocabulary.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/utils/__init__.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/utils/iter.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/utils/misc.py +0 -0
- {pyobo-0.12.0.dev0 → pyobo-0.12.1}/src/pyobo/utils/ndex_utils.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: pyobo
|
|
3
|
-
Version: 0.12.
|
|
3
|
+
Version: 0.12.1
|
|
4
4
|
Summary: A python package for handling and generating OBO
|
|
5
5
|
Keywords: snekpack,cookiecutter,ontologies,biomedical ontologies,life sciences,natural sciences,bioinformatics,cheminformatics,Open Biomedical Ontologies,OBO
|
|
6
6
|
Author: Charles Tapley Hoyt
|
|
@@ -37,15 +37,15 @@ Requires-Dist: humanize
|
|
|
37
37
|
Requires-Dist: tabulate
|
|
38
38
|
Requires-Dist: cachier
|
|
39
39
|
Requires-Dist: pystow>=0.7.0
|
|
40
|
-
Requires-Dist: bioversions>=0.
|
|
41
|
-
Requires-Dist: bioregistry>=0.12.
|
|
42
|
-
Requires-Dist: bioontologies>=0.
|
|
43
|
-
Requires-Dist: ssslm>=0.0.
|
|
40
|
+
Requires-Dist: bioversions>=0.8.0
|
|
41
|
+
Requires-Dist: bioregistry>=0.12.7
|
|
42
|
+
Requires-Dist: bioontologies>=0.7.1
|
|
43
|
+
Requires-Dist: ssslm>=0.0.13
|
|
44
44
|
Requires-Dist: zenodo-client>=0.3.6
|
|
45
|
-
Requires-Dist: class-resolver
|
|
45
|
+
Requires-Dist: class-resolver>=0.6.0
|
|
46
46
|
Requires-Dist: psycopg2-binary
|
|
47
47
|
Requires-Dist: pydantic>=2.0
|
|
48
|
-
Requires-Dist: curies>=0.10.
|
|
48
|
+
Requires-Dist: curies>=0.10.13
|
|
49
49
|
Requires-Dist: python-dateutil
|
|
50
50
|
Requires-Dist: networkx>=3.4
|
|
51
51
|
Requires-Dist: drugbank-downloader
|
|
@@ -55,14 +55,8 @@ Requires-Dist: clinicaltrials-downloader>=0.0.2
|
|
|
55
55
|
Requires-Dist: nih-reporter-downloader>=0.0.1
|
|
56
56
|
Requires-Dist: typing-extensions
|
|
57
57
|
Requires-Dist: rdflib
|
|
58
|
-
Requires-Dist: sphinx>=8 ; extra == 'docs'
|
|
59
|
-
Requires-Dist: sphinx-rtd-theme>=3.0 ; extra == 'docs'
|
|
60
|
-
Requires-Dist: sphinx-click ; extra == 'docs'
|
|
61
|
-
Requires-Dist: sphinx-automodapi ; extra == 'docs'
|
|
62
58
|
Requires-Dist: ssslm[gilda] ; extra == 'gilda'
|
|
63
59
|
Requires-Dist: ssslm[gilda-slim] ; extra == 'gilda-slim'
|
|
64
|
-
Requires-Dist: pytest ; extra == 'tests'
|
|
65
|
-
Requires-Dist: coverage[toml] ; extra == 'tests'
|
|
66
60
|
Maintainer: Charles Tapley Hoyt
|
|
67
61
|
Maintainer-email: Charles Tapley Hoyt <cthoyt@gmail.com>
|
|
68
62
|
Requires-Python: >=3.10
|
|
@@ -71,10 +65,8 @@ Project-URL: Documentation, https://pyobo.readthedocs.io
|
|
|
71
65
|
Project-URL: Funding, https://github.com/sponsors/cthoyt
|
|
72
66
|
Project-URL: Homepage, https://github.com/biopragmatics/pyobo
|
|
73
67
|
Project-URL: Repository, https://github.com/biopragmatics/pyobo.git
|
|
74
|
-
Provides-Extra: docs
|
|
75
68
|
Provides-Extra: gilda
|
|
76
69
|
Provides-Extra: gilda-slim
|
|
77
|
-
Provides-Extra: tests
|
|
78
70
|
Description-Content-Type: text/markdown
|
|
79
71
|
|
|
80
72
|
<!--
|
|
@@ -120,14 +112,7 @@ identifiers. It also means all identifiers are strings, no exceptions.
|
|
|
120
112
|
|
|
121
113
|
Note! The first time you run these, they have to download and cache all
|
|
122
114
|
resources. We're not in the business of redistributing data, so all scripts
|
|
123
|
-
should be completely reproducible.
|
|
124
|
-
hosting/downloading pre-compiled versions in `pyobo.aws` if you don't have time
|
|
125
|
-
for that.
|
|
126
|
-
|
|
127
|
-
Note! PyOBO can perform grounding in a limited number of cases, but it is _not_
|
|
128
|
-
a general solution for named entity recognition (NER) or grounding. It's
|
|
129
|
-
suggested to check `Gilda <https://github.com/indralab/gilda>`\_ for a
|
|
130
|
-
no-nonsense solution.
|
|
115
|
+
should be completely reproducible.
|
|
131
116
|
|
|
132
117
|
### Mapping Identifiers and CURIEs
|
|
133
118
|
|
|
@@ -136,19 +121,11 @@ Get mapping of ChEBI identifiers to names:
|
|
|
136
121
|
```python
|
|
137
122
|
import pyobo
|
|
138
123
|
|
|
139
|
-
chebi_id_to_name = pyobo.get_id_name_mapping(
|
|
124
|
+
chebi_id_to_name = pyobo.get_id_name_mapping("chebi")
|
|
125
|
+
assert "fluazifop-P-butyl" == chebi_id_to_name["132964"]
|
|
140
126
|
|
|
141
|
-
|
|
142
|
-
assert
|
|
143
|
-
```
|
|
144
|
-
|
|
145
|
-
Or, you don't have time for two lines:
|
|
146
|
-
|
|
147
|
-
```python
|
|
148
|
-
import pyobo
|
|
149
|
-
|
|
150
|
-
name = pyobo.get_name('chebi', '132964')
|
|
151
|
-
assert name == 'fluazifop-P-butyl'
|
|
127
|
+
# or more directly
|
|
128
|
+
assert "fluazifop-P-butyl" == pyobo.get_name("chebi", "132964")
|
|
152
129
|
```
|
|
153
130
|
|
|
154
131
|
Get reverse mapping of ChEBI names to identifiers:
|
|
@@ -156,10 +133,8 @@ Get reverse mapping of ChEBI names to identifiers:
|
|
|
156
133
|
```python
|
|
157
134
|
import pyobo
|
|
158
135
|
|
|
159
|
-
chebi_name_to_id = pyobo.get_name_id_mapping(
|
|
160
|
-
|
|
161
|
-
identifier = chebi_name_to_id['fluazifop-P-butyl']
|
|
162
|
-
assert identifier == '132964'
|
|
136
|
+
chebi_name_to_id = pyobo.get_name_id_mapping("chebi")
|
|
137
|
+
assert "132964" == chebi_name_to_id["fluazifop-P-butyl"]
|
|
163
138
|
```
|
|
164
139
|
|
|
165
140
|
Maybe you live in CURIE world and just want to normalize something like
|
|
@@ -168,8 +143,7 @@ Maybe you live in CURIE world and just want to normalize something like
|
|
|
168
143
|
```python
|
|
169
144
|
import pyobo
|
|
170
145
|
|
|
171
|
-
|
|
172
|
-
assert name == 'fluazifop-P-butyl'
|
|
146
|
+
assert "fluazifop-P-butyl" == pyobo.get_name_by_curie("CHEBI:132964")
|
|
173
147
|
```
|
|
174
148
|
|
|
175
149
|
Sometimes you accidentally got an old CURIE. It can be mapped to the more recent
|
|
@@ -181,11 +155,11 @@ from pyobo import Reference
|
|
|
181
155
|
|
|
182
156
|
# Look up DNA-binding transcription factor activity (go:0003700)
|
|
183
157
|
# based on an old id
|
|
184
|
-
primary_curie = pyobo.get_primary_curie(
|
|
185
|
-
assert primary_curie ==
|
|
158
|
+
primary_curie = pyobo.get_primary_curie("go:0001071")
|
|
159
|
+
assert primary_curie == "go:0003700"
|
|
186
160
|
|
|
187
161
|
# If it's already the primary, it just gets returned
|
|
188
|
-
assert Reference.from_curie(
|
|
162
|
+
assert Reference.from_curie("go:0003700") == pyobo.get_primary_curie("go:0003700")
|
|
189
163
|
```
|
|
190
164
|
|
|
191
165
|
### Mapping Species
|
|
@@ -196,11 +170,10 @@ WikiPathway identifiers to species (as NCBI taxonomy identifiers):
|
|
|
196
170
|
```python
|
|
197
171
|
import pyobo
|
|
198
172
|
|
|
199
|
-
wikipathways_id_to_species = pyobo.get_id_species_mapping(
|
|
173
|
+
wikipathways_id_to_species = pyobo.get_id_species_mapping("wikipathways")
|
|
200
174
|
|
|
201
175
|
# Apoptosis (Homo sapiens)
|
|
202
|
-
|
|
203
|
-
assert taxonomy_id == '9606'
|
|
176
|
+
assert "9606" == wikipathways_id_to_species["WP254"]
|
|
204
177
|
```
|
|
205
178
|
|
|
206
179
|
Or, you don't have time for two lines:
|
|
@@ -209,8 +182,8 @@ Or, you don't have time for two lines:
|
|
|
209
182
|
import pyobo
|
|
210
183
|
|
|
211
184
|
# Apoptosis (Homo sapiens)
|
|
212
|
-
taxonomy_id = pyobo.get_species(
|
|
213
|
-
assert taxonomy_id ==
|
|
185
|
+
taxonomy_id = pyobo.get_species("wikipathways", "WP254")
|
|
186
|
+
assert taxonomy_id == "9606"
|
|
214
187
|
```
|
|
215
188
|
|
|
216
189
|
### Grounding
|
|
@@ -222,16 +195,14 @@ it up and its preferred label.
|
|
|
222
195
|
```python
|
|
223
196
|
import pyobo
|
|
224
197
|
|
|
225
|
-
|
|
226
|
-
assert prefix ==
|
|
227
|
-
assert identifier ==
|
|
228
|
-
assert name ==
|
|
198
|
+
reference = pyobo.ground("chebi", "Fusilade II")
|
|
199
|
+
assert reference.prefix == "chebi"
|
|
200
|
+
assert reference.identifier == "132964"
|
|
201
|
+
assert reference.name == "fluazifop-P-butyl"
|
|
229
202
|
|
|
230
203
|
# When failure happens...
|
|
231
|
-
|
|
232
|
-
assert
|
|
233
|
-
assert identifier is None
|
|
234
|
-
assert name is None
|
|
204
|
+
reference = pyobo.ground("chebi", "Definitely not a real name")
|
|
205
|
+
assert reference is None
|
|
235
206
|
```
|
|
236
207
|
|
|
237
208
|
If you're not really sure which namespace a name might belong to, you can try a
|
|
@@ -242,10 +213,10 @@ false positives in case of conflicts):
|
|
|
242
213
|
import pyobo
|
|
243
214
|
|
|
244
215
|
# looking for phenotypes/pathways
|
|
245
|
-
|
|
246
|
-
assert prefix ==
|
|
247
|
-
assert identifier ==
|
|
248
|
-
assert name ==
|
|
216
|
+
reference = pyobo.ground(["efo", "go"], "ERAD")
|
|
217
|
+
assert reference.prefix == "go"
|
|
218
|
+
assert reference.identifier == "0030433"
|
|
219
|
+
assert reference.name == "ubiquitin-dependent ERAD pathway"
|
|
249
220
|
```
|
|
250
221
|
|
|
251
222
|
### Cross-referencing
|
|
@@ -255,10 +226,10 @@ Get xrefs from ChEBI to PubChem:
|
|
|
255
226
|
```python
|
|
256
227
|
import pyobo
|
|
257
228
|
|
|
258
|
-
chebi_id_to_pubchem_compound_id = pyobo.get_filtered_xrefs(
|
|
229
|
+
chebi_id_to_pubchem_compound_id = pyobo.get_filtered_xrefs("chebi", "pubchem.compound")
|
|
259
230
|
|
|
260
|
-
pubchem_compound_id = chebi_id_to_pubchem_compound_id[
|
|
261
|
-
assert pubchem_compound_id ==
|
|
231
|
+
pubchem_compound_id = chebi_id_to_pubchem_compound_id["132964"]
|
|
232
|
+
assert pubchem_compound_id == "3033674"
|
|
262
233
|
```
|
|
263
234
|
|
|
264
235
|
If you don't have time for two lines:
|
|
@@ -266,8 +237,8 @@ If you don't have time for two lines:
|
|
|
266
237
|
```python
|
|
267
238
|
import pyobo
|
|
268
239
|
|
|
269
|
-
pubchem_compound_id = pyobo.get_xref(
|
|
270
|
-
assert pubchem_compound_id ==
|
|
240
|
+
pubchem_compound_id = pyobo.get_xref("chebi", "132964", "pubchem.compound")
|
|
241
|
+
assert pubchem_compound_id == "3033674"
|
|
271
242
|
```
|
|
272
243
|
|
|
273
244
|
Get xrefs from Entrez to HGNC, but they're only available through HGNC, so you
|
|
@@ -276,13 +247,13 @@ need to flip them:
|
|
|
276
247
|
```python
|
|
277
248
|
import pyobo
|
|
278
249
|
|
|
279
|
-
hgnc_id_to_ncbigene_id = pyobo.get_filtered_xrefs(
|
|
250
|
+
hgnc_id_to_ncbigene_id = pyobo.get_filtered_xrefs("hgnc", "ncbigene")
|
|
280
251
|
ncbigene_id_to_hgnc_id = {
|
|
281
252
|
ncbigene_id: hgnc_id
|
|
282
253
|
for hgnc_id, ncbigene_id in hgnc_id_to_ncbigene_id.items()
|
|
283
254
|
}
|
|
284
|
-
mapt_hgnc = ncbigene_id_to_hgnc_id[
|
|
285
|
-
assert mapt_hgnc ==
|
|
255
|
+
mapt_hgnc = ncbigene_id_to_hgnc_id["4137"]
|
|
256
|
+
assert mapt_hgnc == "6893"
|
|
286
257
|
```
|
|
287
258
|
|
|
288
259
|
Since this is a common pattern, there's a keyword argument `flip` that does this
|
|
@@ -291,9 +262,9 @@ for you:
|
|
|
291
262
|
```python
|
|
292
263
|
import pyobo
|
|
293
264
|
|
|
294
|
-
ncbigene_id_to_hgnc_id = pyobo.get_filtered_xrefs(
|
|
295
|
-
mapt_hgnc_id = ncbigene_id_to_hgnc_id[
|
|
296
|
-
assert mapt_hgnc_id ==
|
|
265
|
+
ncbigene_id_to_hgnc_id = pyobo.get_filtered_xrefs("hgnc", "ncbigene", flip=True)
|
|
266
|
+
mapt_hgnc_id = ncbigene_id_to_hgnc_id["4137"]
|
|
267
|
+
assert mapt_hgnc_id == "6893"
|
|
297
268
|
```
|
|
298
269
|
|
|
299
270
|
If you don't have time for two lines (I admit this one is a bit confusing) and
|
|
@@ -302,8 +273,8 @@ need to flip it:
|
|
|
302
273
|
```python
|
|
303
274
|
import pyobo
|
|
304
275
|
|
|
305
|
-
hgnc_id = pyobo.get_xref(
|
|
306
|
-
assert hgnc_id ==
|
|
276
|
+
hgnc_id = pyobo.get_xref("hgnc", "4137", "ncbigene", flip=True)
|
|
277
|
+
assert hgnc_id == "6893"
|
|
307
278
|
```
|
|
308
279
|
|
|
309
280
|
### Properties
|
|
@@ -315,11 +286,11 @@ basis.
|
|
|
315
286
|
import pyobo
|
|
316
287
|
|
|
317
288
|
# I don't make the rules. I wouldn't have chosen this as the key for this property. It could be any string
|
|
318
|
-
chebi_smiles_property =
|
|
319
|
-
chebi_id_to_smiles = pyobo.get_filtered_properties_mapping(
|
|
289
|
+
chebi_smiles_property = "http://purl.obolibrary.org/obo/chebi/smiles"
|
|
290
|
+
chebi_id_to_smiles = pyobo.get_filtered_properties_mapping("chebi", chebi_smiles_property)
|
|
320
291
|
|
|
321
|
-
smiles = chebi_id_to_smiles[
|
|
322
|
-
assert smiles ==
|
|
292
|
+
smiles = chebi_id_to_smiles["132964"]
|
|
293
|
+
assert smiles == "C1(=CC=C(N=C1)OC2=CC=C(C=C2)O[C@@H](C(OCCCC)=O)C)C(F)(F)F"
|
|
323
294
|
```
|
|
324
295
|
|
|
325
296
|
If you don't have time for two lines:
|
|
@@ -327,8 +298,8 @@ If you don't have time for two lines:
|
|
|
327
298
|
```python
|
|
328
299
|
import pyobo
|
|
329
300
|
|
|
330
|
-
smiles = pyobo.get_property(
|
|
331
|
-
assert smiles ==
|
|
301
|
+
smiles = pyobo.get_property("chebi", "132964", "http://purl.obolibrary.org/obo/chebi/smiles")
|
|
302
|
+
assert smiles == "C1(=CC=C(N=C1)OC2=CC=C(C=C2)O[C@@H](C(OCCCC)=O)C)C(F)(F)F"
|
|
332
303
|
```
|
|
333
304
|
|
|
334
305
|
### Hierarchy
|
|
@@ -340,12 +311,12 @@ import pyobo
|
|
|
340
311
|
from pyobo import Reference
|
|
341
312
|
|
|
342
313
|
# check that go:0008219 ! cell death is an ancestor of go:0006915 ! apoptotic process
|
|
343
|
-
assert Reference.from_curie(
|
|
314
|
+
assert Reference.from_curie("go:0008219") in pyobo.get_ancestors("go", "0006915")
|
|
344
315
|
|
|
345
316
|
# check that go:0070246 ! natural killer cell apoptotic process is a
|
|
346
317
|
# descendant of go:0006915 ! apoptotic process
|
|
347
|
-
apopototic_process_descendants = pyobo.get_descendants(
|
|
348
|
-
assert Reference.from_curie(
|
|
318
|
+
apopototic_process_descendants = pyobo.get_descendants("go", "0006915")
|
|
319
|
+
assert Reference.from_curie("go:0070246") in apopototic_process_descendants
|
|
349
320
|
```
|
|
350
321
|
|
|
351
322
|
Get the sub-hierarchy below a given node:
|
|
@@ -355,11 +326,11 @@ import pyobo
|
|
|
355
326
|
from pyobo import Reference
|
|
356
327
|
|
|
357
328
|
# get the descendant graph of go:0006915 ! apoptotic process
|
|
358
|
-
apopototic_process_subhierarchy = pyobo.get_subhierarchy(
|
|
329
|
+
apopototic_process_subhierarchy = pyobo.get_subhierarchy("go", "0006915")
|
|
359
330
|
|
|
360
331
|
# check that go:0070246 ! natural killer cell apoptotic process is a
|
|
361
332
|
# descendant of go:0006915 ! apoptotic process through the subhierarchy
|
|
362
|
-
assert Reference.from_curie(
|
|
333
|
+
assert Reference.from_curie("go:0070246") in apopototic_process_subhierarchy
|
|
363
334
|
```
|
|
364
335
|
|
|
365
336
|
Get a hierarchy with properties preloaded in the node data dictionaries:
|
|
@@ -368,12 +339,12 @@ Get a hierarchy with properties preloaded in the node data dictionaries:
|
|
|
368
339
|
import pyobo
|
|
369
340
|
from pyobo import Reference
|
|
370
341
|
|
|
371
|
-
prop =
|
|
372
|
-
chebi_hierarchy = pyobo.get_hierarchy(
|
|
342
|
+
prop = "http://purl.obolibrary.org/obo/chebi/smiles"
|
|
343
|
+
chebi_hierarchy = pyobo.get_hierarchy("chebi", properties=[prop])
|
|
373
344
|
|
|
374
|
-
assert Reference.from_curie(
|
|
375
|
-
assert prop in chebi_hierarchy.nodes[
|
|
376
|
-
assert chebi_hierarchy.nodes[
|
|
345
|
+
assert Reference.from_curie("chebi:132964") in chebi_hierarchy
|
|
346
|
+
assert prop in chebi_hierarchy.nodes["chebi:132964"]
|
|
347
|
+
assert chebi_hierarchy.nodes["chebi:132964"][prop] == "C1(=CC=C(N=C1)OC2=CC=C(C=C2)O[C@@H](C(OCCCC)=O)C)C(F)(F)F"
|
|
377
348
|
```
|
|
378
349
|
|
|
379
350
|
### Relations
|
|
@@ -383,9 +354,9 @@ way)
|
|
|
383
354
|
|
|
384
355
|
```python
|
|
385
356
|
>>> import pyobo
|
|
386
|
-
>>> human_mapt_hgnc_id =
|
|
387
|
-
>>> mouse_mapt_mgi_id =
|
|
388
|
-
>>> hgnc_mgi_orthology_mapping = pyobo.get_relation_mapping(
|
|
357
|
+
>>> human_mapt_hgnc_id = "6893"
|
|
358
|
+
>>> mouse_mapt_mgi_id = "97180"
|
|
359
|
+
>>> hgnc_mgi_orthology_mapping = pyobo.get_relation_mapping("hgnc", "ro:HOM0000017", "mgi")
|
|
389
360
|
>>> assert mouse_mapt_mgi_id == hgnc_mgi_orthology_mapping[human_mapt_hgnc_id]
|
|
390
361
|
```
|
|
391
362
|
|
|
@@ -394,9 +365,9 @@ If you want to do it in one line, use:
|
|
|
394
365
|
```python
|
|
395
366
|
|
|
396
367
|
>>> import pyobo
|
|
397
|
-
>>> human_mapt_hgnc_id =
|
|
398
|
-
>>> mouse_mapt_mgi_id =
|
|
399
|
-
>>> assert mouse_mapt_mgi_id == pyobo.get_relation(
|
|
368
|
+
>>> human_mapt_hgnc_id = "6893"
|
|
369
|
+
>>> mouse_mapt_mgi_id = "97180"
|
|
370
|
+
>>> assert mouse_mapt_mgi_id == pyobo.get_relation("hgnc", "ro:HOM0000017", "mgi", human_mapt_hgnc_id)
|
|
400
371
|
```
|
|
401
372
|
|
|
402
373
|
### Writings Tests that Use PyOBO
|
|
@@ -412,8 +383,8 @@ import pyobo
|
|
|
412
383
|
from pyobo.mocks import get_mock_id_name_mapping
|
|
413
384
|
|
|
414
385
|
mock_id_name_mapping = get_mock_id_name_mapping({
|
|
415
|
-
|
|
416
|
-
|
|
386
|
+
"chebi": {
|
|
387
|
+
"132964": "fluazifop-P-butyl",
|
|
417
388
|
},
|
|
418
389
|
})
|
|
419
390
|
|
|
@@ -421,33 +392,21 @@ class MyTestCase(unittest.TestCase):
|
|
|
421
392
|
def my_test(self):
|
|
422
393
|
with mock_id_name_mapping:
|
|
423
394
|
# use functions directly, or use your functions that wrap them
|
|
424
|
-
pyobo.get_name(
|
|
395
|
+
pyobo.get_name("chebi", "1234")
|
|
425
396
|
```
|
|
426
397
|
|
|
427
|
-
##
|
|
398
|
+
## Preprocessing CURIEs, URIs, and unqualified identifiers
|
|
428
399
|
|
|
429
400
|
In order to normalize references and identify resources, PyOBO uses the
|
|
430
401
|
[Bioregistry](https://github.com/bioregistry/bioregistry). It used to be a part
|
|
431
402
|
of PyOBO, but has since been externalized for more general reuse.
|
|
432
403
|
|
|
433
404
|
At
|
|
434
|
-
[src/pyobo/
|
|
435
|
-
is the curated
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
Other entries in the metaregistry:
|
|
441
|
-
|
|
442
|
-
- The `"remappings"->"full"` entry is a dictionary from strings that might
|
|
443
|
-
follow `xref:` in a given OBO file that need to be completely replaced, due to
|
|
444
|
-
incorrect formatting
|
|
445
|
-
- The `"remappings"->"prefix"` entry contains a dictionary of prefixes for xrefs
|
|
446
|
-
that need to be remapped. Several rules, for example, remove superfluous
|
|
447
|
-
spaces that occur inside CURIEs or and others address instances of the GOGO
|
|
448
|
-
issue.
|
|
449
|
-
- The `"blacklists"` entry contains rules for throwing out malformed xrefs based
|
|
450
|
-
on full string, just prefix, or just suffix.
|
|
405
|
+
[src/pyobo/identifier_utils/preprocessing.json](https://github.com/pyobo/pyobo/blob/master/src/pyobo/src/pyobo/identifier_utils/preprocessing.json)
|
|
406
|
+
is the curated set of pre-processing rules. These are used in combination with
|
|
407
|
+
the `curies` package to do pre-processing steps on CURIEs, URIs, and unqualified
|
|
408
|
+
identifiers beyond what is possible with the Bioregistry. See
|
|
409
|
+
https://curies.readthedocs.io/en/latest/preprocessing.html.
|
|
451
410
|
|
|
452
411
|
## Troubleshooting
|
|
453
412
|
|
|
@@ -468,7 +427,6 @@ The most recent release can be installed from
|
|
|
468
427
|
[PyPI](https://pypi.org/project/pyobo/) with uv:
|
|
469
428
|
|
|
470
429
|
```console
|
|
471
|
-
python3 -m pip install pyobo
|
|
472
430
|
$ uv pip install pyobo
|
|
473
431
|
```
|
|
474
432
|
|