Skip to content

Commit

Permalink
add common-anatomy.owl artifact
Browse files Browse the repository at this point in the history
  • Loading branch information
anitacaron committed Jun 26, 2023
1 parent 2cea8c5 commit cdf013d
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,7 @@ uberon-base.obo
uberon-basic.*
uberon-full.*
uberon-simple.*
common-anatomy.*
patterns/definitions.owl
patterns/pattern.owl
subsets/*.json
Expand Down
11 changes: 10 additions & 1 deletion src/ontology/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ PATTERN_RELEASE_FILES= $(PATTERNDIR)/definitions.owl $(PATTERNDIR)/pattern.

FORMATS = $(sort owl obo json owl)
FORMATS_INCL_TSV = $(sort $(FORMATS) tsv)
RELEASE_ARTEFACTS = $(sort $(ONT)-base $(ONT)-full $(ONT)-simple $(ONT)-basic ext basic composite-metazoan composite-metazoan-basic composite-vertebrate composite-vertebrate-basic )
RELEASE_ARTEFACTS = $(sort $(ONT)-base $(ONT)-full $(ONT)-simple $(ONT)-basic ext basic composite-metazoan composite-metazoan-basic composite-vertebrate composite-vertebrate-basic common-anatomy )

# ----------------------------------------
# Top-level targets
Expand Down Expand Up @@ -703,6 +703,12 @@ composite-vertebrate-basic.json: composite-vertebrate-basic.owl
$(ROBOT) annotate --input $< --ontology-iri $(ONTBASE)/$@ $(ANNOTATE_ONTOLOGY_VERSION) \
convert --check false -f json -o $@.tmp.json &&\
mv $@.tmp.json $@
common-anatomy.obo: common-anatomy.owl
$(ROBOT) convert --input $< --check false -f obo $(OBO_FORMAT_OPTIONS) -o $@.tmp.obo && grep -v ^owl-axioms $@.tmp.obo > $@ && rm $@.tmp.obo
common-anatomy.json: common-anatomy.owl
$(ROBOT) annotate --input $< --ontology-iri $(ONTBASE)/$@ $(ANNOTATE_ONTOLOGY_VERSION) \
convert --check false -f json -o $@.tmp.json &&\
mv $@.tmp.json $@
# ----------------------------------------
# Release artefacts: main release artefacts
# ----------------------------------------
Expand Down Expand Up @@ -791,6 +797,9 @@ composite-vertebrate.owl:

composite-vertebrate-basic.owl:
echo "ERROR: You have configured a custom release artefact ($@); this release artefact needs to be define in uberon.Makefile!" && false

common-anatomy.owl:
echo "ERROR: You have configured a custom release artefact ($@); this release artefact needs to be define in uberon.Makefile!" && false
# ----------------------------------------
# Debugging Tools
# ----------------------------------------
Expand Down
1 change: 1 addition & 0 deletions src/ontology/uberon-odk.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ release_artefacts:
- custom-composite-metazoan-basic
- custom-composite-vertebrate
- custom-composite-vertebrate-basic
- custom-common-anatomy
edit_format: obo
import_group:
use_base_merging: TRUE
Expand Down
10 changes: 10 additions & 0 deletions src/ontology/uberon.Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -254,6 +254,16 @@ subsets/cumbo.obo: subsets/cumbo.owl
#supercheck.owl: $(TMPDIR)/unreasoned.owl
# owltools $(UCAT) $< $(COMPONENTSDIR)/phenoscape-ext.owl --merge-support-ontologies --expand-macros --assert-inferred-subclass-axioms --useIsInferred -o -f functional $@

# ----------------------------------------
# STEP 6: Create common anatomy subset
# ----------------------------------------

common-anatomy.owl: $(ONT).owl
$(OWLTOOLS) $< --extract-ontology-subset --fill-gaps --subset common_anatomy -o $@.tmp.owl && mv $@.tmp.owl $@ &&\
$(ROBOT) annotate --input $@ --ontology-iri $(ONTBASE)/$@ $(ANNOTATE_ONTOLOGY_VERSION) -o $@.tmp.owl && mv $@.tmp.owl $@
.PRECIOUS: common-anatomy.owl



# ----------------------------------------
# IMPORTS
Expand Down

0 comments on commit cdf013d

Please sign in to comment.