Hi, I want to do batch matrix-vector multiplication but cannot figure out how to do that.
for example,
input shape is (N x M x VectorSize), weight shape is (M x VectorSize x VectorSize). and I want to get an output shape (N x M x VectorSize).
N is batch size, M is number of vectors and VectorSize is literally size of vector. I want to compute matrix multiplication each vectors and matrices like picture below.image707×592 77.9 KB
How can I do this without any for-loop?
Thank you.