[Numpy-discussion] ndarray subclassing bug?
Pierre GM
pgmdevlist at gmail.com
Sun Aug 10 14:33:03 EDT 2008
On Sunday 10 August 2008 14:26:33 Christoph T. Weidemann wrote:
> Why whould tst.sort() show the correct base class and np.sort show
> NoneType as base class for tst?
> I'd appreciate any insights ...
numpy functions will return arrays of the type which has the largest priority,
with ndarrays a priority of 1 by default. If you set a Class variable
__array_priority__ to a number larger than 1, that should fix your problem.
More information about the NumPy-Discussion
mailing list