How to matrix-multiply 2d tensor by each vector in 3d matrix

I have two matrices:

t1 = torch.randn(4,4)
t2 = torch.randn(4,1)

I can matrix-multiply them like so:

res = torch.matmul(t1, t2)

This results in a 4x1 matrix. I would like to do this multiplication many at once. t1 remains the same, but I want to make t2 of the size [4,10,10]

If I use matmul() directly it gives me the error: RuntimeError: Expected size for first two dimensions of batch2 tensor to be: [4, 4] but got: [4, 10].

How can I do this multiplication so that t1 is multiplied by each [:,r,c] vector inside t2?

I solved it by rehsaping t2 to [4,100]

And then multiplying the two tensors using:

res = torch.einsum('ij,jk->ik', [t1, t2])