I am trying to use the following MLP model (for MNIST) in the model zoo as a template for my work, and I have this problem:
I remove the flattening data (lines 18 - 19) and try to add a Flux.flatten layer before the Dense layer, like this:
return Chain( Flux.flatten, Dense(prod(imgsize), 32, relu), Dense(32, nclasses))
but I got very bad training/testing accuracy (it still runs though). I thought they should be the same. Any idea?