Lsqfit

Latest version: v13.2

Safety actively analyzes 619181 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 9

13.2

Adds `lsqfit.vegas_fit.sample` which samples the Bayesian probability distribution used in the fit. This is useful, for example, when making probability density histograms or contour plots of probability densities.

13.1

Adds a second least-squares fitting strategy: ``lsqfit.vegas_fit`` uses ``PDFIntegrator`` from the ``vegas`` Python module to evaluate means, covariances, PDF histograms, etc from Bayesian integrals (as opposed to minimization as in ``lsqfit.nonlinear_fit``).

13.0.4

Minor changes to stay in sync with the ``gvar`` module. Improved documentation on using ``lsqfit`` with the GSL library.

13.0.3

Improved installation code for dealing with old versions of ``numpy``. Support for Python wheels.

13.0.1

Simpler, more modern installation code.

13.0

Introduces improved pickling which means that multiple processors (``nproc>1``) can be used when doing Bayesian integrals with the ``vegas`` module's ``PDFIntegrator`` and the fit's PDF ``fit.pdf(p)``. This is particularly useful when the fit is complicated and ``fit.pdf(p)`` is costly to evaluate.

``fit.pdf(p)`` is now normalized so ``fit.pdf(fit.pmean)`` equals one. This differs from previous versions; to get the old normalization use ``fit.pdf(p)/exp(fit.pdf.lognorm)``. (Note that ``exp(fit.pdf.lognorm)`` can cause overflows for high-dimensional fits.) Also function ``fit.dchi2(p)`` replaces ``fit.evalchi2(p)`` and ``fit.logpdf(p)``, both of which are deprecated.

Function ``empbayes_fit(z0, fitargs, p0)`` has a new keyword ``p0`` which specifies the fit-parameter starting point for the first fit; in subsequent fits ``p0`` is updated automatically to optimize fitting (unless it is specified by ``fitargs``).

New ``setup.py`` forces Cython to rebuild *.c files when using Python 3.11 or later. This addresses incompatibilities introduced by 3.11.

Page 1 of 9

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.