[Numpy-discussion] could anyone check on a 32bit system?

Nathaniel Smith njs at pobox.com
Wed May 1 09:54:56 EDT 2013


On Wed, May 1, 2013 at 9:12 AM, Pauli Virtanen <pav at iki.fi> wrote:
> 01.05.2013 16:01, Yaroslav Halchenko kirjoitti:
> [clip]
>> to ignorant me, even without considering 'correctness', it is just
>> a typical regression -- results changed from one release to another (and
>> not to the better side).
>
> To me this seems to be a consequence of performing additions in a
> different order than previously. Both results are IMHO correct, so I'm
> not sure there is anything to fix here. Third-party code relying on a
> certain outcome of rounding error is likely incorrect anyway.

Yeah, seems to just be the standard floating point indeterminism.
Using Matthew's numbers and pure Python floats:

In [9]: (0.49505185 + 0.53529587) + -0.13461665
Out[9]: 0.89573107

In [10]: 0.49505185 + (0.53529587 + -0.13461665)
Out[10]: 0.8957310700000001

In [11]: _9 - _10
Out[11]: -1.1102230246251565e-16

Looks like a bug in pymvpa or its test suite to me.

-n



More information about the NumPy-Discussion mailing list