[Numpy-discussion] Unexpected float96 precision loss
Wed Sep 1 20:06:14 CDT 2010
On 09/01/10 22:30, Michael Gilbert wrote:
> Interesting. float96( '0.0001' ) also seems to evaluate to the first
> result. I assume that it also does a float64( '0.0001' ) conversion
> first. I understand that you can't change how python passes in floats,
> but wouldn't it be better to exactly handle strings since those can be
> converted exactly, which is what the user wants/expects?
I posted about this a week or two ago as well. Mean meaning to file
bugs, but busy :(
IIRC, the suggestion at the time was I might be able to use something
like C's sscanf to do the string-to-float96 conversion properly. I
haven't yet looked into it further, please let me know if you sort out
any way to do it...
More information about the NumPy-Discussion