pwin / owlready2

GNU Lesser General Public License v3.0
140 stars 23 forks source link

Ontology not loaded #19

Open yoavxyoav opened 2 years ago

yoavxyoav commented 2 years ago

I have followed the instructions as they appear here, yet when I trying to load SNOMED CT using

>>> from owlready2 import *
>>> from owlready2.pymedtermino2.umls import *
>>> default_world.set_backend(filename = "pym.sqlite3")
>>> import_umls("mmsys.zip", terminologies = ["ICD10", "SNOMEDCT_US", "CUI"])
>>> default_world.save()

Output is: Importing UMLS from /Users/yoav/Documents/2021AB-full/mmsys.zip with Python version 3.8.12 and Owlready version 2-0.36... Parsing config/2021AB/MRSTY.RRF.gz as MRSTY with encoding UTF-8 Parsing config/2021AB/MRRANK.RRF as MRRANK Breaking ORIG cycles... Finalizing only properties and restrictions... Finalizing CUI - ORIG mapping... FTS Indexing...

then

>>> PYM = get_ontology("http://PYM/").load()
>>> SNOMEDCT_US = PYM["SNOMEDCT_US"]

however SNOMED_US appears to be NoneType.

When I change the last line to SOMETHING = PYM["CUI"], an object is returned.

Not sure what I'm missing.