[Numpy-discussion] Response to PEP suggestions
konrad.hinsen at laposte.net
konrad.hinsen at laposte.net
Fri Feb 18 13:44:27 EST 2005
On 18.02.2005, at 18:59, Travis Oliphant wrote:
> Do you mean have register each of the 21 different types of arrays as
> a new type object? Hmm. That is an interesting idea. I'm a
> little worried
Yes. It only costs a bit of memory for the type objects, so why not?
>> 2) Implement scalar types for those array element types that currently
>> have no Python scalar equivalent (e.g. UInt16).
>
> Do you think this would fly with the Python folks. Counting the
> suggestion above, we would be encouraging the creation of 39 new types
> to the Python core. My current count shows the current number of
> types as 35 so
Those new types would (if all goes well) be part of the standard
library, but not built-in types. Compared to the number of types and
classes in the standard library, the addition is not so big. There
wouldn't be literals either. Anyone who doesn't use the array module
could thus safely ignore the existence of those types.
Implementation-wise, the new types could well be rank-0 arrays
internally and thus add nearly no overhead.
> we would basically double that. This doesn't have to matter, but
> I'd have to hear how Guido feels about something like that.
Of course!
>> 3) Implement the same set of attributes of methods for scalar types
>> and
>> arrays.
>
> That would be ideal. But, I'm not sure what kind of chance we have
> with that.
Me neither. It might depend on clever presentation of the project.
Perhaps some bribing could help ;-)
Konrad.
--
------------------------------------------------------------------------
-------
Konrad Hinsen
Laboratoire Leon Brillouin, CEA Saclay,
91191 Gif-sur-Yvette Cedex, France
Tel.: +33-1 69 08 79 25
Fax: +33-1 69 08 82 61
E-Mail: khinsen at cea.fr
------------------------------------------------------------------------
-------
More information about the NumPy-Discussion
mailing list