← Back to team overview

python-quantities-developers team mailing list archive

Re: quantities-0.5b5 posted at PyPI

 

Ok, I'll try a third time to send this message...

On Wed, Jun 24, 2009 at 12:01 AM, Tony S Yu <tonyyu@xxxxxxx> wrote:

>
> On Jun 23, 2009, at 4:18 PM, Darren Dale wrote:
>
>  There was some discussion at numpy-discussion of what needs to be done
>> before numpy-1.4 is released. I took the opportunity to request an ndarray
>> method that could be called by ufuncs on the way in in order to better
>> support subclassing and to make ufuncs more generally useful to subclasses.
>> I also posted a new beta (0.5b5) at the python package index which addresses
>> a couple bugs identified by Tony Yu (welcome Tony!) and a few other
>> less-critical items.
>>
>> I'll have a bit of free time to pick up development again in the nights
>> and weekends over the summer, and am looking forward to continuing work on
>> unit tests and documentation. Hopefully the proposed ufunc mechanism will
>> gain support and be implemented in the near future, which should allow
>> development of a MaskedQuantity, allow things like m+mm, and allow
>> dimensional analysis to be performed before modifying array data. If you
>> have questions or comments about this feature for the numpy mailing list,
>> please speak up, I would prefer to make the most of this opportunity to
>> improve numpy.
>>
>> Cheers,
>> Darren
>>
>
> Hey Darren,
>
> I was wondering if you've made any attempts to write a patch to implement
> this ufunc mechanism.
>

I posted a proof of concept back in March, trying to gauge if there was
enough support to work on a full implementation. I didn't get any feedback
and so I haven't worked on it since.

>
> There were supportive comments on the numpy mailing list, but no one
> sounded enthusiastic enough to actually write code. A rough implementation
> of the proposal would go a long way towards getting this in numpy 1.4.
>
> That said, I don't think I'd be capable of writing the code. I don't really
> know the numpy internals very well---I don't even have much experience
> subclassing numpy arrays. (I know it's pretty bad form to suggest something,
> but not offer any help.)


Thats alright. I'm roughly familiar with the relevant numpy code (I fixed
several bugs for 1.3 that affected quantities) and could work on a first cut
implementation. I'll follow up with the numpy mailing list today. (Update,
I've had enough feedback to feel comfortable working on an actual
impolementation, maybe I can even get it together in time for numpy-1.4
which might be released in late September.)

I'm also considering submitting an abstract to give a talk at scipy, maybe a
lightning talk.

Darren

References