You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mahout.apache.org by "Jake Mannix (JIRA)" <ji...@apache.org> on 2010/01/28 07:14:34 UTC
[jira] Resolved: (MAHOUT-268) Vector.getDistanceSquared() is
incorrect for both SparseVector varieties
[ https://issues.apache.org/jira/browse/MAHOUT-268?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jake Mannix resolved MAHOUT-268.
--------------------------------
Resolution: Fixed
fixed in r903965
> Vector.getDistanceSquared() is incorrect for both SparseVector varieties
> ------------------------------------------------------------------------
>
> Key: MAHOUT-268
> URL: https://issues.apache.org/jira/browse/MAHOUT-268
> Project: Mahout
> Issue Type: Bug
> Affects Versions: 0.2
> Environment: all
> Reporter: NOT_A_USER
> Assignee: Jake Mannix
> Fix For: 0.3
>
>
> I'm pretty sure that getDistanceSquared() should just return as if an optimized implementation of:
> {code}
> public double getDistanceSquared(Vector v) { return this.minus(v).getLengthSquared(); }
> {code}
> In which case if some vector elements are negative, both SequentialAccessSparseVector (my fault!) and RandomAccessSparseVector return the wrong thing. Very easy to write a failing unit test for this one.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.