I assume your parameters are conv weights.
Based on the shape you provided, both weights have the same number of input and output channels.
Have a look at this example:
conv = nn.Conv2d(in_channels=16, out_channels=64, kernel_size=3)
print(conv.weight.shape)
> torch.Size([64, 16, 3, 3])

So the difference is the kernel size. While one has a kernel of [3, 1], the other one is the transposed version of it.
Would this code work for you?
a = torch.ones(64, 16, 1, 3)
b = torch.ones(64, 16, 3, 1)

c = torch.matmul(b, a)
print(c.shape)
> torch.Size([64, 16, 3, 3])