A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2006-March/062539.html below:

[Python-Dev] Expose the array interface in Python 2.5?

[Python-Dev] Expose the array interface in Python 2.5?Paul Moore p.f.moore at gmail.com
Fri Mar 17 23:02:07 CET 2006
On 3/17/06, Thomas Heller <theller at python.net> wrote:

> Travis E. Oliphant wrote:
> > Would it be possible to add at least the C-struct array interface to the
> > Python arrayobject in time for Python 2.5?
>
> I'm very much for that.
>
> > Is someone on this list willing to help make it happen?
>
> Unfortunately not me - I'm too busy with ctypes, and if the array interface
> makes it into the core I will have to implement/use that in ctypes too.
> Accessing Python arrays (Numeric arrays, Numeric array, or Numpy array)
> as ctypes arrays, and vice versa, without copying any memory, would be a good thing.

This seems to expose the key point here. What *exactly* is the work
that Travis is requesting? (I have very little spare time, no VC7.1 to
do builds, but I do have an interest and would possibly be willing to
help, if it was clear what was involved...)

If all that is required is a simple C definition added to the Python
code, then it seems to me that would be (a) fairly easy, but (b)
pretty useless (on the basis that a standards-style PEP like the DB
API ones would do much the same, without any code changes).

But as ctypes is now in the core, it seems likely that any addition of
an array type to the core would mean that ctypes should support it -
which means that the work Thomas mentions is required.

There are quite likely other issues, as well.

On the third hand, the PEP referenced from the page you quote (at
http://svn.scipy.org/svn/PEP/PEP_genarray.txt) seems to specify an
implementation - are you just asking for that to be added to the core?
If so, why not submit this as a formal PEP, and see what happens from
there? (For this route, one of the Numeric people *needs* to champion
the PEP, IMHO, as only they are qualified to address any points that
get raised in general discussion).

Paul.
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4