lambdamusic / Ontospy

Python library and command-line interface for inspecting and visualizing RDF models aka ontologies.
http://lambdamusic.github.io/Ontospy/
MIT License
218 stars 52 forks source link

get_rdf(path) retrieve an empty model #35

Open corinabioinformatic opened 6 years ago

corinabioinformatic commented 6 years ago

This script: path = "~\go.owl.rdf" o = ontospy.Ontospy() model = o.load_rdf(path) Takes time to load the file, but once it is loaded retrieve an empty model. But when I download it from the website: url = "http://purl.obolibrary.org/obo/go.owl" model = ontospy.Ontospy(url) It takes longer but at least it retrieve a non empty model. I will check again along the day. But I cannot figurate out the error.

lambdamusic commented 5 years ago

The go.owl ontology loads fine from the command line (after ~ 1HR!). It's a 150M ontology though and ontospy is not optimized for that kind of sizes. Best option you have is probably to load it into a triplestore first, then point ontospy to its sparql endpoint.

I'll be looking at improving loading speed in the context of #44