I am using Baron solver with a licence version under AMPL licence for solving a MINLP in Pyomo and Spyder. I use baron in my code as following:
opt=SolverFactory('baron', executable='/home/LocalUser/ampl_linux-intel64/baron')
result=opt.solve(instance, keepfiles=True,tee=True)
but when I run my code, I got this error:
Solver log file: '/tmp/tmpil8__em2.baron.log'
Solver solution file: '/tmp/tmpvphbmoa8.baron.soln'
Solver problem files: ('/tmp/tmpl7sk5uym.pyomo.bar',)
/home/LocalUser/ampl_linux-intel64/baron: can't open /tmp/tmpl7sk5uym.pyomo.bar.nl
ERROR: Solver (baron) returned non-zero return code (1)
ERROR: See the solver log above for diagnostic information.
Traceback (most recent call last):
File "Platform-nonlinear.py", line 236, in <module>
result=opt.solve(instance, keepfiles=True,tee=True)
File "/home/LocalUser/.local/lib/python3.6/site-packages/pyomo/opt/base/solvers.py", line 596, in solve
"Solver (%s) did not exit normally" % self.name)
pyutilib.common._exceptions.ApplicationError: Solver (baron) did not exit normally
I tried it in both windows and linux but I got the same error at both time!!! T really don't know how I can fix it!
