I am using owlready2 api for python to load an Ontology and check consistency for that ontology using the sync_reasoner() function. But it seems that it is not checking the consistency for the ontology. Although there is an error, it shows nothing! Any idea how can I check consistency of an ontology in python using owlready2 or any other api.
here is my small code:
from owlready2 import *
onto = get_ontology("test.owl")
sync_reasoner()
and here is the output I am getting:
- Owlready2 * Running HermiT... java -Xmx2000M -cp C:\Users\44999038\AppData\Local\Programs\Python\Python36-32\lib\site-packages\owlready2\hermit;C:\Users\44999038\AppData\Local\Programs\Python\Python36-32\lib\site-packages\owlready2\hermit\HermiT.jar org.semanticweb.HermiT.cli.CommandLine -c -O -D -I file:///C:/Users/44999038/AppData/Local/Temp/tmptmcc_a79
- Owlready2 * HermiT took 0.48622655868530273 seconds
My modified code:
from owlready2 import *
onto = get_ontology("test.owl")
with onto:sync_reasoner()
onto.save()
Output owl file I have got: