It has been a long I am confused on understanding some of the AlexNet architecture : enter image description here

The output of the first conv layer is 55x55x48 (96 considering the division between GPUs but let's stick to 1 GPU so depth 48). Then max pooling is applied and there come my problem.

When applying max pooling, the result is 27x27x48 right ? If so, how is applied the next convolution over this result (with 5x5x48 filters) to output 27x27x128 ? I finally don't see how and when to apply max-pooling in between convolutions. I must miss something here...


Okay, I got it. If anyone interested, they use 5x5 filter but with padding 2 and striding 1 so that with bias it doesn't change the 2D dimension of the output when applied on the result of max-pooling. The info on padding isn't present on the original paper...


It uses same padding which means the output of max-pooling is padded with zeros in a way that the output of next layer preserves the width and height. for information take a look at here.

  • $\begingroup$ If the padding was 0, the output size would be (27-5)/1 + 1 = 23x23x128, but it remains 27x27, how would it be possible then ? $\endgroup$ – Elliot Dec 5 '17 at 16:06
  • $\begingroup$ but padding is not zero. I have referred that it is same so it preserves the height and width. do you know what is same padding? $\endgroup$ – Media Dec 5 '17 at 16:20
  • $\begingroup$ I understood "zero padding", my fault. Same padding is exactly what I said below, padding of size 2 in that precise case. Thanks $\endgroup$ – Elliot Dec 5 '17 at 16:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.