array-api
array-api copied to clipboard
Should vecdot broadcast along the contracted axis?
The spec implies that it should https://data-apis.org/array-api/latest/API_specification/generated/signatures.linear_algebra_functions.vecdot.html#signatures.linear_algebra_functions.vecdot. However, other functions like matmul do not contract along the contracted axis.
This came up in the numpy implementation, which is currently wrong, but is being fixed at https://github.com/numpy/numpy/pull/21928.
tensordot does not allow broadcasting in the contracted axes, so I think vecdot shouldn't, either.