Interactive IPython-friendly Mimizer based on SEAL Minuit.

(It’s included in the package, no need to install it separately.)

It is designed from ground up to be fast, interactive and cython friendly. iminuit extract function signature very permissively starting from checking func_code down to last resort of parsing docstring (or you could tell iminuit to stop looking and take your answer). The interface is inspired heavily by PyMinuit and the status printout is inspired by ROOT Minuit. iminuit is mostly compatible with PyMinuit (with few exceptions). Existing PyMinuit code can be ported to iminuit by just changing the import statement.

In a nutshell:

from iminuit import Minuit
def f(x, y, z):
    return (x - 2) ** 2 + (y - 3) ** 2 + (z - 4) ** 2
m = Minuit(f)
print(m.values)  # {'x': 2,'y': 3,'z': 4}
print(m.errors)  # {'x': 1,'y': 1,'z': 1}

If you are interested in fitting a curve or distribution, take a look at probfit.


All the tutorials are in tutorial directory. You can view them online too: