inner product of tensors