jump-dev / HiGHS.jl

A Julia interface to the HiGHS solver
https://highs.dev
MIT License
108 stars 15 forks source link

Problem with running HiGHS with "run_crossover" #145

Closed sambuddhac closed 1 year ago

sambuddhac commented 1 year ago

I am trying to run optimization model in JuMP with the HiGHS interface where my run_crossover is set to "false." I am getting the following error:

ERROR: LoadError: MathOptInterface.SetAttributeNotAllowed{MathOptInterface.RawOptimizerAttribute}: Setting attribute MathOptInterface.RawOptimizerAttribute("run_crossover") cannot be performed: 

Invalid value `false::Bool` for option "run_crossover".

 You may want to use a `CachingOptimizer` in `AUTOMATIC` mode or you may need to call `reset_optimizer` before doing this operation if the `CachingOptimizer` is in `MANUAL` mode.

Can you please help me out?

blegat commented 1 year ago

With https://github.com/jump-dev/HiGHS.jl/pull/146, the error is now:

Invalid value `true::Bool` for option "run_crossover", expected `String`.

The options is specified with a String, not a Bool, from the HiGHS documentation:

Run crossover after IPM: "on" by default - "choose"/"off" are alternatives.

So you should use "off" instead of false.

sambuddhac commented 1 year ago

@blegat thanks a lot !!! This indeed resolved my issue.