
to, 2008-01-24 kello 13:18 -0700, David Bolme kirjoitti:
A am having some trouble when pickling numpy arrays. Basically I use one python script to create the array and then pickle it. When I load the pickled array using a different python script it appears to load fine. When I try to perform a matrix multiply on the array with a vector (using dot) python crashes with a segmentation violation. The array contains 64bit floating point numbers and has a shape of (47, 16384) and the vector has a shape of (16384,1). Other shapes I have tested also have this problem. A workaround is to create a new array that is initialized with the data from the first. For example:
This probably is the same problem as bug #551, http://projects.scipy.org/scipy/numpy/ticket/551 Summary: The cause is not known at this point, but so far appears to have something to do with SSE2 optimized ATLAS library. Are you using Atlas library on Mac OS X, and if yes, which version? Do you have SSE2 optimizations enabled? What happens if you try to use a non-SSE2-optimized Atlas, eg. by pointing LD_LIBRARY_PATH (I'm not sure this works on Mac, but I assume so...) to non-optimized Atlas libraries: LD_LIBRARY_PATH=/usr/lib/atlas python crasher.py -- Pauli Virtanen