Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Calling Matlab inside a Python fitting function called by Matlab causes a hang #26

Open
mducle opened this issue Jun 19, 2024 · 0 comments
Labels
bug Something isn't working enhancement New feature or request

Comments

@mducle
Copy link
Member

mducle commented Jun 19, 2024

The Matlab computational engine is inherently serial. In the case here we have Python calling a fitting function in Matlab which requires evaluating a Python model function. The Matlab function yields execution to Python but waits until Python finishes; in the mean time, if the Python function then tries to call Matlab, this causes the program to wait until the Matlab fitting function finishes, causing a deadlock.

We should either try to:

  1. Detect if Matlab is being called from a Python function and give an error
  2. Try to implement some kind of two way communications / server client interface in call.m.

Option 1 is likelier to be much easier...

@mducle mducle added bug Something isn't working enhancement New feature or request labels Jun 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant