Receive error: matlab.eng​ine.Matlab​ExecutionE​rror: Too many output arguments.

3 Ansichten (letzte 30 Tage)
Dear all,
I'm trying to create a simulink model using a python script. after many tries i get the error shown in the picture.
Explicitly setting nargout=0 for all non-output MATLAB calls in the script already did. Example:
or
Could you give me suggestions on what else I could try to fix the errors?
Thank you very much!

Akzeptierte Antwort

Hitesh
Hitesh am 4 Jan. 2025
Bearbeitet: Hitesh am 4 Jan. 2025
I too encountered this error, the workaround that worked for me was to reinstall the "matlabengine" module. Kindly ensure that you need to run following command in this directory "matlabroot\extern\engines\python".
pip install matlabengine
I have revised and executed your script without any errors. I have saved the model and attached it for your reference.Kindly refer to the below image for the revised script.
For more information regarding "ModuleNotFoundError: No module named 'matlabeng​ineforpyth​on3_X' ", kindly refer to the following MATLAB Answer:

Weitere Antworten (0)

Kategorien

Mehr zu Integration with Online Platforms finden Sie in Help Center und File Exchange

Produkte


Version

R2024b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by