[Python-Dev] Expose the array interface in Python 2.5? (original) (raw)
Greg Ewing greg.ewing at canterbury.ac.nz
Tue Mar 28 01:31:38 CEST 2006
- Previous message: [Python-Dev] Expose the array interface in Python 2.5?
- Next message: [Python-Dev] buildbot warnings in x86 gentoo trunk
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Chris Barker wrote:
Can we have both? A defined interface, that existing code can be adapted to provide, and a new C-Object, that future code can just use. If the goal is to have as many extension types as possible use the same base object, the sooner a standard object is provided the better.
Having many extension types provide the same interface is what I think the main goal should be, not to have them use the same object. So getting the interface defined should be the first priority.
I'd sure like to see indexing and slicing, at at least.
The interface itself doesn't need to provide indexing and slicing -- these could be provided by a view object that used the array interface of the underlying object.
This would also fit in nicely with the "views" philosophy that seems to be shaping up for Py3k.
Another point is that n-dimensional arrays really are very useful for all sorts of stuff that have nothing to do with high-performance Numeric computing.
I'm all in favour of including such an object, as long as we keep in mind that this is an orthogonal issue to having an array interface. The discussion still seems to be a bit muddled on this point.
Greg
- Previous message: [Python-Dev] Expose the array interface in Python 2.5?
- Next message: [Python-Dev] buildbot warnings in x86 gentoo trunk
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]