From: <jen...@us...> - 2008-07-07 08:50:19
|
Revision: 1004 http://dl-learner.svn.sourceforge.net/dl-learner/?rev=1004&view=rev Author: jenslehmann Date: 2008-07-07 01:50:10 -0700 (Mon, 07 Jul 2008) Log Message: ----------- - small test Modified Paths: -------------- trunk/src/dl-learner/org/dllearner/core/EvaluatedDescription.java trunk/src/dl-learner/org/dllearner/test/ComponentTest.java trunk/src/dl-learner/org/dllearner/tools/protege/ActionHandler.java Modified: trunk/src/dl-learner/org/dllearner/core/EvaluatedDescription.java =================================================================== --- trunk/src/dl-learner/org/dllearner/core/EvaluatedDescription.java 2008-07-06 19:54:28 UTC (rev 1003) +++ trunk/src/dl-learner/org/dllearner/core/EvaluatedDescription.java 2008-07-07 08:50:10 UTC (rev 1004) @@ -168,6 +168,11 @@ } } + @Override + public String toString() { + return description.toString() + "(accuracy: " + getAccuracy() + ")"; + } + // we need to use this method instead of the standard JSON array constructor, // otherwise we'll get unexpected results (JSONArray does not take Individuals // as arguments and does not use toString) Modified: trunk/src/dl-learner/org/dllearner/test/ComponentTest.java =================================================================== --- trunk/src/dl-learner/org/dllearner/test/ComponentTest.java 2008-07-06 19:54:28 UTC (rev 1003) +++ trunk/src/dl-learner/org/dllearner/test/ComponentTest.java 2008-07-07 08:50:10 UTC (rev 1004) @@ -23,7 +23,7 @@ import java.util.Set; import java.util.TreeSet; -import org.dllearner.algorithms.DBpediaNavigationSuggestor; +import org.dllearner.algorithms.refexamples.ExampleBasedROLComponent; import org.dllearner.core.ComponentInitException; import org.dllearner.core.ComponentManager; import org.dllearner.core.KnowledgeSource; @@ -83,7 +83,7 @@ // create the learning algorithm LearningAlgorithm la = null; try { - la = cm.learningAlgorithm(DBpediaNavigationSuggestor.class, lp, rs); + la = cm.learningAlgorithm(ExampleBasedROLComponent.class, lp, rs); } catch (LearningProblemUnsupportedException e) { // TODO Auto-generated catch block e.printStackTrace(); @@ -95,7 +95,7 @@ // start the algorithm and print the best concept found la.start(); - System.out.println(la.getCurrentlyBestEvaluatedDescription()); + System.out.println(la.getCurrentlyBestEvaluatedDescriptions()); } } Modified: trunk/src/dl-learner/org/dllearner/tools/protege/ActionHandler.java =================================================================== --- trunk/src/dl-learner/org/dllearner/tools/protege/ActionHandler.java 2008-07-06 19:54:28 UTC (rev 1003) +++ trunk/src/dl-learner/org/dllearner/tools/protege/ActionHandler.java 2008-07-07 08:50:10 UTC (rev 1004) @@ -9,8 +9,6 @@ import javax.swing.event.ListSelectionListener; import javax.swing.event.ListSelectionEvent; -import javax.swing.JDialog; - import org.dllearner.core.owl.Description; /** * @@ -39,7 +37,7 @@ * This is the view of the DL-Learner tab. */ private OWLClassDescriptionEditorWithDLLearnerTab.DLLearnerView view; - private JDialog detailDialog; +// private JDialog detailDialog; /** * This is the constructor for the action handler * @param a ActionHandler This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |