Skip to content

Commit 6cf34e5

Browse files
prima instantiate
1 parent 37d6959 commit 6cf34e5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/OptimizationPRIMA/src/OptimizationPRIMA.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ function Optimization.OptimizationCache(prob::SciMLBase.OptimizationProblem,
3131
throw("We evaluate the jacobian and hessian of the constraints once to automatically detect
3232
linear and nonlinear constraints, please provide a valid AD backend for using COBYLA.")
3333
else
34-
f = Optimization.instantiate_function(prob.f, reinit_cache, prob.f.adtype, num_cons)
34+
f = Optimization.instantiate_function(prob.f, reinit_cache.u0, prob.f.adtype, reinit_cache.p, num_cons)
3535
end
3636

3737
return Optimization.OptimizationCache(f, reinit_cache, prob.lb, prob.ub, prob.lcons,

0 commit comments

Comments
 (0)