Skip to content

Commit 3e6d272

Browse files
committed
Workaround for lack of relaxation in ROBOT.
ontodev/robot#1183 (comment)
1 parent d7e7c70 commit 3e6d272

File tree

2 files changed

+15
-2
lines changed

2 files changed

+15
-2
lines changed

src/ontology/Makefile

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,9 @@ ANNOTATE_VERSION_IRI = annotate -V $(ONTBASE)/releases/`date +%Y-%m-%d`/[email protected]
130130

131131
# by default we use ELK to perform a reason-relax-reduce chain
132132
# after that we annotate the ontology with the release versionInfo
133-
$(ONT).owl: $(SRC)
133+
$(SRC).relaxed.obo: $(SRC)
134+
./relax-qcrs.pl $< > $@.tmp && mv $@.tmp $@
135+
$(ONT).owl: $(SRC).relaxed.obo
134136
$(ROBOT) reason --input $< --reasoner ELK \
135137
relax \
136138
reduce -r ELK \
@@ -235,7 +237,7 @@ IM=build-$(ONT)
235237
build-docker:
236238
docker build -t $(ONT) .
237239

238-
240+
include upa.Makefile
239241

240242

241243

src/ontology/relax-qcrs.pl

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
#!/usr/bin/perl
2+
3+
while (<>) {
4+
print;
5+
if (m@cardinality="(\d+)"@) {
6+
if ($1) {
7+
s@\s+\{.*\} *@ @;
8+
print;
9+
}
10+
}
11+
}

0 commit comments

Comments
 (0)