[PYTHON MATRIX-SIG] function not supported?

Jim Hugunin hugunin@mit.edu
Mon, 14 Apr 1997 15:29:16 -0400


Tommy writes:
> I picked up the latest (I think it's the latest?) Numeric extensions
> after Jim H. posted that it was about ready for primt time.  I got the
> package from: http://www.sls.lcs.mit.edu/~jjh/numpy about three or
> four weeks ago.  It all built fine and imports okay, but every other
> test program I have for it fails in about the same way.  Here's what
> happened when I ran the mandelbrot.py Demo:

I've seen this problem before.  It appears to have to do with dynamic 
linking under particular OS's.  I assume that you're using the dynamically 
linked version of numpy?  Also, what OS are you running under?

The numeric functions on multiarrays are actually implemented in 
umathmodule.c.  When this module is imported, it fills in the table of math 
functions for arrayobjects.  The problem is that somehow on your system, 
this table is not getting filled in.  I'd bet that if you build a 
statically linked version of Python + NumPy, this problem will go away.  If 
you know enough about your OS's dynamic linking system to figure out why 
things are not working on your machine, I'd love to adopt any patches you 
might have.  For a clue, the function that probably isn't working is in 
umath_init in umathmodule.c and it's the line:

 	/* Setup the array object's numerical structures */
 	 PyArray_SetNumericOps(d);

Let me know how it goes - Jim


_______________
MATRIX-SIG  - SIG on Matrix Math for Python

send messages to: matrix-sig@python.org
administrivia to: matrix-sig-request@python.org
_______________