Skip to content

Releases: lmfit/uncertainties

Massive speedup for calculations involving many numbers with uncertainties

15 Aug 20:56
Compare
Choose a tag to compare

A calculation like str(sum(ufloat(1, 1) for _ in xrange(100000))) is now about 5,000 faster than with the latest release (version 2.4.8.1).

More generally, the calculation time of such sums (and more generally of complex expressions involving many numbers with uncertainty) is now linear instead of quadratic, and much faster in absolute time.

This closes issue #30.

Version 2.4.7.1: the printing and formatting of ±inf±… now works.

16 Jan 22:58
Compare
Choose a tag to compare

±inf±… can now be printed and formatted.

This is consistent with the fact that such numbers with uncertainty can be created with uncertainties.ufloat().

This makes it easier to handle calculation that work with floats despite involving infinities.

Install fix

14 Aug 06:18
Compare
Choose a tag to compare

"python3 setup.py install" failed when setuptools was not installed. This is now fixed (by running 2to3 in setup.py when setuptools is not available, since distutils does not do it automatically).

Version 2.4.6: printing and empty/None formatting closer to Python's own

10 Apr 13:13
Compare
Choose a tag to compare

The string and empty format type formatting of numbers with uncertainties are now similar to what Python 3.4 does (https://docs.python.org/3.4/library/string.html#format-specification-mini-language).

The previous behavior was based on the Python 2.7 documentation, which is probably incorrect (http://stackoverflow.com/questions/16525924/precise-definition-of-float-string-formatting).

Version 2.4.5: support for NaN±… formatting

09 Apr 10:11
Compare
Choose a tag to compare

Numbers like NaN±… can now be formatted.

Exception now raised for negative standard deviations

07 Dec 10:36
Compare
Choose a tag to compare

An exception is now raised for negative standard deviations. This fixes a regression probably introduced by version 2.

2.4.2: workaround for NumPy 1.8.0 new mean() behavior

19 Nov 14:46
Compare
Choose a tag to compare

Workaround for NumPy 1.8.0 new mean() behavior, which made uncertainties fail when calculating the mean of an array with numbers with uncertainties.

Reference: numpy/numpy#4063

Version 2.4.1

26 Jul 07:46
Compare
Choose a tag to compare

The uncertainties.umath functions ceil(), floor(), isinf(), isnan() and trunc() now return values of the same type as their corresponding function in the math module.

In previous versions, they generally returned values with a zero uncertainty (…±0), which was not useful, since the results of these functions are integers (float or int type) or booleans. It is less surprising to obtain the same types as in the math module.

Python Package Index release 2.4. Added extensive support for formatting.

18 Jul 08:09
Compare
Choose a tag to compare

This version adds extensive support for formatting, including automatic and user-defined control of the uncertainty format, and pretty-printing and LaTeX formatting.