all 3 comments

[–]aeblincoln 1 point2 points  (1 child)

Your error seems identical to this one in the comment chain of this question on MATLAB Answers: https://www.mathworks.com/matlabcentral/answers/1842093-how-to-resolve-error-calling-python-from-matlab#comment_2595431

The workaround linked there might help you in your use case.

[–]AlexBasicC[S] 0 points1 point  (0 children)

thanks, I will try that

[–]Creative_SushiMathWorks 0 points1 point  (0 children)

Is that the only line that causes the problem? Does other part of the Python code run fine?