You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@spamassassin.apache.org by hs...@apache.org on 2007/04/12 17:51:38 UTC

svn commit: r527994 - /spamassassin/trunk/masses/perceptron.c

Author: hstern
Date: Thu Apr 12 08:51:36 2007
New Revision: 527994

URL: http://svn.apache.org/viewvc?view=rev&rev=527994
Log:
Backing out accidental commit to perceptron.c.  svn commit -m never again

Modified:
    spamassassin/trunk/masses/perceptron.c

Modified: spamassassin/trunk/masses/perceptron.c
URL: http://svn.apache.org/viewvc/spamassassin/trunk/masses/perceptron.c?view=diff&rev=527994&r1=527993&r2=527994
==============================================================================
--- spamassassin/trunk/masses/perceptron.c (original)
+++ spamassassin/trunk/masses/perceptron.c Thu Apr 12 08:51:36 2007
@@ -347,12 +347,12 @@
 /* compute the error gradient for the logsig node with least squares error */
 #ifdef LEAST_SQUARES_ERROR
 			error = is_spam[random_test] - y_out;
-			delta = y_out * (1-y_out) * error / (1+num_mutable) * learning_rate;
+			delta = y_out * (1-y_out) * error / (num_tests_hit[random_test]+1) * learning_rate;
 #else
 /* compute the error gradient for the tanh node with entropic error */
 #ifdef ENTROPIC_ERROR
 			error = (2.0*is_spam[random_test]-1) - y_out;
-			delta = error / (1+num_mutable) * learning_rate;
+			delta = error / (num_tests_hit[random_test]+1) * learning_rate;
 #endif
 #endif