Module Lbfgs.Make

Parameters

Signature

type fv = AD.t
type prm = AD.t
type prms = prm P.t
type f = Base.int -> prms -> fv
type adt =
| S
| M
type info = (Base.int * Base.int * Base.int Base.array * adt) P.t
val build_info : prms -> Base.int * info
val extract : (int * int * int array * adt) P.t -> (Base.float, Stdlib.Bigarray.float64_elt, Stdlib.Bigarray.c_layout) Stdlib.Bigarray.Array1.t -> AD.t P.t
val blit : ('a -> AD.t) -> (int * int * int array * 'b) P.t -> 'a P.t -> (Base.float, Stdlib.Bigarray.float64_elt, Stdlib.Bigarray.c_layout) Stdlib.Bigarray.Array1.t -> unit
type state = {
mutable fv_hist : Base.float Base.list;
mutable k : Base.int;
work : Owl_opt_lbfgs__.Bindings.work;
ps : (Base.float, Stdlib.Bigarray.float64_elt, Stdlib.Bigarray.c_layout) Stdlib.Bigarray.Array1.t;
n_prms : Base.int;
info : info;
}
type status =
| Stop of Base.float
| Continue of Base.float
type stop = Base.float -> state -> Base.bool
val iter : state -> Base.int
val prev_fv : state -> Base.float
val fv_hist : state -> Base.float Base.List.t
val prms : state -> AD.t P.t
val init : ?⁠corrections:int -> prms0:prms -> unit -> state
val f_df : f:(Base.int -> AD.t P.t -> AD.t) -> state -> (Base.float, Stdlib.Bigarray.float64_elt, Stdlib.Bigarray.c_layout) Stdlib.Bigarray.Array1.t -> (Base.float, Stdlib.Bigarray.float64_elt, Stdlib.Bigarray.c_layout) Stdlib.Bigarray.Array1.t -> float
val stop : Base.Float.t -> state -> bool
val step : (pgtol:float -> factr:float -> work:Owl_opt_lbfgs__.Bindings.work -> ((Base.float, Stdlib.Bigarray.float64_elt, Stdlib.Bigarray.c_layout) Stdlib.Bigarray.Array1.t -> (Base.float, Stdlib.Bigarray.float64_elt, Stdlib.Bigarray.c_layout) Stdlib.Bigarray.Array1.t -> float) -> (Base.float, Stdlib.Bigarray.float64_elt, Stdlib.Bigarray.c_layout) Stdlib.Bigarray.Array1.t -> 'a -> Owl_opt_lbfgs__.Bindings.lbfgs_status) -> ?⁠pgtol:float -> ?⁠factr:float -> ?⁠stop:(Base.Float.t -> state -> bool) -> f:(Base.int -> AD.t P.t -> AD.t) -> state -> 'a -> status
val lmin : pgtol:float -> factr:float -> work:Owl_opt_lbfgs__.Bindings.work -> (Owl_opt_lbfgs__.Bindings.vec -> Owl_opt_lbfgs__.Bindings.vec -> float) -> Owl_opt_lbfgs__.Bindings.vec -> Owl_opt_lbfgs__.Bindings.vec -> Owl_opt_lbfgs__.Bindings.lbfgs_status
val lmax : pgtol:float -> factr:float -> work:Owl_opt_lbfgs__.Bindings.work -> (Owl_opt_lbfgs__.Bindings.vec -> Owl_opt_lbfgs__.Bindings.vec -> float) -> Owl_opt_lbfgs__.Bindings.vec -> Owl_opt_lbfgs__.Bindings.vec -> Owl_opt_lbfgs__.Bindings.lbfgs_status
val optimise : (pgtol:float -> factr:float -> work:Owl_opt_lbfgs__.Bindings.work -> ((Base.float, Stdlib.Bigarray.float64_elt, Stdlib.Bigarray.c_layout) Stdlib.Bigarray.Array1.t -> (Base.float, Stdlib.Bigarray.float64_elt, Stdlib.Bigarray.c_layout) Stdlib.Bigarray.Array1.t -> float) -> (Base.float, Stdlib.Bigarray.float64_elt, Stdlib.Bigarray.c_layout) Stdlib.Bigarray.Array1.t -> (float, Stdlib.Bigarray.float64_elt, Stdlib.Bigarray.c_layout) Stdlib.Bigarray.Array1.t -> Owl_opt_lbfgs__.Bindings.lbfgs_status) -> ?⁠pgtol:float -> ?⁠factr:float -> ?⁠stop:(Base.Float.t -> state -> bool) -> f:(Base.int -> AD.t P.t -> AD.t) -> state -> Base.float
val min : ?⁠pgtol:float -> ?⁠factr:float -> ?⁠stop:(Base.Float.t -> state -> bool) -> f:(Base.int -> AD.t P.t -> AD.t) -> state -> Base.float
val max : ?⁠pgtol:float -> ?⁠factr:float -> ?⁠stop:(Base.Float.t -> state -> bool) -> f:(Base.int -> AD.t P.t -> AD.t) -> state -> Base.float