[Numpy-discussion] Best way to insert C code in numpy code

Chris Colbert sccolbert@gmail....
Tue Sep 22 05:17:04 CDT 2009


I give my vote to cython as well. I have a program which uses cython
for a portion simply because it was easier using a simple C for-loop
to do what i wanted rather than beating numpy into submission. It was
an order of magnitude faster as well.

Cheers,

Chris

On Mon, Sep 21, 2009 at 9:12 PM, David Warde-Farley <dwf@cs.toronto.edu> wrote:
> On 21-Sep-09, at 2:55 PM, Xavier Gnata wrote:
>
>> Should I read that to learn you cython and numpy interact?
>> Or is there another best documentation (with examples...)?
>
> You should have a look at the Bresenham algorithm thread you posted. I
> went to the trouble of converting some Python code for Bresenham's
> algorithm to Cython, and a pointer to the Cython+NumPy tutorial:
>
> http://wiki.cython.org/tutorials/numpy
>
> David
> _______________________________________________
> NumPy-Discussion mailing list
> NumPy-Discussion@scipy.org
> http://mail.scipy.org/mailman/listinfo/numpy-discussion
>


More information about the NumPy-Discussion mailing list