简体   繁体   English

Scip:缺少最大时间选项?

[英]Scip: Maximum time option missing?

I'm using a software based on SCIP (3.0.1). 我正在使用基于SCIP(3.0.1)的软件。 I have a bunch of experiments to execute, and for that I'd like to simply enforce a maximum execution time for SCIP: if you haven't already found the best solution, after x seconds outputs anyway the best solution found so far. 我有大量实验要执行,为此,我想简单地为SCIP强制执行最长执行时间:如果您尚未找到最佳解决方案,则在x秒后仍会输出到目前为止找到的最佳解决方案。

Right now I'm doing using a script that sends to the bound PID process the sigint interrupt after the desired time, but it isn't working all the time. 现在,我正在使用一个脚本,该脚本会在所需的时间后将sigint中断发送到绑定的PID进程,但它并不能一直工作。 I'd like to properly code this with SCIP. 我想用SCIP正确编码。 Simply as it may sound, I couldn't find a relevant option for doing that. 听起来很简单,我找不到执行此操作的相关选项。

Do you have any idea? 你有什么主意吗?

Kind regards for your time. 谢谢您的时间。

There is a time limit parameter for setting a solving time in seconds: 有一个时间限制参数,用于设置以秒为单位的求解时间:

SCIPsetRealParam(scip, "limits/time", 600)

sets this limit to 10 minutes. 将此限制设置为10分钟。

A list of all parameters is found in the SCIP documentation . SCIP文档中可以找到所有参数的列表。

You can do that also via settings. 您也可以通过设置来做到这一点。 Either in the interactive shell: 在交互式外壳中:

set limits time <your_timelimit>

or in a settings file, that you read in before solving: 或在解决之前阅读的设置文件中:

limits/time = <your_timelimit>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM