My python code is
import os os.environ[\'OCTAVE_EXECUTABLE\'] = "D:\\Octave\\Octave-5.2.0\\mingw64\\bin\\octave-cli.exe" from oct2py import octave oct