From: <ku...@us...> - 2008-08-22 15:52:25
|
Revision: 1128 http://dl-learner.svn.sourceforge.net/dl-learner/?rev=1128&view=rev Author: kurzum Date: 2008-08-22 15:52:22 +0000 (Fri, 22 Aug 2008) Log Message: ----------- output is showing accuracy now Modified Paths: -------------- trunk/src/dl-learner/org/dllearner/algorithms/refexamples/ExampleBasedROLearner.java Modified: trunk/src/dl-learner/org/dllearner/algorithms/refexamples/ExampleBasedROLearner.java =================================================================== --- trunk/src/dl-learner/org/dllearner/algorithms/refexamples/ExampleBasedROLearner.java 2008-08-22 13:15:50 UTC (rev 1127) +++ trunk/src/dl-learner/org/dllearner/algorithms/refexamples/ExampleBasedROLearner.java 2008-08-22 15:52:22 UTC (rev 1128) @@ -399,8 +399,10 @@ // we record when a more accurate node is found and log it if (bestNodeStable.getCovPosMinusCovNeg() < candidatesStable.last() .getCovPosMinusCovNeg()) { - String acc = (candidatesStable.last().getAccuracy(nrOfPositiveExamples, nrOfNegativeExamples)+"").substring(2,6); - acc= acc.substring(0,2)+"."+acc.substring(3)+"%"; + String acc = (candidatesStable.last().getAccuracy(nrOfPositiveExamples, nrOfNegativeExamples))+""; + try { acc = acc.substring(2,6); + acc= acc.substring(0,2)+"."+acc.substring(3)+"%";}catch (Exception e) { } + // no handling needed, it will just look ugly in the output logger.info("more accurate ("+acc+") node found: " + candidatesStable.last()); bestNodeStable = candidatesStable.last(); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |