[Fwd: [Cops] How to stop ALPS searching as soon as a solution found]

Yan Xu Yan.Xu at sas.com
Tue Dec 4 11:39:19 EST 2007


There is a parameter "solLimit" in AlpsParams.h that should be used to stop searching when reacing solution limit. However, it hasn't been fully implemented in ALPS yet.

For sequential code, I can make it work soon.

For parallel code, it need a bit work since we need make sure we clean up everything on every processes before leave. But, I can first make the option works after rampup. So during rampup, if the search finds a solution, it won't exit, but once the rampup complete, the search check whether it reachs solution limit. If yes, the search exit. If you are using "spiral initialization", rampup phase generally completes quickly.

By the way, there are other two parameters "timeLimit" and "nodeLimit", which works in serial and parallel (after rampup phase).

I will let you know when I'm done.

Best,
Yan




-------- Original Message --------
Subject:        [Cops] How to stop ALPS searching as soon as a solution found
Date:   Tue, 4 Dec 2007 13:27:37 +0100
From:   Khoa Vo <khoa.vo at informatik.uni-heidelberg.de>
To:     <cops at list.coin-or.org>



Dear all,



I am using ALPS framework (version 0.95) in COPS family to parallelize my computing program for a discrete optimization problem (Matrix Bandwidth optimization). It looks to be a well architected and robust framework.



Due to the difficulty of Bandwidth problem, in the current program I test for each of input bandwidth value if there is any feasible solution for that. If yes, then it is the necessary solution and searching should be stopped. Otherwise searching continues until the full tree has been tested and an answer of Infeasibility will be returned. In other words, I want the search to stop when a solution found, not until all nodes have been pruned, both sequentially and parallelly.



Can you tell me how to configure/program such a message/event? In the current program, in function BwTreeNode::process(bool isRoot, bool rampUp), where class BwTreeNode inherited from class AlpsTreeNode, when a solution found I try to using

-sending a message with ALPS_S_FINAL_SOL

-getKnowledgeBroker()->setExitStatus(AlpsExitStatusOptimal);

But that didn't help, the search keeps running until all nodes have been pruned.



Any hint, advice or solution will be welcomed.

Thanks,

Khoa Vo

Institute of Computer Science

University of Heidelberg

Im Neuenheimer Feld 368

69120 Heidelberg

Germany

Email: khoa.vo at informatik.uni-heidelberg.de
<mailto:khoa.vo at informatik.uni-heidelberg.de>

Phone: 49-6221-545743


--
Dr. Ted Ralphs
Associate Professor
Industrial and Systems Engineering
Lehigh University
(610)758-4784
ted at lehigh dot edu
www.lehigh.edu/~tkr2




More information about the Cops mailing list