Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Solver doesn't terminate with defined time limit #79

Open
amininilooffar opened this issue Jul 23, 2024 · 2 comments
Open

Solver doesn't terminate with defined time limit #79

amininilooffar opened this issue Jul 23, 2024 · 2 comments

Comments

@amininilooffar
Copy link

Hi, Thanks for the code provided for Google Colab.
I am trying to solve my MINLP problem using 'couenne'. It takes a long time until it gives me the result; however, I want it to stop computations after a defined time frame. I tried this code: from pyomo.opt import SolverFactory, SolverManagerFactory
solver = SolverFactory('couenne')
solver_manager = SolverManagerFactory('serial')
results = solver_manager.solve(model, opt=solver, tee=True, timelimit=600)
But I face an error: 'TimeoutExpired: Command '['/content/bin/couenne', '/tmp/tmp4ceh948b.pyomo.nl', '-AMPL']' timed out after 600.99996879700029 seconds' without having any results.
Could you please help me in this regard?
Thanks,
Niloofar

@tkralphs
Copy link
Member

tkralphs commented Aug 1, 2024

It looks like the solver correctly timed out. What kind of a result you are looking for? When the solver times out, it may indeed not have a solution or be able to provide much information. You could ask the Pyomo folks how to see the raw output from Couenne and then you could see exactly what it outputs when it times out. I suspect there just isn't any solution information available.

@tkralphs
Copy link
Member

tkralphs commented Aug 1, 2024

Could you change the title of this issue to be more accurate? It doesn't seem to be true that the solver doesn't terminate. It say in the output "timed out in 600 seconds."

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants