Thanks for your reply!
I tried it but it doesn’t give the desired output.
A = torch.rand(11000,11000)
H = torch.rand(11000,20)

C = (A.unsqueeze(1) * H.unsqueeze(2)).sum(dim=1)

C.shape

torch.Size([11000, 11000])
But the desired shape of C was (20, 11000).
Should dim=0 with the example i provided?