[Clp] Can't get Clp to shut up

fmargot at andrew.cmu.edu fmargot at andrew.cmu.edu
Sun Oct 28 08:07:21 EDT 2012


> I have a linear programming model
>
> OsiSolverInterface * lp;
>
> which I use as follows:
>
> after the initialSolve, I modify some of the row lower bounds, and then
> resolve.  Since I'm doing this a lot, I want to turn off the messages from
> the solver.
>
> I do
>
> lp->messageHandler()->setLogLevel(0);
>
> just before doing
>
> lp->resolve();
>
> However, the messages are still coming out on stdout!  Why can't I get it
> to shut up?
>
> Victor
>

If you have an OsiClpSolverInterface object, try also

lp->getModelPtr()->messageHandler()->setLogLevel(0);

I don't know if this has changed, but a while back, any call to
lp->initialSolve() was resetting the loglevel to its default value. You
might need to use the above commands after each initialSolve() call.

Francois




More information about the Clp mailing list