Error Of Running An Executable File From Python Subprosess
I am trying to run an executable file (a linear programming solver CLP.exe) from Python 3.5. Import subprocess exeFile = ' C:\\MyPath\\CLP.exe' arg1 = 'C:\\Temp\\LpModel.mps'
Solution 1:
Every space separated token needs to be another argument in the array for subprocess.check_output
exeFile = " C:\\MyPath\\CLP.exe"
subprocess.check_output([
exeFile,
"C:\\Temp\\LpModel.mps",
"-max",
"-dualSimplex",
"-printi",
"all",
"-solution",
"t",
"solutionFile.txt"],
stderr=subprocess.STDOUT,
shell=False)
Post a Comment for "Error Of Running An Executable File From Python Subprosess"