Skip to content

approx_fprime_helper #2

@nilgoyette

Description

@nilgoyette

Hi, I'm trying to port a python project to Rust and I'm using your library as a replacement to scipy.optimize. rustimization seems to be working ok but there's something I don't like. In scipy/optimize/lbfgsb.py, we can find this

    if jac is None:
        def func_and_grad(x):
            f = fun(x, *args)
            g = _approx_fprime_helper(x, fun, epsilon, args=args, f0=f)
            return f, g

which is to say 1) use this if g wasn't provided 2) use the last value of f() when calling g(). Using your library, doing 1) is possible, but it's impossible to do 2). It's quite important if f() is expensive.

I already coded _approx_fprime_helper and I'm pretty sure I can code this myself in your library. My question is more: is this project still alive? Do you accept PR?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions