Skip to content

Commit

Permalink
Allow for Options in Fminbox (#623)
Browse files Browse the repository at this point in the history
  • Loading branch information
pkofod committed Jun 18, 2018
1 parent 5025644 commit e60e13a
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/multivariate/solvers/constrained/fminbox.jl
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,8 @@ function optimize(f,
l::AbstractArray{T},
u::AbstractArray{T},
initial_x::AbstractArray{T},
F::Fminbox = Fminbox(); inplace = true, autodiff = :finite) where T<:AbstractFloat
F::Fminbox = Fminbox(),
options = Options(); inplace = true, autodiff = :finite) where T<:AbstractFloat

g! = inplace ? g : (G, x) -> copy!(G, g(x))
od = OnceDifferentiable(f, g!, initial_x, zero(T))
Expand All @@ -146,7 +147,8 @@ function optimize(f,
l::AbstractArray{T},
u::AbstractArray{T},
initial_x::AbstractArray{T},
F::Fminbox = Fminbox(); inplace = true, autodiff = :finite) where T<:AbstractFloat
F::Fminbox = Fminbox(),
options = Options(); inplace = true, autodiff = :finite) where T<:AbstractFloat

od = OnceDifferentiable(f, initial_x, zero(T); autodiff = autodiff)
optimize(od, l, u, initial_x, F)
Expand Down

0 comments on commit e60e13a

Please sign in to comment.