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

frompyfunc function segfault (Trac #1775) #2368

Closed
numpy-gitbot opened this issue Oct 19, 2012 · 5 comments
Closed

frompyfunc function segfault (Trac #1775) #2368

numpy-gitbot opened this issue Oct 19, 2012 · 5 comments

Comments

@numpy-gitbot
Copy link

Original ticket http://projects.scipy.org/numpy/ticket/1775 on 2011-03-18 by trac user borisaqua, assigned to unknown.

from numpy import *
fv = vectorize(lambda a: tuple([a]*50))
fv([2,3])

Program received signal SIGSEGV, Segmentation fault.
0x00007ffff6252acf in ?? () from /usr/lib/pymodules/python2.6/numpy/core/umath.so
(gdb) bt
#0 0x00007ffff6252acf in ?? () from /usr/lib/pymodules/python2.6/numpy/core/umath.so
#1 0x00007ffff6254734 in ?? () from /usr/lib/pymodules/python2.6/numpy/core/umath.so
#2 0x00007ffff6255928 in ?? () from /usr/lib/pymodules/python2.6/numpy/core/umath.so
#3 0x0000000000000000 in ?? ()

(gdb)

@numpy-gitbot
Copy link
Author

@charris wrote on 2011-03-18

This still shows up in the current master branch.

@numpy-gitbot
Copy link
Author

@mforbes wrote on 2012-05-17

The real problem is not vectorize but frompyfunc which fails for nout >= 32:

>>> np.frompyfunc(lambda a: tuple([a]*31), 1, 31)(1)
(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1)
>>> np.frompyfunc(lambda a: tuple([a]*32), 1, 32)(1)
Segmentation fault

@numpy-gitbot
Copy link
Author

Title changed from Vectorized function segfault to frompyfunc function segfault by @mforbes on 2012-05-17

@charris
Copy link
Member

charris commented Feb 19, 2014

Still present in 1.9-devel.

@jaimefrio
Copy link
Member

This was fixed in #5673, so closing.

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