17
$\begingroup$

I've been looking at the CS231N lectures from Stanford and I'm trying to wrap my head around some issues in CNN architectures. What I'm trying to understand is if there are some general guidelines for picking convolution filter size and things like strides or is this more an art than a science?

Pooling I understand exists mainly to induce some form of translation invariance into a model. On the other hand, I don't have a good intuition of how stride size is picked. Are there some other guidelines to that except trying to compress the current layer size or trying to achieve a larger receptive field to a neuron? Anyone know of any good papers or similar that discuss this?

$\endgroup$

2 Answers 2

10
$\begingroup$

As an introductory text to all the issues you name, I would recommend the deep learning book. It provides a broad overview of the field. It explains the role each of those parameters play.

In my opinion is very helpful to read about some of the most popular architectures (resnet, inception, alex-net), and extract the key ideas leading to the design decisions. After reading the aforementioned book.

In the syllabus of the lectures you refer to, it is explained in great detail how the convolution layer adds a big number of parameters (weights, biases) and neurons. This layer, once trained, it is able to extract meaning patterns from the image. For lower layers those filters look like edge extractors. For higher layers, those primitive shapes are combined to describe more complex forms. Those filters involve a high number of parameters, and a big issue of the design of deep networks in how to be able to describe complex forms and still be able to reduce the number of parameters.

Since neighboring pixels are strongly correlated (specially in lowest layers), it makes sense to reduce the size of the output by subsampling (pooling) the filter response. The further apart two pixels are from each other, the less correlated. Therefore, a big stride in the pooling layer leads to high information loss. Loosely speaking. A stride of 2 and a kernel size 2x2 for the pooling layer is a common choice.

A more sophisticated approach is the Inception network (Going deeper with convolutions) where the idea is to increase sparsity but still be able to achieve a higher accuracy, by trading the number of parameters in a convolutional layer vs an inception module for deeper networks.

A nice paper that provides hints on current architectures and the role of some of the design dimensions in a structured, systematic way is SqueezeNet: AlexNet-level accuracy with 50x fewer parameters and <0.5MB model size. It builds on ideas introduced in the models previously mentioned.

$\endgroup$
4
$\begingroup$

If you consider better learning over learning time, I want to suggest these kernel and stride sizes;

Regarding filter size, I think it depends on your image characteristics. For example, large amount of pixels are necessary for the network recognize the object, you may use bigger filters, on other hand if objects are somewhat small or local features, you consider applying smaller filters relative to your input image size.

For the stride size, for me, small stride would be better at capturing the finer details of the input image.

For me, the benefit of pooling is that it extracts the sharpest features of an image. In general, the sharpest features look like the best lower level representation of an image.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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