Open makansij opened 2 years ago
PyROS doesn't properly handle an invalid ipopt.opt
file in the working directory, and instead of spitting out a relevant message, it reports AttributeError: Invalid uncertainty set detected...
.
To reproduce, place an invalid ipopt.op
file in your working directory, and run the example above.
@makansij Running Python 3.9 with the main
branch, I encounter the same exception from my end. I also note that I observe the following error messages through the logger (displayed just before the traceback is printed):
ERROR: Solver (ipopt) returned non-zero return code (155)
ERROR: Solver log: Ipopt 3.13.2: Exception of type: OPTION_INVALID in file
"IpOptionsList.cpp" at line 726:
Exception message: Read Option: "example". It is not a valid option.
Check the list of available options.
ampl_ipopt.cpp: Error in second Initialize!!!!
ERROR: Solver <pyomo.solvers.plugins.solvers.IPOPT.IPOPT object at
0x7f3786fd6130> encountered exception attempting to optimize master
problem in iteration 0
If I run with the Pyomo 6.4.1 release, then the outcome is the same, but the third logging statement does not show, as this logging statement was added after #2515.
Did you encounter a similar series of logger statements, or was only the exception traceback printed to your console?
Summary
I’ve been experimenting with different solvers to see which ones to use under which robust optimizations. So, I started with the example provided under https://pyomo.readthedocs.io/en/stable/contributed_packages/pyros.html#pyros-usage-example. However, I was unable to get the single-stage version of this problem to work with IPOPT. The code in the example uses the
baron
solver. However, since there don’t seem to be any integral uncertain parameters, nor integral variables, this problem should be solvable by a non-linear solver, e.g. IPOPT. I tried this example with IPOPT and got the following error:Steps to reproduce the issue
Error Message
Here's the error message:
Information on your system
Pyomo version: 6.4.1 Python version: 3.9 Operating system: MacOS Monterey Solver (if applicable): IPOPT
Additional information
Is this the expected behavior? Or am I failing to see how the problem exceeds the capabilities of a non-linear solver such as IPOPT?