[Cbc] [CBC] Time limit in Cbc

Mathieu Lacroix lacroix at isima.fr
Tue Aug 25 13:09:56 EDT 2009


John,

Effectively, I am using the mustCallAgain flag.
I have just tested the new version of Cbc and now
the integer solution is not considered as feasible.
Thank you a lot for this update.

Unfortunately, I have still a problem. Before the cut generation at root 
node,
a heuristic is applied and a solution is found. However, Cbc seems to
not take into account this solution since it returns no solution when 
time limit is reached.

My heuristic code seems correct for me. In the method
int usppdp_CbcHeuristic::solution(double & solutionValue, double * 
betterSol),
I update the parameter solutionValue (and betterSol) and the method 
returns 1.
Is there something I misunderstand in the use of the heuristics in Cbc?

Best regards,
Mathieu LACROIX

John J Forrest a écrit :
>
> Mathieu,
>
> It sounds as if the cut generators you are using have "mustCallAgain" 
> flag set so that they go round and round until no cut is generated. - 
> is that so?
>
> I have modified code so eventHappened_ will be set - that seems to 
> skip more stuff and I hope it will do the trick for you (and stop a 
> bit faster).
>
> John
>
> Inactive hide details for Mathieu LACROIX ---08/25/2009 10:25:35 
> AM---John, Thank you for having updated Cbc. The trunk versionMathieu 
> LACROIX ---08/25/2009 10:25:35 AM---John, Thank you for having updated 
> Cbc. The trunk version stops when time
>
>
> From: 	
> Mathieu LACROIX <lacroix at lamsade.dauphine.fr>
>
> To: 	
> John J Forrest/Watson/IBM at IBMUS
>
> Cc: 	
> Mathieu Lacroix <lacroix at isima.fr>, cbc at list.coin-or.org, 
> cbc-bounces at list.coin-or.org
>
> Date: 	
> 08/25/2009 10:25 AM
>
> Subject: 	
> Re: [Cbc] [CBC] Time limit in Cbc
>
> ------------------------------------------------------------------------
>
>
>
> John,
>
> Thank you for having updated Cbc. The trunk version stops when time
> limit is reached. However, there is another problem.
> When the time limit is reached, Cbc stops the cut generation but does
> not check if there exist some violated constraints.
> Therefore, in some cases, the solution obtained by Cbc is integer and
> thus, it is considered as feasible. Unfortunately,
> this is not the case in my problem since I have an exponential number of
> constraints in my formulation.
>
> In order to avoid this problem, another cut generation must be done. If
> any violated constraint is found, thus, the solution
> obtained by Cbc is infeasible, even if it is integer. Is there any
> option to force Cbc to compute another cut generation in order
> to know if the last solution is feasible for the problem?
>
> Thank you for your help,
> Best regards,
> Mathieu
>
> John J Forrest a écrit :
> >
> > Mathieu,
> >
> > Cbc does check time after each round of cuts and a solve. When I
> > played around with a time limit, I found that it was still going into
> > heuristics at root node. This could be the problem, especially as the
> > time limit check in an expensive heuristic (i.e. one that does a small
> > branch and bound) checks the time it has spent against smaller of its
> > time limit and overall time limit. It should be checking total time 
> spent.
> >
> > Will put in a few more checks and fix time check at weekend - see if
> > that helps.
> >
> > Solution etc looks OK to me.
> >
> > John
> >
> > Inactive hide details for Mathieu Lacroix ---08/19/2009 05:43:05
> > AM---Hello everybody, It is possible to give a time limit to CMathieu
> > Lacroix ---08/19/2009 05:43:05 AM---Hello everybody, It is possible to
> > give a time limit to Cbc. However, it seems that cbc
> >
> >
> > From:
> > Mathieu Lacroix <lacroix at isima.fr>
> >
> > To:
> > cbc at list.coin-or.org
> >
> > Date:
> > 08/19/2009 05:43 AM
> >
> > Subject:
> > [Cbc] [CBC] Time limit in Cbc
> >
> > Sent by:
> > cbc-bounces at list.coin-or.org
> >
> > ------------------------------------------------------------------------
> >
> >
> >
> > Hello everybody,
> >
> > It is possible to give a time limit to Cbc. However, it seems that cbc
> > checks whether the time limit is reached only before branching. As in my
> > problem, the time limit is reached before branching (due to cut
> > generation at the root node), is it possible to force cbc to check the
> > time limit after each cut generation? And if the time limit is reached,
> > how to stop cbc without loosing all the informations (upper bound, lower
> > bound and best solution found if any)?
> >
> > Thanks you for any reply,
> > Cheers,
> >
> > Mathieu LACROIX
> >
> > --
> > Mathieu LACROIX
> > lacroix at lamsade.dauphine.fr
> > Laboratoire LAMSADE
> > Université Paris-Dauphine
> > Place du Maréchal de Lattre de Tassigny
> > 75775 Paris cedex 16 - France
> > Tel: +33 (0)1 44 05 48 53
> > URL: http://epoc.isima.fr/~lacroix/ 
> <http://epoc.isima.fr/%7Elacroix/> <http://epoc.isima.fr/%7Elacroix/>
> >
> >
> >
> > _______________________________________________
> > Cbc mailing list
> > Cbc at list.coin-or.org
> > http://list.coin-or.org/mailman/listinfo/cbc
> >
> >
> > ------------------------------------------------------------------------
> >
> > _______________________________________________
> > Cbc mailing list
> > Cbc at list.coin-or.org
> > http://list.coin-or.org/mailman/listinfo/cbc
> >  
>
>
> -- 
> Mathieu LACROIX
> lacroix at lamsade.dauphine.fr
> Laboratoire LAMSADE
> Université Paris-Dauphine
> Place du Maréchal de Lattre de Tassigny
> 75775 Paris cedex 16 - France
> Tel: +33 (0)1 44 05 48 53
> URL: http://epoc.isima.fr/~lacroix/ <http://epoc.isima.fr/%7Elacroix/>
>
>
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Cbc mailing list
> Cbc at list.coin-or.org
> http://list.coin-or.org/mailman/listinfo/cbc
>   


-- 
Mathieu LACROIX
lacroix at lamsade.dauphine.fr
Laboratoire LAMSADE
Université Paris-Dauphine
Place du Maréchal de Lattre de Tassigny
75775 Paris cedex 16 - France
Tel: +33 (0)1 44 05 48 53
URL: http://epoc.isima.fr/~lacroix/





More information about the Cbc mailing list