tf.keras.backend.dot

Multiplies 2 tensors (and/or variables) and returns a tensor.

x Tensor or variable.
y Tensor or variable.

A tensor, dot product of x and y.

Examples:

x = tf.keras.backend.placeholder(shape=(2, 3))
y = tf.keras.backend.placeholder(shape=(3, 4))
xy = tf.keras.backend.dot(x, y)
xy
<tf.Tensor ... shape=(2, 4) dtype=float32>
x = tf.keras.backend.placeholder(shape=(32, 28, 3))
y = tf.keras.backend.placeholder(shape=(3, 4))
xy = tf.keras.backend.dot(x, y)
xy
<tf.Tensor ... shape=(32, 28, 4) dtype=float32>
x = tf.keras.backend.random_uniform_variable(shape=(2, 3), low=0, high=1)
y = tf.keras.backend.ones((4, 3, 5))
xy = tf.keras.backend.dot(x, y)
tf.keras.backend.int_shape(xy)
(2, 4, 5)