X = np.random.normal(size=(10, 5))
Y = np.random.normal(size=(10, 5))
Z1 = inner1d(X, Y)
Z2 = [np.dot(X[k], Y[k]) for k in range(10)]
print(np.allclose(Z1, Z2))
find the dot product of sub-arrays in numpy