Error loading the MALOnt.owl file with owlready2
Opened this issue · 0 comments
Simply loading the owl file using owlready2:
my_onto = get_ontology("MALOnt.owl").load()
, throws an error:
KeyError Traceback (most recent call last)
KeyError: '_:owlready_blank_3'
Exception ignored in: 'owlready2_optimized.add_to_bn2'
Traceback (most recent call last):
File "/home/anna/anaconda3/envs/my_NER/lib/python3.8/site-packages/owlready2/driver.py", line 218, in do_parse
if format == "rdfxml": owlready2_optimized.parse_rdfxml(f, queue, default_base, batch_size)
KeyError: '_:owlready_blank_3'
Yet, even though the error is thrown, the MALOnt ontology is loaded into my_onto
, and individuals, classes etc. can be assesed using my_onto.individuals()
, my_onto.classes()
etc.
Moreover, after getting the error, if the same command is repeated (my_onto = get_ontology("MALOnt.owl").load())
, it throws no error and everything functions correctly.