Open vanlot opened 8 years ago
How large is the ontology? (Can you post it here if possible?)
How much memory have you allocated to the JVM?
It is not big, with around 66 classes (see the attached file). I also allocate -Xmx2048m in JMV in Java EE Eclipse. Note:
File: Sample.zip
Thanks Van
I am having the exact same issue . The ontology is pretty small with 2 SWRL rules , but it still takes longer time to load .
OWLOntologyManager owlManager = OWLManager.createOWLOntologyManager(); OWLOntology ontology = owlManager .loadOntologyFromOntologyDocument(fileStorageService.loadFileAsResource("test.owl").getFile()); // The below line takes long time to load although the file is pretty small. return SWRLAPIFactory.createSQWRLQueryEngine(ontology);
jars used
swrlapi-2.0.8.jar swrlapi-drools-engine-2.0.8.jar
Hi friends,
I have a problem with creating query engine object. It takes too much time to generate an object of query engine (around 1 minute). My code is below: .... String path = "C:/Ontology/Test/Heart.owl";
try { // Create OWLOntology instances using the OWLAPI ontologyManager = OWLManager.createOWLOntologyManager();
File file = new File(path); ontology = ontologyManager.loadOntologyFromOntologyDocument(file);
queryEngine = SWRLAPIFactory.createSQWRLQueryEngine(ontology);
} catch (OWLOntologyCreationException e) { e.printStackTrace(); } It take more than one minute to execute the code: queryEngine = SWRLAPIFactory.createSQWRLQueryEngine(ontology);
Are there any solutions to make it run faster?
Thank you,
Van