On Wed, Aug 6, 2014 at 5:24 PM, Charles R Harris <charlesr.har...@gmail.com>
wrote:

>
>
>
> On Wed, Aug 6, 2014 at 4:57 PM, Nathaniel Smith <n...@pobox.com> wrote:
>
>> On Wed, Aug 6, 2014 at 4:32 PM, Charles R Harris
>> <charlesr.har...@gmail.com> wrote:
>> > Should also mention that we don't have the ability to operate on stacked
>> > vectors because they can't be identified by dimension info. One
>> workaround
>> > is to add dummy dimensions where needed, another is to add two flags,
>> row
>> > and col, and set them appropriately. Two flags are needed for backward
>> > compatibility, i.e., both false is a traditional array.
>>
>> It's possible I could be convinced to like this, but it would take a
>> substantial amount of convincing :-). It seems like a pretty big
>> violation of orthogonality/"one obvious way"/etc. to have two totally
>> different ways of representing row/column vectors.
>>
>>
> The '@' operator supports matrix stacks, so it would seem we also need to
> support vector stacks. The new addition would only be effective with the
> '@' operator. The main problem I see with flags is that adding them would
> require an extensive audit of the C code to make sure they were preserved.
> Another option, already supported to a large extent, is to have row and col
> classes inheriting from ndarray that add nothing, except for a possible new
> transpose type function/method. I did mock up such a class just for fun,
> and also added a 'dyad' function. If we really don't care to support
> stacked vectors we can get by without adding anything.
>
>
Note that the '@' PEP is not compatible with current 'dot' for arrays with
more than two dimensions and for scalars.

Chuck
_______________________________________________
NumPy-Discussion mailing list
NumPy-Discussion@scipy.org
http://mail.scipy.org/mailman/listinfo/numpy-discussion

Reply via email to