chainerx.dot

chainerx.dot(a, b)

Returns a dot product of two arrays.

For arrays with more than one axis, it computes the dot product along the last axis of a and the second-to-last axis of b. This is just a matrix product if the both arrays are 2-D. For 1-D arrays, it uses their unique axis as an axis to take dot product over.

Parameters
  • a (ndarray) – The left argument.

  • b (ndarray) – The right argument.

Returns

Output array.

Return type

ndarray

Note

This function currently does not support N > 2 dimensional arrays.

Note

During backpropagation, this function propagates the gradient of the output array to input arrays a and b.

See also

numpy.dot()