arXiv(opens in a new tab)Computer ScienceMar 2019

Manuscript Offprint

arXiv:1903.06586

Selective Kernel Networks

Xiang Li, Wenhai Wang, Xiaolin Hu, Jian Yang

Abstract

In standard Convolutional Neural Networks (CNNs), the receptive fields of artificial neurons in each layer are designed to share the same size. It is well-known in the neuroscience community that the receptive field size of visual cortical neurons are modulated by the stimulus, which has been rarely considered in constructing CNNs. We propose a dynamic selection mechanism in CNNs that allows each neuron to adaptively adjust its receptive field size based on multiple scales of input information. A building block called Selective Kernel (SK) unit is designed, in which multiple branches with different kernel sizes are fused using softmax attention that is guided by the information in these branches. Different attentions on these branches yield different sizes of the effective receptive fields of neurons in the fusion layer. Multiple SK units are stacked to a deep network termed Selective Kernel Networks (SKNets). On the ImageNet and CIFAR benchmarks, we empirically show that SKNet outperforms the existing state-of-the-art architectures with lower model complexity. Detailed analyses show that the neurons in SKNet can capture target objects with different scales, which verifies the capability of neurons for adaptively adjusting their receptive field sizes according to the input. The code and models are available at https://github.com/implus/SKNet.

1 Introduction

The local receptive fields (RFs) of neurons in the primary visual cortex (V1) of cats [14] have inspired the construction of Convolutional Neural Networks (CNNs) [26] in the last century, and it continues to inspire mordern CNN structure construction. For instance, it is well-known that in the visual cortex, the RF sizes of neurons in the same area (e.g., V1 region) are different, which enables the neurons to collect multi-scale spatial information in the same processing stage. This mechanism has been widely adopted in recent Convolutional Neural Networks (CNNs). A typical example is InceptionNets [42, 15, 43, 41], in which a simple concatenation is designed to aggregate multi-scale information from, e.g., 3×\times3, 5×\times5, 7×\times7 convolutional kernels inside the “inception” building block.

However, some other RF properties of cortical neurons have not been emphasized in designing CNNs, and one such property is the adaptive changing of RF size. Numerous experimental evidences have suggested that the RF sizes of neurons in the visual cortex are not fixed, but modulated by the stimulus. The Classical RFs (CRFs) of neurons in the V1 region was discovered by Hubel and Wiesel [14], as determined by single oriented bars. Later, many studies (e.g., [30]) found that the stimuli outside the CRF will also affect the responses of neurons. The neurons are said to have non-classical RFs (nCRFs). In addition, the size of nCRF is related to the contrast of the stimulus: the smaller the contrast, the larger the effective nCRF size [37]. Surprisingly, by stimulating nCRF for a period of time, the CRF of the neuron is also enlarged after removing these stimuli [33]. All of these experiments suggest that the RF sizes of neurons are not fixed but modulated by stimulus [38]. Unfortunately, this property does not receive much attention in constructing deep learning models. Those models with multi-scale information in the same layer such as InceptionNets have an inherent mechanism to adjust the RF size of neurons in the next convolutional layer according to the contents of the input, because the next convolutional layer linearly aggregates multi-scale information from different branches. But that linear aggregation approach may be insufficient to provide neurons powerful adaptation ability.

In the paper, we present a nonlinear approach to aggregate information from multiple kernels to realize the adaptive RF sizes of neurons. We introduce a “Selective Kernel” (SK) convolution, which consists of a triplet of operators: Split, Fuse and Select. The Split operator generates multiple paths with various kernel sizes which correspond to different RF sizes of neurons. The Fuse operator combines and aggregates the information from multiple paths to obtain a global and comprehensive representation for selection weights. The Select operator aggregates the feature maps of differently sized kernels according to the selection weights.

Figure

Figure 1: Selective Kernel Convolution.

The SK convolutions can be computationally lightweight and impose only a slight increase in parameter and computational cost. We show that on the ImageNet 2012 dataset [35] SKNets are superior to the previous state-of-the-art models with similar model complexity. Based on SKNet-50, we find the best settings for SK convolution and show the contribution of each component. To demonstrate their general applicability, we also provide compelling results on smaller datasets, CIFAR-10 and 100 [22], and successfully embed SK into small models (e.g., ShuffleNetV2 [27]).

To verify the proposed model does have the ability to adjust neurons’ RF sizes, we simulate the stimulus by enlarging the target object in natural images and shrinking the background to keep the image size unchanged. It is found that most neurons collect information more and more from the larger kernel path when the target object becomes larger and larger. These results suggest that the neurons in the proposed SKNet have adaptive RF sizes, which may underlie the model’s superior performance in object recognition.

References (51)