From: <lor...@us...> - 2012-05-03 15:12:10
|
Revision: 3685 http://dl-learner.svn.sourceforge.net/dl-learner/?rev=3685&view=rev Author: lorenz_b Date: 2012-05-03 15:12:01 +0000 (Thu, 03 May 2012) Log Message: ----------- Check for empty entities. Modified Paths: -------------- trunk/scripts/src/main/java/org/dllearner/scripts/evaluation/EnrichmentEvaluation.java Modified: trunk/scripts/src/main/java/org/dllearner/scripts/evaluation/EnrichmentEvaluation.java =================================================================== --- trunk/scripts/src/main/java/org/dllearner/scripts/evaluation/EnrichmentEvaluation.java 2012-05-03 14:43:04 UTC (rev 3684) +++ trunk/scripts/src/main/java/org/dllearner/scripts/evaluation/EnrichmentEvaluation.java 2012-05-03 15:12:01 UTC (rev 3685) @@ -378,8 +378,12 @@ int attempt = 0; long startTime = 0; + boolean emptyEntity = sparqlReasoner.getPopularity(property) == 0; + if(emptyEntity){ + logger.warn("Empty entity: " + property); + } boolean timeout = true; - while(((AbstractAxiomLearningAlgorithm)learner).isTimeout() && attempt++ < maxAttempts){ + while(!emptyEntity && ((AbstractAxiomLearningAlgorithm)learner).isTimeout() && attempt++ < maxAttempts){ if(attempt > 1){ try { logger.warn("Got timeout. Waiting " + delayInMilliseconds + " ms ..."); @@ -405,7 +409,9 @@ long runTime = System.currentTimeMillis() - startTime; List<EvaluatedAxiom> learnedAxioms = learner .getCurrentlyBestEvaluatedAxioms(nrOfAxiomsToLearn); - if(timeout && learnedAxioms.isEmpty()){ + if(emptyEntity){ + writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "EMPTY_ENTITY", 0, 0, false); + } else if(timeout && learnedAxioms.isEmpty()){ writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "TIMEOUT", 0, runTime, false); } else if (learnedAxioms == null || learnedAxioms.isEmpty()) { writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "NULL", 0, runTime, false); @@ -454,10 +460,15 @@ // learner.setMaxExecutionTimeInSeconds(10); algName = AnnComponentManager.getName(learner); + boolean emptyEntity = sparqlReasoner.getPopularity(property) == 0; + if(emptyEntity){ + logger.warn("Empty entity: " + property); + } + int attempt = 0; long startTime = 0; boolean timeout = true; - while(((AbstractAxiomLearningAlgorithm)learner).isTimeout() && attempt++ < maxAttempts){ + while(!emptyEntity && ((AbstractAxiomLearningAlgorithm)learner).isTimeout() && attempt++ < maxAttempts){ if(attempt > 1){ try { logger.warn("Got timeout. Waiting " + delayInMilliseconds + " ms ..."); @@ -483,7 +494,9 @@ long runTime = System.currentTimeMillis() - startTime; List<EvaluatedAxiom> learnedAxioms = learner .getCurrentlyBestEvaluatedAxioms(nrOfAxiomsToLearn); - if(timeout && learnedAxioms.isEmpty()){ + if(emptyEntity){ + writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "EMPTY_ENTITY", 0, 0, false); + } else if(timeout && learnedAxioms.isEmpty()){ writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "TIMEOUT", 0, runTime, false); } else if (learnedAxioms == null || learnedAxioms.isEmpty()) { writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "NULL", 0, runTime, false); @@ -519,13 +532,19 @@ try{ List<EvaluatedAxiom> learnedAxioms = null; + boolean emptyEntity = sparqlReasoner.getPopularity(cls) == 0; + if(emptyEntity){ + logger.warn("Empty entity: " + cls); + } long startTime = System.currentTimeMillis(); boolean timeout = false; String algName; if(algorithmClass == CELOE.class){ algName = CELOE.class.getAnnotation(ComponentAnn.class).name(); logger.info("Applying " + algName + " on " + cls + " ... "); - learnedAxioms = applyCELOE(ks, cls, false); + if(!emptyEntity){ + learnedAxioms = applyCELOE(ks, cls, false); + } } else { // dynamically invoke constructor with SPARQL knowledge source @@ -542,7 +561,7 @@ int attempt = 0; timeout = true; - while(((AbstractAxiomLearningAlgorithm)learner).isTimeout() && attempt++ < maxAttempts){ + while(!emptyEntity && ((AbstractAxiomLearningAlgorithm)learner).isTimeout() && attempt++ < maxAttempts){ if(attempt > 1){ try { logger.warn("Got timeout. Waiting " + delayInMilliseconds + " ms ..."); @@ -566,7 +585,9 @@ long runTime = System.currentTimeMillis() - startTime; - if(timeout && learnedAxioms.isEmpty()){ + if(emptyEntity){ + writeToDB(cls.toManchesterSyntaxString(baseURI, prefixes), algName, "EMPTY_ENTITY", 0, 0, false); + } else if(timeout && learnedAxioms.isEmpty()){ writeToDB(cls.toManchesterSyntaxString(baseURI, prefixes), algName, "TIMEOUT", 0, runTime, false); } else if (learnedAxioms == null || learnedAxioms.isEmpty()) { writeToDB(cls.toManchesterSyntaxString(baseURI, prefixes), algName, "NULL", 0, runTime, false); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <lor...@us...> - 2012-05-03 15:25:23
|
Revision: 3686 http://dl-learner.svn.sourceforge.net/dl-learner/?rev=3686&view=rev Author: lorenz_b Date: 2012-05-03 15:25:13 +0000 (Thu, 03 May 2012) Log Message: ----------- Check for empty entities. Modified Paths: -------------- trunk/scripts/src/main/java/org/dllearner/scripts/evaluation/EnrichmentEvaluation.java Modified: trunk/scripts/src/main/java/org/dllearner/scripts/evaluation/EnrichmentEvaluation.java =================================================================== --- trunk/scripts/src/main/java/org/dllearner/scripts/evaluation/EnrichmentEvaluation.java 2012-05-03 15:12:01 UTC (rev 3685) +++ trunk/scripts/src/main/java/org/dllearner/scripts/evaluation/EnrichmentEvaluation.java 2012-05-03 15:25:13 UTC (rev 3686) @@ -376,55 +376,59 @@ // learner.setMaxExecutionTimeInSeconds(10); algName = AnnComponentManager.getName(learner); - int attempt = 0; - long startTime = 0; boolean emptyEntity = sparqlReasoner.getPopularity(property) == 0; if(emptyEntity){ logger.warn("Empty entity: " + property); } - boolean timeout = true; - while(!emptyEntity && ((AbstractAxiomLearningAlgorithm)learner).isTimeout() && attempt++ < maxAttempts){ - if(attempt > 1){ + + if(emptyEntity){ + writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "EMPTY_ENTITY", 0, 0, false); + } else { + int attempt = 0; + long startTime = 0; + boolean timeout = true; + while(((AbstractAxiomLearningAlgorithm)learner).isTimeout() && attempt++ < maxAttempts){ + if(attempt > 1){ + try { + logger.warn("Got timeout. Waiting " + delayInMilliseconds + " ms ..."); + Thread.sleep(delayInMilliseconds); + } catch (InterruptedException e) { + e.printStackTrace(); + } + } + logger.info("Applying " + algName + " on " + property + " ... (Attempt " + attempt + ")"); + startTime = System.currentTimeMillis(); try { - logger.warn("Got timeout. Waiting " + delayInMilliseconds + " ms ..."); - Thread.sleep(delayInMilliseconds); - } catch (InterruptedException e) { - e.printStackTrace(); + learner.start(); + timeout = false; + } catch (Exception e) { + if(e.getCause() instanceof SocketTimeoutException){ + + } else { + e.printStackTrace(); + } } } - logger.info("Applying " + algName + " on " + property + " ... (Attempt " + attempt + ")"); - startTime = System.currentTimeMillis(); - try { - learner.start(); - timeout = false; - } catch (Exception e) { - if(e.getCause() instanceof SocketTimeoutException){ - - } else { - e.printStackTrace(); + + long runTime = System.currentTimeMillis() - startTime; + List<EvaluatedAxiom> learnedAxioms = learner + .getCurrentlyBestEvaluatedAxioms(nrOfAxiomsToLearn); + if(timeout && learnedAxioms.isEmpty()){ + writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "TIMEOUT", 0, runTime, false); + } else if (learnedAxioms == null || learnedAxioms.isEmpty()) { + writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "NULL", 0, runTime, false); + } else { + for (EvaluatedAxiom learnedAxiom : learnedAxioms) { + double score = learnedAxiom.getScore().getAccuracy(); + if (Double.isNaN(score)) { + score = -1; + } + writeToDB(property.toManchesterSyntaxString(baseURI, prefixes) .toString(), algName, learnedAxiom.getAxiom().toManchesterSyntaxString(baseURI, prefixes), + score, runTime, isEntailed(learnedAxiom)); } } } - long runTime = System.currentTimeMillis() - startTime; - List<EvaluatedAxiom> learnedAxioms = learner - .getCurrentlyBestEvaluatedAxioms(nrOfAxiomsToLearn); - if(emptyEntity){ - writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "EMPTY_ENTITY", 0, 0, false); - } else if(timeout && learnedAxioms.isEmpty()){ - writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "TIMEOUT", 0, runTime, false); - } else if (learnedAxioms == null || learnedAxioms.isEmpty()) { - writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "NULL", 0, runTime, false); - } else { - for (EvaluatedAxiom learnedAxiom : learnedAxioms) { - double score = learnedAxiom.getScore().getAccuracy(); - if (Double.isNaN(score)) { - score = -1; - } - writeToDB(property.toManchesterSyntaxString(baseURI, prefixes) .toString(), algName, learnedAxiom.getAxiom().toManchesterSyntaxString(baseURI, prefixes), - score, runTime, isEntailed(learnedAxiom)); - } - } objectProperties++; if (maxObjectProperties != 0 && objectProperties == maxObjectProperties) { break; @@ -464,52 +468,54 @@ if(emptyEntity){ logger.warn("Empty entity: " + property); } - - int attempt = 0; - long startTime = 0; - boolean timeout = true; - while(!emptyEntity && ((AbstractAxiomLearningAlgorithm)learner).isTimeout() && attempt++ < maxAttempts){ - if(attempt > 1){ + if(emptyEntity){ + writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "EMPTY_ENTITY", 0, 0, false); + } else { + int attempt = 0; + long startTime = 0; + boolean timeout = true; + while(((AbstractAxiomLearningAlgorithm)learner).isTimeout() && attempt++ < maxAttempts){ + if(attempt > 1){ + try { + logger.warn("Got timeout. Waiting " + delayInMilliseconds + " ms ..."); + Thread.sleep(delayInMilliseconds); + } catch (InterruptedException e) { + e.printStackTrace(); + } + } + logger.info("Applying " + algName + " on " + property + " ... (Attempt " + attempt + ")"); + startTime = System.currentTimeMillis(); try { - logger.warn("Got timeout. Waiting " + delayInMilliseconds + " ms ..."); - Thread.sleep(delayInMilliseconds); - } catch (InterruptedException e) { - e.printStackTrace(); + learner.start(); + timeout = false; + } catch (Exception e) { + if(e.getCause() instanceof SocketTimeoutException){ + + } else { + e.printStackTrace(); + } } } - logger.info("Applying " + algName + " on " + property + " ... (Attempt " + attempt + ")"); - startTime = System.currentTimeMillis(); - try { - learner.start(); - timeout = false; - } catch (Exception e) { - if(e.getCause() instanceof SocketTimeoutException){ - - } else { - e.printStackTrace(); + + long runTime = System.currentTimeMillis() - startTime; + List<EvaluatedAxiom> learnedAxioms = learner + .getCurrentlyBestEvaluatedAxioms(nrOfAxiomsToLearn); + if(timeout && learnedAxioms.isEmpty()){ + writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "TIMEOUT", 0, runTime, false); + } else if (learnedAxioms == null || learnedAxioms.isEmpty()) { + writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "NULL", 0, runTime, false); + } else { + for (EvaluatedAxiom learnedAxiom : learnedAxioms) { + double score = learnedAxiom.getScore().getAccuracy(); + if (Double.isNaN(score)) { + score = -1; + } + writeToDB(property.toManchesterSyntaxString(baseURI, prefixes) .toString(), algName, learnedAxiom.getAxiom().toManchesterSyntaxString(baseURI, prefixes), + score, runTime, isEntailed(learnedAxiom)); } } } - long runTime = System.currentTimeMillis() - startTime; - List<EvaluatedAxiom> learnedAxioms = learner - .getCurrentlyBestEvaluatedAxioms(nrOfAxiomsToLearn); - if(emptyEntity){ - writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "EMPTY_ENTITY", 0, 0, false); - } else if(timeout && learnedAxioms.isEmpty()){ - writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "TIMEOUT", 0, runTime, false); - } else if (learnedAxioms == null || learnedAxioms.isEmpty()) { - writeToDB(property.toManchesterSyntaxString(baseURI, prefixes), algName, "NULL", 0, runTime, false); - } else { - for (EvaluatedAxiom learnedAxiom : learnedAxioms) { - double score = learnedAxiom.getScore().getAccuracy(); - if (Double.isNaN(score)) { - score = -1; - } - writeToDB(property.toManchesterSyntaxString(baseURI, prefixes) .toString(), algName, learnedAxiom.getAxiom().toManchesterSyntaxString(baseURI, prefixes), - score, runTime, isEntailed(learnedAxiom)); - } - } dataProperties++; if (maxDataProperties != 0 && dataProperties == maxDataProperties) { break; @@ -531,77 +537,81 @@ for (NamedClass cls : classes) { try{ - List<EvaluatedAxiom> learnedAxioms = null; - boolean emptyEntity = sparqlReasoner.getPopularity(cls) == 0; - if(emptyEntity){ - logger.warn("Empty entity: " + cls); - } - long startTime = System.currentTimeMillis(); - boolean timeout = false; - String algName; + String algName = ""; if(algorithmClass == CELOE.class){ algName = CELOE.class.getAnnotation(ComponentAnn.class).name(); - logger.info("Applying " + algName + " on " + cls + " ... "); - if(!emptyEntity){ - learnedAxioms = applyCELOE(ks, cls, false); - } } else { - - // dynamically invoke constructor with SPARQL knowledge source LearningAlgorithm learner = algorithmClass.getConstructor( SparqlEndpointKS.class).newInstance(ks); - ((AbstractAxiomLearningAlgorithm)learner).setReasoner(sparqlReasoner); - ConfigHelper.configure(learner, "classToDescribe", cls.toString()); - ConfigHelper.configure(learner, "maxExecutionTimeInSeconds", - maxExecutionTimeInSeconds); - learner.init(); - // learner.setPropertyToDescribe(property); - // learner.setMaxExecutionTimeInSeconds(10); algName = AnnComponentManager.getName(learner); - int attempt = 0; - - timeout = true; - while(!emptyEntity && ((AbstractAxiomLearningAlgorithm)learner).isTimeout() && attempt++ < maxAttempts){ - if(attempt > 1){ + } + List<EvaluatedAxiom> learnedAxioms = new ArrayList<EvaluatedAxiom>(); + boolean emptyEntity = sparqlReasoner.getPopularity(cls) == 0; + if(emptyEntity){ + logger.warn("Empty entity: " + cls); + writeToDB(cls.toManchesterSyntaxString(baseURI, prefixes), algName, "EMPTY_ENTITY", 0, 0, false); + } else { + long startTime = System.currentTimeMillis(); + boolean timeout = false; + if(algorithmClass == CELOE.class){ + logger.info("Applying " + algName + " on " + cls + " ... "); + learnedAxioms = applyCELOE(ks, cls, false); + } else { + + // dynamically invoke constructor with SPARQL knowledge source + LearningAlgorithm learner = algorithmClass.getConstructor( + SparqlEndpointKS.class).newInstance(ks); + ((AbstractAxiomLearningAlgorithm)learner).setReasoner(sparqlReasoner); + ConfigHelper.configure(learner, "classToDescribe", cls.toString()); + ConfigHelper.configure(learner, "maxExecutionTimeInSeconds", + maxExecutionTimeInSeconds); + learner.init(); + // learner.setPropertyToDescribe(property); + // learner.setMaxExecutionTimeInSeconds(10); + int attempt = 0; + + timeout = true; + while(((AbstractAxiomLearningAlgorithm)learner).isTimeout() && attempt++ < maxAttempts){ + if(attempt > 1){ + try { + logger.warn("Got timeout. Waiting " + delayInMilliseconds + " ms ..."); + Thread.sleep(delayInMilliseconds); + } catch (InterruptedException e) { + e.printStackTrace(); + } + } + logger.info("Applying " + algName + " on " + cls + " ... (Attempt " + attempt + ")"); + startTime = System.currentTimeMillis(); try { - logger.warn("Got timeout. Waiting " + delayInMilliseconds + " ms ..."); - Thread.sleep(delayInMilliseconds); - } catch (InterruptedException e) { + learner.start(); + timeout = false; + } catch (Exception e) { e.printStackTrace(); } } - logger.info("Applying " + algName + " on " + cls + " ... (Attempt " + attempt + ")"); - startTime = System.currentTimeMillis(); - try { - learner.start(); - timeout = false; - } catch (Exception e) { - e.printStackTrace(); + learnedAxioms = ((AxiomLearningAlgorithm)learner).getCurrentlyBestEvaluatedAxioms(nrOfAxiomsToLearn); + } + + + long runTime = System.currentTimeMillis() - startTime; + + if(timeout && learnedAxioms.isEmpty()){ + writeToDB(cls.toManchesterSyntaxString(baseURI, prefixes), algName, "TIMEOUT", 0, runTime, false); + } else if (learnedAxioms == null || learnedAxioms.isEmpty()) { + writeToDB(cls.toManchesterSyntaxString(baseURI, prefixes), algName, "NULL", 0, runTime, false); + } else { + for (EvaluatedAxiom learnedAxiom : learnedAxioms) { + double score = learnedAxiom.getScore().getAccuracy(); + if (Double.isNaN(score)) { + score = -1; + } + writeToDB(cls.toManchesterSyntaxString(baseURI, prefixes) .toString(), algName, learnedAxiom.getAxiom().toManchesterSyntaxString(baseURI, prefixes), + score, runTime, isEntailed(learnedAxiom)); } } - learnedAxioms = ((AxiomLearningAlgorithm)learner).getCurrentlyBestEvaluatedAxioms(nrOfAxiomsToLearn); } - long runTime = System.currentTimeMillis() - startTime; - - if(emptyEntity){ - writeToDB(cls.toManchesterSyntaxString(baseURI, prefixes), algName, "EMPTY_ENTITY", 0, 0, false); - } else if(timeout && learnedAxioms.isEmpty()){ - writeToDB(cls.toManchesterSyntaxString(baseURI, prefixes), algName, "TIMEOUT", 0, runTime, false); - } else if (learnedAxioms == null || learnedAxioms.isEmpty()) { - writeToDB(cls.toManchesterSyntaxString(baseURI, prefixes), algName, "NULL", 0, runTime, false); - } else { - for (EvaluatedAxiom learnedAxiom : learnedAxioms) { - double score = learnedAxiom.getScore().getAccuracy(); - if (Double.isNaN(score)) { - score = -1; - } - writeToDB(cls.toManchesterSyntaxString(baseURI, prefixes) .toString(), algName, learnedAxiom.getAxiom().toManchesterSyntaxString(baseURI, prefixes), - score, runTime, isEntailed(learnedAxiom)); - } - } - classesCnt++; if (maxClasses != 0 && classesCnt == maxClasses) { break; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <lor...@us...> - 2012-05-03 21:20:37
|
Revision: 3690 http://dl-learner.svn.sourceforge.net/dl-learner/?rev=3690&view=rev Author: lorenz_b Date: 2012-05-03 21:20:31 +0000 (Thu, 03 May 2012) Log Message: ----------- Fallback to SPARQL 1.0 after 2 attempts. Modified Paths: -------------- trunk/scripts/src/main/java/org/dllearner/scripts/evaluation/EnrichmentEvaluation.java Modified: trunk/scripts/src/main/java/org/dllearner/scripts/evaluation/EnrichmentEvaluation.java =================================================================== --- trunk/scripts/src/main/java/org/dllearner/scripts/evaluation/EnrichmentEvaluation.java 2012-05-03 21:20:22 UTC (rev 3689) +++ trunk/scripts/src/main/java/org/dllearner/scripts/evaluation/EnrichmentEvaluation.java 2012-05-03 21:20:31 UTC (rev 3690) @@ -183,6 +183,8 @@ // max. number of attempts per algorithm and entity, because to many queries // in a short time could cause blocking by the endpoint private final int maxAttempts = 5; + //after 2 attempts we force the iterative SPARQL 1.1 mode + private final int nrOfAttemptsBeforeForceToSPARQL1_0_Mode = 2; //delay between 2 attempts private final int delayInMilliseconds = 15000; @@ -399,6 +401,7 @@ logger.info("Applying " + algName + " on " + property + " ... (Attempt " + attempt + ")"); startTime = System.currentTimeMillis(); try { + ((AbstractAxiomLearningAlgorithm)learner).setForceSPARQL_1_0_Mode(attempt > nrOfAttemptsBeforeForceToSPARQL1_0_Mode); learner.start(); timeout = false; } catch (Exception e) { @@ -486,6 +489,7 @@ logger.info("Applying " + algName + " on " + property + " ... (Attempt " + attempt + ")"); startTime = System.currentTimeMillis(); try { + ((AbstractAxiomLearningAlgorithm)learner).setForceSPARQL_1_0_Mode(attempt > nrOfAttemptsBeforeForceToSPARQL1_0_Mode); learner.start(); timeout = false; } catch (Exception e) { @@ -583,6 +587,7 @@ logger.info("Applying " + algName + " on " + cls + " ... (Attempt " + attempt + ")"); startTime = System.currentTimeMillis(); try { + ((AbstractAxiomLearningAlgorithm)learner).setForceSPARQL_1_0_Mode(attempt > nrOfAttemptsBeforeForceToSPARQL1_0_Mode); learner.start(); timeout = false; } catch (Exception e) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <lor...@us...> - 2012-05-04 01:01:01
|
Revision: 3692 http://dl-learner.svn.sourceforge.net/dl-learner/?rev=3692&view=rev Author: lorenz_b Date: 2012-05-04 01:00:54 +0000 (Fri, 04 May 2012) Log Message: ----------- Reduced delay time. Modified Paths: -------------- trunk/scripts/src/main/java/org/dllearner/scripts/evaluation/EnrichmentEvaluation.java Modified: trunk/scripts/src/main/java/org/dllearner/scripts/evaluation/EnrichmentEvaluation.java =================================================================== --- trunk/scripts/src/main/java/org/dllearner/scripts/evaluation/EnrichmentEvaluation.java 2012-05-03 21:29:31 UTC (rev 3691) +++ trunk/scripts/src/main/java/org/dllearner/scripts/evaluation/EnrichmentEvaluation.java 2012-05-04 01:00:54 UTC (rev 3692) @@ -187,7 +187,7 @@ private final int nrOfAttemptsBeforeForceToSPARQL1_0_Mode = 2; //delay between 2 attempts - private final int delayInMilliseconds = 15000; + private final int delayInMilliseconds = 5000; // max. execution time for each learner for each entity private int maxExecutionTimeInSeconds = 10; @@ -403,7 +403,7 @@ try { ((AbstractAxiomLearningAlgorithm)learner).setForceSPARQL_1_0_Mode(attempt > nrOfAttemptsBeforeForceToSPARQL1_0_Mode); learner.start(); - timeout = false; + timeout = ((AbstractAxiomLearningAlgorithm)learner).isTimeout(); } catch (Exception e) { if(e.getCause() instanceof SocketTimeoutException){ @@ -491,7 +491,7 @@ try { ((AbstractAxiomLearningAlgorithm)learner).setForceSPARQL_1_0_Mode(attempt > nrOfAttemptsBeforeForceToSPARQL1_0_Mode); learner.start(); - timeout = false; + timeout = ((AbstractAxiomLearningAlgorithm)learner).isTimeout(); } catch (Exception e) { if(e.getCause() instanceof SocketTimeoutException){ @@ -589,7 +589,7 @@ try { ((AbstractAxiomLearningAlgorithm)learner).setForceSPARQL_1_0_Mode(attempt > nrOfAttemptsBeforeForceToSPARQL1_0_Mode); learner.start(); - timeout = false; + timeout = ((AbstractAxiomLearningAlgorithm)learner).isTimeout(); } catch (Exception e) { e.printStackTrace(); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |