You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, after I updated Octave from 6.4 to 7.2 I get an error while trying to call function:
octave.in_data_gen(a, 'A.txt', L, N)
Output:
File "/home/vm/.local/lib/python3.11/site-packages/oct2py/dynamic.py", line 103, in __call__
return self._ref().feval(self.name, *inputs, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/vm/.local/lib/python3.11/site-packages/oct2py/core.py", line 392, in feval
return self._feval(func_name, func_args, dname=dname, nout=nout,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/vm/.local/lib/python3.11/site-packages/oct2py/core.py", line 595, in _feval
raise Oct2PyError(msg)
oct2py.utils.Oct2PyError: Octave evaluation error:
error: in_data_gen: function called with too many outputs
error: called from:
in_data_gen at line -1, column -1
The function was working fine before the update and is working fine when being used in Octave directly. Function is very simple, doesn't return anything; only does some type cating and writes a txt file.
I've done some more testing and the problem only occurs when the function matlab function called by oct2py does not return any value. When the same function is modified to return some value everything works fine.
The text was updated successfully, but these errors were encountered:
mludwini
changed the title
Problem with
Problem with calling function; too many outputs
Nov 16, 2022
Ok, I've been able to fix the issue by adding an additional argument when calling function nout=0. Presumably I should have thought about it earlier. Sorry for making fuss. Hope that this will help anyone migrating their code to newer version of octave.
Hi, after I updated Octave from 6.4 to 7.2 I get an error while trying to call function:
octave.in_data_gen(a, 'A.txt', L, N)
Output:
The function was working fine before the update and is working fine when being used in Octave directly. Function is very simple, doesn't return anything; only does some type cating and writes a txt file.
I've done some more testing and the problem only occurs when the function matlab function called by oct2py does not return any value. When the same function is modified to return some value everything works fine.
The text was updated successfully, but these errors were encountered: