8000 ENH: np.linalg.eig doesn't process the SIGINT signal · Issue #11081 · numpy/numpy · GitHub
[go: up one dir, main page]

Skip to content

ENH: np.linalg.eig doesn't process the SIG 8000 INT signal #11081

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

Open
yurivict opened this issue May 12, 2018 · 2 comments
Open

ENH: np.linalg.eig doesn't process the SIGINT signal #11081

yurivict opened this issue May 12, 2018 · 2 comments

Comments

@yurivict
Copy link

Ctrl-C doesn't have any effect.

py27-numpy-1.13.3_3,1 on FreeBSD-11.1

@yurivict yurivict changed the title np.linalg.eig doesn't process the SIGINT np.linalg.eig doesn't process the SIGINT signal May 12, 2018
@mattip mattip changed the title np.linalg.eig doesn't process the SIGINT signal ENH: np.linalg.eig doesn't process the SIGINT signal Jun 19, 2018
@mattip
Copy link
Member
mattip commented Jun 19, 2018

It is hard to pick the right time, but it seems OpenBlas is not respecting the signal. When I hit ^C after ~2 seconds until the code enters the eig call, the interrupt only returns after ~5 more seconds.

>>> c,d = np.linalg.eig(a)
>>> a = np.empty((100, 1000,1000), dtype=float) # big enough to take some time
>>> c,d = np.linalg.eig(a)
^CTraceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/matti/pypy_stuff/cpython3_virt/lib/python3.6/site-packages/numpy/linalg/linalg.py", line 1256, in eig
    w, vt = _umath_linalg.eig(a, signature=signature, extobj=extobj)
KeyboardInterrupt
>>> 

@seberg
Copy link
Member
seberg commented Jun 19, 2020

I tseems (with the exception of a few releases which recieved backports). A possible solution should be to call PyOS_InterruptOccurred() repeatedly. We could probably query that periodically in the outer iteration either in the iterator, or the ufunc machinery itself.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants
0