Repository navigation
MAINT: avoid setting non-existing gufunc strides for keepdims=True. - #11176
Conversation
Corrects an overzealous change from the fixed core dimensions to the ones expanded for keepdims=True.
|
Would be nice if there were a test proving this is necessary. |
|
I don't think |
|
@mattip - I cannot test this, as it doesn't cause any problems - just a bit of extra memory allocated that may get an irrelevant value in it. But it was good to find it, as it showed that your @eric-wieser - the name is a bit beyond the scope of this PR, but how I see it is that the names not attached to the ufunc are explicitly meant for changes that are useful within the routine. In the frozen-dimension addition, Anyway, probably the wrong place to put this idea, since not relevant to this PR - which really is just a correction for a mistake I made in #11098. |
|
Still a bit stymied on this one, I admit. Even though I dived deeply into the code I only have an intuitive feel for when we use |
|
The underlying logic is that if one wants to access information in the ufunc (basically, Agreed that a name change may be useful, but perhaps as part of #11175 - this PR is really just meant as a correction for #11098 (and I'd like to have it in to avoid yet more rebases...). |
|
Thanks Marten |
Corrects an overzealous change in #11098 from the fixed core dimensions to the ones expanded for
keepdims=True. Since arrays were allocated, this wrong change caused no problems, but it was not needed and confused the heck out of myself...@charris: since this is a correction to stuff slated for 1.15, I set the milestone as such.
cc @mattip