[ 
https://issues.apache.org/jira/browse/MAHOUT-600?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12988810#comment-12988810
 ] 

Ted Dunning commented on MAHOUT-600:
------------------------------------

I looked at EPSILON, but it is pretty loose.  I wanted a tighter constraint.

My guess is that different architectures have slightly different order of 
operations, but why what would cause an relative error > 10^-16 is not 
something I could guess at off-hand.

I am still dubious of the definition of logNormalize in any case.

> Reported test failure due to exact floating point comparison
> ------------------------------------------------------------
>
>                 Key: MAHOUT-600
>                 URL: https://issues.apache.org/jira/browse/MAHOUT-600
>             Project: Mahout
>          Issue Type: Bug
>            Reporter: Ted Dunning
>             Fix For: 0.5
>
>         Attachments: 
> 0001-MAHOUT-600-Improves-floating-point-comparison-in-log.patch
>
>
> Jeremy Lewi kindly pointed this result from his machine out to us:
> {code}
> Test set: org.apache.mahout.math.VectorTest
> -------------------------------------------------------------------------------
> Tests run: 20, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 0.045 sec 
> <<< FAILURE!
> testLogNormalize(org.apache.mahout.math.VectorTest)  Time elapsed: 0.002 sec  
> <<< FAILURE!
> java.lang.AssertionError: 
> expected:<{2:0.5345224838248488,1:0.4235990463273581,0:0.2672612419124244}> 
> but was:<{2:0.5345224838248488,1:0.423599046327358,0:0.2672612419124244}>
>       at org.junit.Assert.fail(Assert.java:91)
>       at org.junit.Assert.failNotEquals(Assert.java:645)
>       at org.junit.Assert.assertEquals(Assert.java:126)
>       at org.junit.Assert.assertEquals(Assert.java:145)
>       at 
> org.apache.mahout.math.VectorTest.testLogNormalize(VectorTest.java:509)
>       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> {code}
> I have a patch that cleans this up.  Will attach forthwith.

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to