NLopt.jl icon indicating copy to clipboard operation
NLopt.jl copied to clipboard

from direct to stogo -> NLOPT_INVALID_ARGS

Open UnixJunkie opened this issue 2 years ago • 4 comments

If I switch from direct to stogo for global optimization, I get this error. With direct, the optimization is going on (but I guess it would work way better if I exploit the gradient, hence the trial switch to stogo).

UnixJunkie avatar Jul 07 '23 03:07 UnixJunkie

Do you have a reproducible example? I don't fully understand what you mean.

odow avatar Jan 15 '24 03:01 odow

No, I don't have a minimal example (way too much work to get one). I have a problem where direct works; if I change the algorithm from direct to stogo, I get this error.

UnixJunkie avatar Jan 15 '24 03:01 UnixJunkie

Do you have constraints? stogo does not support constraints other than bound constraints.

odow avatar Jan 15 '24 04:01 odow

I only have bound constraints.

On Mon, Jan 15, 2024 at 1:19 PM Oscar Dowson @.***> wrote:

Do you have constraints? stogo does not support constraints other than bound constraints.

— Reply to this email directly, view it on GitHub https://github.com/JuliaOpt/NLopt.jl/issues/200#issuecomment-1891277849, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAFUFAGLCCC622PZB5QY4BDYOSU43AVCNFSM6AAAAAA2BHYZ3OVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQOJRGI3TOOBUHE . You are receiving this because you authored the thread.Message ID: @.***>

UnixJunkie avatar Jan 15 '24 04:01 UnixJunkie

From the documentation: https://nlopt.readthedocs.io/en/latest/NLopt_Reference/#error-codes-negative-return-values

NLOPT_INVALID_ARGS happens because "Invalid arguments (e.g. lower bounds are bigger than upper bounds, an unknown algorithm was specified, etcetera)."

It's impossible to say what the problem is without a reproducible example, so I'm going to close this issue. If you're still experiencing an issue and you have a reproducible example, please comment below and I will reopen the issue.

odow avatar Aug 16 '24 03:08 odow