You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by er...@apache.org on 2015/08/13 23:25:27 UTC

[math] MATH-1255

Repository: commons-math
Updated Branches:
  refs/heads/MATH_3_X fcd49fc8f -> 5c3988cb0


MATH-1255

Wrong usage of "Gaussian" function.


Project: http://git-wip-us.apache.org/repos/asf/commons-math/repo
Commit: http://git-wip-us.apache.org/repos/asf/commons-math/commit/5c3988cb
Tree: http://git-wip-us.apache.org/repos/asf/commons-math/tree/5c3988cb
Diff: http://git-wip-us.apache.org/repos/asf/commons-math/diff/5c3988cb

Branch: refs/heads/MATH_3_X
Commit: 5c3988cb0414bb013464f8a12741fde37546cde3
Parents: fcd49fc
Author: Gilles <er...@apache.org>
Authored: Thu Aug 13 23:18:21 2015 +0200
Committer: Gilles <er...@apache.org>
Committed: Thu Aug 13 23:18:21 2015 +0200

----------------------------------------------------------------------
 src/changes/changes.xml                                           | 3 +++
 .../commons/math3/ml/neuralnet/sofm/KohonenUpdateAction.java      | 2 +-
 2 files changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/commons-math/blob/5c3988cb/src/changes/changes.xml
----------------------------------------------------------------------
diff --git a/src/changes/changes.xml b/src/changes/changes.xml
index 03cfec2..4b81140 100644
--- a/src/changes/changes.xml
+++ b/src/changes/changes.xml
@@ -51,6 +51,9 @@ If the output is not quite correct, check for invisible trailing spaces!
   </properties>
   <body>
     <release version="3.6" date="XXXX-XX-XX" description="">
+      <action dev="erans" type="fix" issue="MATH-1255">
+        Wrong neighbourhood size in class "KohonenUpdateAction" (package "o.a.c.m.ml.neuralnet.sofm").
+      </action>
       <action dev="psteitz" type="fix" issue="MATH-1252" due-to="John Bay">
         ResizableDoubleArray constructor does not work with double array of size 1.
       </action>

http://git-wip-us.apache.org/repos/asf/commons-math/blob/5c3988cb/src/main/java/org/apache/commons/math3/ml/neuralnet/sofm/KohonenUpdateAction.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/math3/ml/neuralnet/sofm/KohonenUpdateAction.java b/src/main/java/org/apache/commons/math3/ml/neuralnet/sofm/KohonenUpdateAction.java
index 9fa72ce..fb3ec4d 100644
--- a/src/main/java/org/apache/commons/math3/ml/neuralnet/sofm/KohonenUpdateAction.java
+++ b/src/main/java/org/apache/commons/math3/ml/neuralnet/sofm/KohonenUpdateAction.java
@@ -107,7 +107,7 @@ public class KohonenUpdateAction implements UpdateAction {
         final Gaussian neighbourhoodDecay
             = new Gaussian(currentLearning,
                            0,
-                           1d / currentNeighbourhood);
+                           currentNeighbourhood);
 
         if (currentNeighbourhood > 0) {
             // Initial set of neurons only contains the winning neuron.