Hi, I'd like to add numpy support to an existing code that uses swig. I've changed the source file that has code to convert python lists into native data from c to c++ so I can use templates to handle data conversions. The problem I'm having is a segfault on PyArray_Check called from my c++ source. Looking at things in the debugger the argument passed to it is indeed an intialized python list, my swig file has import_array() in it's init, and I've verified that it is getting called. adding a function in my c++ source to call import_array() a second time prevents the segfault. Could anyone explain why I need the import_array() in both places? If that's the correct way to handle it?
Thanks Burlen _______________________________________________ NumPy-Discussion mailing list NumPy-Discussion@scipy.org http://mail.scipy.org/mailman/listinfo/numpy-discussion