Hi Travis,

On Mon, Feb 13, 2012 at 11:46 PM, Travis Oliphant <tra...@continuum.io> wrote:
> Here is the code I used to determine the coercion table of types.   I first 
> used *all* of the numeric_ops, narrowed it down to those with 2 inputs and 1 
> output, and then determined the run-time coercion table.   Then, I removed 
> ops that had the same tables until I was left with binary ops that had 
> different coercion tables.
>
> Some operations were NotImplemented and I used 'X' in the table for those 
> combinations.
>
> The table for each op is a dictionary with keys given by (type1, type2) and 
> values given by a length-4 list of the types of the result between:  
> [scalar-scalar, scalar-array, array-scalar, array-array] where the first term 
> is type1 and the second term is type2.
>
> This resulting dictionary of tables for each op is then saved to a file.   I 
> ran this code for NumPy 1.5.1 64-bit and then again for NumPy 1.6.1 64-bit.   
> I also ran this code for NumPy 1.4.1 64-bit and NumPy 1.3.1.dev 64-bit.
>
> The code to compare them is also attached.    I'm attaching also the changes 
> that have occurred between 1.3.1.dev and 1.4.1, 1.4.1 to 1.5.1, and finally 
> 1.5.1 to 1.6.1
>
> As you can see there were changes in each release.   Most of these were minor 
> prior to the change from 1.5.1 to 1.6.1. I am still reviewing the changes 
> from 1.5.1 to 1.6.1.    At first blush, it looks like there are a lot of 
> changes to swallow that are not necessarily minor.    I really would like to 
> just say all is well, and it's no big deal.   I hope that users really don't 
> care and nobody's code is really relying on array-scalar combination 
> conversions.

Thanks for looking into this.

It strikes me that changes in behavior here could be dangerous and
easily missed, and it does seem to me that it is worth a pause to
consider what the effect of the changes might be.

Obviously, now both 1.6 and 1.6.1 are in the wild, there will be costs
to reverting as well.

Best,

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

Reply via email to