[Numpy-discussion] new array type in cython?

Charles R Harris charlesr.harris at gmail.com
Mon Sep 28 15:05:27 EDT 2009


On Mon, Sep 28, 2009 at 10:47 AM, Neal Becker <ndbecker2 at gmail.com> wrote:

> Robert Kern wrote:
>
> > On Mon, Sep 28, 2009 at 10:36, Neal Becker <ndbecker2 at gmail.com> wrote:
> >> Robert Kern wrote:
> >>
> >>> On Mon, Sep 28, 2009 at 06:23, Neal Becker <ndbecker2 at gmail.com>
> wrote:
> >>>> Has anyone attempted a new array type in cython?  Any hints?
> >>>
> >>> Are you having problems?
> >>
> >> No, haven't tried using cython for this yet.  Wondering if there are any
> >> examples.
> >
> > Have you read the documentation?
> >
> > http://wiki.cython.org/tutorials/numpy
> >
>
> Yes, I didn't notice anything about adding user-defined datatypes to numpy,
> did I miss something?
>
> This is for a fixed point type, no? Why not write a class based around
something like int32, override some of the methods, and use object arrays?
It's quick an easy and unless you really, really need speed it should do the
trick.

Chuck
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20090928/c236e98f/attachment.html>


More information about the NumPy-Discussion mailing list