[gecode-users] Passing option -time to fzn-gecode

Guido Tack tack at gecode.org
Mon Sep 15 12:47:41 CEST 2014


Hi,

if you are calling mzn-gecode, you have to pass the time option on to the fzn-gecode executable, like this:

mzn-gecode --fzn-flags "-time 2000" --all-solutions problem.mzn

Cheers,
Guido

-- 
Guido Tack
http://www.csse.monash.edu/~guidot/



On 8 Sep 2014, at 6:05 pm, Max Myer <max.61 at aim.com> wrote:

> I'm trying to run a few minizinc examples by calling 
> 
> $ mzn-gecode --all-solutions problem.mzn
> 
> I'd like to terminate the solve process after a specified amount of time. I found the argument "-time" in fzn-gecode (--help), but am unsure how to pass it to fzn-gecode.
> 
> Adding "-time" to the mzn-gecode call results in the general fzn-gecode help output. Perhaps this is due to this part in fzn-gecode.cpp:
> 
> ...
> int main(int argc, char** argv) {
>   Support::Timer t_total;
>   t_total.start();
>   FlatZinc::FlatZincOptions opt("Gecode/FlatZinc");
>   opt.parse(argc, argv);
>   
>   if (argc!=2) {
>     cerr << "Usage: " << argv[0] << " [options] <file>" << endl;
>     cerr << "       " << argv[0] << " -help for more information" << endl;
>     exit(EXIT_FAILURE); 
>   } 
>   ...
> 
> Anyway, I'd appreciate some help on this.
> 
> Cheers,
> Max
> _______________________________________________
> Gecode users mailing list
> users at gecode.org
> https://www.gecode.org/mailman/listinfo/gecode-users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.gecode.org/pipermail/users/attachments/20140915/c47e39e0/attachment.html>


More information about the users mailing list