diff options
| author | Federico Igne <federico.igne@cs.ox.ac.uk> | 2022-05-18 15:09:37 +0100 |
|---|---|---|
| committer | Federico Igne <federico.igne@cs.ox.ac.uk> | 2022-05-18 15:38:25 +0100 |
| commit | 537277d9ce3ba2aff1d66d1b19dbb77e17be0d48 (patch) | |
| tree | d82884a5a72c7a8741084f7f324770d6b2e3489e /src/main/java/uk/ac/ox/cs/pagoda/rules | |
| parent | 52bba67e640fb1e30817fd1114a54e1d38ad5a74 (diff) | |
| download | ACQuA-537277d9ce3ba2aff1d66d1b19dbb77e17be0d48.tar.gz ACQuA-537277d9ce3ba2aff1d66d1b19dbb77e17be0d48.zip | |
build(hermit): bump HermiT v1.3.8.1 -> v1.4.5.519
This commit contains a "hacky" fix for KARMA2 to access some (now
private) field in the OWLAxioms class. The code is now using Java
Reflections to turn a private field public and gain access to internal
resources.
Diffstat (limited to 'src/main/java/uk/ac/ox/cs/pagoda/rules')
| -rw-r--r-- | src/main/java/uk/ac/ox/cs/pagoda/rules/LowerDatalogProgram.java | 5 | ||||
| -rw-r--r-- | src/main/java/uk/ac/ox/cs/pagoda/rules/Program.java | 2 |
2 files changed, 4 insertions, 3 deletions
diff --git a/src/main/java/uk/ac/ox/cs/pagoda/rules/LowerDatalogProgram.java b/src/main/java/uk/ac/ox/cs/pagoda/rules/LowerDatalogProgram.java index a2676e8..2610652 100644 --- a/src/main/java/uk/ac/ox/cs/pagoda/rules/LowerDatalogProgram.java +++ b/src/main/java/uk/ac/ox/cs/pagoda/rules/LowerDatalogProgram.java | |||
| @@ -1,6 +1,7 @@ | |||
| 1 | package uk.ac.ox.cs.pagoda.rules; | 1 | package uk.ac.ox.cs.pagoda.rules; |
| 2 | 2 | ||
| 3 | import org.apache.commons.io.FilenameUtils; | 3 | import org.apache.commons.io.FilenameUtils; |
| 4 | import org.semanticweb.HermiT.Configuration; | ||
| 4 | import org.semanticweb.HermiT.Reasoner; | 5 | import org.semanticweb.HermiT.Reasoner; |
| 5 | import org.semanticweb.HermiT.model.*; | 6 | import org.semanticweb.HermiT.model.*; |
| 6 | import org.semanticweb.owlapi.model.*; | 7 | import org.semanticweb.owlapi.model.*; |
| @@ -149,7 +150,7 @@ class ClassifyThread extends Thread { | |||
| 149 | public void run() { | 150 | public void run() { |
| 150 | ontology = m_program.getOntology(); | 151 | ontology = m_program.getOntology(); |
| 151 | try { | 152 | try { |
| 152 | hermitReasoner = new Reasoner(ontology); | 153 | hermitReasoner = new Reasoner(new Configuration(), ontology); |
| 153 | Timer t = new Timer(); | 154 | Timer t = new Timer(); |
| 154 | hermitReasoner.classifyClasses(); | 155 | hermitReasoner.classifyClasses(); |
| 155 | Utility.logInfo("HermiT classification done: " + t.duration()); | 156 | Utility.logInfo("HermiT classification done: " + t.duration()); |
| @@ -235,4 +236,4 @@ class ClassifyThread extends Thread { | |||
| 235 | private Atom getAtom(OWLClass c) { | 236 | private Atom getAtom(OWLClass c) { |
| 236 | return Atom.create(AtomicConcept.create(c.toStringID()), X); | 237 | return Atom.create(AtomicConcept.create(c.toStringID()), X); |
| 237 | } | 238 | } |
| 238 | } \ No newline at end of file | 239 | } |
diff --git a/src/main/java/uk/ac/ox/cs/pagoda/rules/Program.java b/src/main/java/uk/ac/ox/cs/pagoda/rules/Program.java index de06f52..22eb9ec 100644 --- a/src/main/java/uk/ac/ox/cs/pagoda/rules/Program.java +++ b/src/main/java/uk/ac/ox/cs/pagoda/rules/Program.java | |||
| @@ -273,7 +273,7 @@ protected PredicateDependency dependencyGraph; | |||
| 273 | Utility.logInfo("The number of data property range axioms that are ignored: " + noOfDataPropertyRangeAxioms + "(" + noOfAxioms + ")"); | 273 | Utility.logInfo("The number of data property range axioms that are ignored: " + noOfDataPropertyRangeAxioms + "(" + noOfAxioms + ")"); |
| 274 | 274 | ||
| 275 | DLOntology dlOntology = (DLOntology) clausifier.preprocessAndClausify(filteredOntology, null)[1]; | 275 | DLOntology dlOntology = (DLOntology) clausifier.preprocessAndClausify(filteredOntology, null)[1]; |
| 276 | dlClauses = dlOntology.getDLClauses(); | 276 | dlClauses = new HashSet<DLClause>(dlOntology.getDLClauses()); |
| 277 | positiveFacts = dlOntology.getPositiveFacts(); | 277 | positiveFacts = dlOntology.getPositiveFacts(); |
| 278 | } | 278 | } |
| 279 | 279 | ||
