Unclear dimension error message

Hi, new user trying to use flux for a convolution network. I get the error:
DimensionMismatch("A has dimensions (1024,64) but B has dimensions (1024,64)")

But I do not understand what that means. Are the dimensions supposed to be different in some way?

The error is probably thrown from a matrix multiplication (the stacktrace will show you what exactly is causing it). For matrix multiplication, you need the dimensions to be (N, M) * (M, L) (i.e. the inner dimension must match). You have (N, M) * (N, M) which doesn’t work (inner dimensions don’t match). One of those matrices should be probably be transposed.

1 Like

Thank you, that fixed it.