Check a set of args for the <cite>__numpy_ufunc__</cite> method. If more than one of the input arguments implements <cite>__numpy_ufunc__</cite>, they are tried in the order: subclasses before superclasses, otherwise left to right. The first routine returning something other than <cite>NotImplemented</cite> determines the result. If all of the <cite>__numpy_ufunc__</cite> operations returns <cite>NotImplemented</cite>, a <cite>TypeError</cite> is raised.
Returns 0 on success and 1 on exception. On success,
*result contains the result of the operation, if any. If
*result is NULL, there is no override.
System Message: WARNING/2 (
<string>
, line 8);
backlink Inline emphasis start-string without end-string.
System Message: WARNING/2 (
<string>
, line 8);
backlink Inline emphasis start-string without end-string.
<
Position of override in args.
<
Number of overriding args.
<
normal_* holds normalized arguments.
Pos of each override in args
2016-01-29: Disable for now in master -- can re-enable once details are sorted out. All commented bits are tagged NUMPY_UFUNC_DISABLED. -njs
Check inputs
be sure to include possible 'out' keyword argument.
TODO: could use PyArray_GetAttrString_SuppressException if it weren't private to multiarray.so
No overrides, bail out.
Normalize ufunc arguments.
Build new kwds
decide what to do based on the method.
ufunc.__call__
ufunc.reduce
ufunc.accumulate
ufunc.reduceat
ufunc.outer
ufunc.at
Call __numpy_ufunc__ functions in correct order
Choose an overriding argument
Get the first instance of an overriding arg.
Check for sub-types to the right of obj.
override_obj had no subtypes to the right.
<
We won't call this one again
Check if there is a method left to call
No acceptable override found.
Call the override
Exception occurred
Try the next one
Good result.
Override found, return it.
Referenced by ufunc_geterr().