JuliaSmoothOptimizers / OptimizationProblems.jl

Optimization Problems for Julia
Other
88 stars 48 forks source link

Fix `hs61` test #334

Closed tmigot closed 4 months ago

tmigot commented 4 months ago

Close #72 Need https://github.com/JuliaSmoothOptimizers/NLPModelsJuMP.jl/pull/181

amontoison commented 4 months ago

I already updated hs61 a few weeks ago. https://github.com/JuliaSmoothOptimizers/OptimizationProblems.jl/commit/f01b2918506e520caa0e4f54095da37fa6d8c4b8

tmigot commented 4 months ago

Ok, but the issue remains because we also need to replace @NLconstraint by @constraint ...

amontoison commented 4 months ago

We need to do that only if we want to switch to the new API. It's related to the PR #321.

tmigot commented 4 months ago

Yes and no, using @constraint for quadratic constraint is possibly a better modeling, the fact that use @NLconstraint was a hack. I don't think this is particularly connected to the new API. Thanks to the great work in NLPModelsJuMP we will be able to update quadratic constraints, that was the point of this. Also this PR was a draft, there was no need to merge it.

amontoison commented 4 months ago

@NLconstraint was mandatory for quadratic constraints before MOI, it was not a hack. JuMP just added support for it later and us now.

The new API is now doing the same thing but for all nonlinear constraints /objective.

I merged the PR becasue we can test hs61 in all cases now, even with the old API.