From: Benjamin T. <ben...@de...> - 2006-08-09 08:28:13
|
Le Mardi 8 Ao=FBt 2006 05:18, Bill Baxter a =E9crit=A0: > I see Pyrex and SWIG examples in numpy/doc but there doesn't seem to be an > example of just a simple straightforward usage of the C-API. > For instance make a few arrays by hand in C and then call numpy.multiply() > on them. So far my attempts to call PyArray_SimpleNewFromData all result > in segfaults. > Anyone have such an example? > > --Bill =46or our neuroimagery lib, i had to write some simples straightforward wra= ppers=20 to the C-lib GSL, which you might be interested to have a quick look..=20 Trac entry: http://projects.scipy.org/neuroimaging/ni/browser/fff/trunk/bindings/lightw= rappers.h http://projects.scipy.org/neuroimaging/ni/browser/fff/trunk/bindings/lightw= rappers.c and half-commented example usage.. http://projects.scipy.org/neuroimaging/ni/browser/fff/trunk/pythonTests/fff= ctests/lightmoduleExample.c =2D- Benjamin Thyreau CEA Orsay |