Nathan Goldbaum
Nathan Goldbaum
Also you might be interested in https://github.com/numpy/numpy/issues/29229
Let's bring this in, thanks @math-hiyoko! Looking forward to future contributions.
I can reproduce this on `main`. Here's a C traceback from lldb if I do ctrl-C during the hang: ``` * thread #1, queue = 'com.apple.main-thread', stop reason = signal...
Hey, sorry for taking a couple days to get back to you. This week has been hectic! I was more thinking of adding some type-checking to the pure-python GCD, and...
Well, one thing I think we can do is ban infinity and NaN at least, to avoid the infinite loop: ``` diff --git a/numpy/_core/_internal.py b/numpy/_core/_internal.py index 058e93644d..fcb6c37f0d 100644 --- a/numpy/_core/_internal.py...
Thanks! I'll try to take a look at this today.
I tried to compile `_pcg64.pyx` in numpy with this directive inserted at the top of the file and hit this compilation error when building numpy: ``` numpy/random/_pcg64.cpython-313t-darwin.so.p/numpy/random/_pcg64.pyx.c:9310:3: error: expected '}'...
Hmm, that ended up being because I had a typo in the directive name, `frethreading_compatible=True`. Not sure why the miscompilation happened with the typo given the code change in this...
We had similar reports from Jax about thread safety issues around adding legacy DTypes - not terribly surprising there are more problems.
@wlach let me know if you're interested in finishing this up or wouldn't mind someone else taking this over.