rdf - How can I use OWL Import with relative paths? -
in owl file, import many other files like:
<owl:imports rdf:resource="file:/home/noor/downloads/bbc/anatidae.rdf"/> <owl:imports rdf:resource="file:/home/noor/downloads/bbc/animal.rdf"/> <owl:imports rdf:resource="file:/home/noor/downloads/bbc/bird.rdf"/> <owl:imports rdf:resource="file:/home/noor/downloads/bbc/chordate.rdf"/> <owl:imports rdf:resource="file:/home/noor/downloads/bbc/kingdom.rdf"/> <owl:imports rdf:resource="file:/home/noor/downloads/bbc/mammal.rdf"/>
but i'm not able manage relative paths; these failing:
<owl:imports rdf:resource="file:anatidae.rdf"/> <owl:imports rdf:resource="file:./anatidae.rdf"/>
how can relative paths?
imports supposed point uris rather local files, therefore tools not support yet import local assets. in order handle local files, have following solutions:
a quick fix expose rdf via local web server , access them (e.g.
<owl:imports rdf:resource="http://localhost/chordate.rdf"/>
).if using protege open owl file, can configure mapping between actual files , import iri in
active ontology
-->import ontology
tab.last solution, if work brain can load files 1 one without dealing
owl:imports
, example:brain brain = new brain();
brain.learn("/home/noor/downloads/bbc/bird.rdf");
Comments
Post a Comment