-
Notifications
You must be signed in to change notification settings - Fork 65
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
Dropping GIL when calling Julia from Python (JuliaCall) #343
Comments
Repeating what I said in #108
Specifically, you can release the GIL yourself in the Julia code you call like: pythread = PythonCall.C.PyEval_SaveThread()
try
# code which doesn't touch Python
finally
PythonCall.C.PyEval_RestoreThread(pythread)
end |
This issue has been marked as stale because it has been open for 30 days with no activity. If the issue is still relevant then please leave a comment, or else it will be closed in 7 days. |
In case relevant, new in 3.12rc1: https://peps.python.org/pep-0684/ https://docs.python.org/3.12/whatsnew/3.12.html#pep-684-a-per-interpreter-gil
New release candidate 2 expected 2023-09-04 then
See also new in 3.13: https://peps.python.org/pep-0554/
Copied from: JuliaPy/PyCall.jl#1046 (comment) |
is this closed by #535? |
Yep thanks. |
Similar to what Numba's
nogil
, it's useful for using Julia as a performant backend of PythonThe text was updated successfully, but these errors were encountered: