From the answers to this question In a CNN, does each new filter have different weights for each input channel, or are the same weights of each filter used across input channels?, I got the fact that each filter has different weights for each input channel. But why should that be the case? What if we apply the same weights to each input channel? Does it work or not?


For simplicitly, let's consider only the first convolutional layer, that is, the one applied to the image. If you consider an RGB image, then there are $3$ channels: the red channel, the green channel and the blue channel. Thus, a kernel that is applied to this image will also have $3$ channels: the red channel, the green channel and the blue channel. In general, the distributions of the intensity of the red, green and blue colors in the image are different, so, in general, the red, green and blue channels of the kernel will also be different because they need to keep track of different information.

| improve this answer | |
  • $\begingroup$ Thanks for your answer. I understand what you mean, so do you think it is possible to use the same weight for different channel? Or do you know someone who tried it and got a result? $\endgroup$ – wangxl Jun 10 '19 at 8:24
  • $\begingroup$ The weights are the learnable parameters. They are changed by gradient descent and the back-propagation algorithm during training. $\endgroup$ – nbro Jun 10 '19 at 9:17
  • $\begingroup$ @wangxl To test it yourself you could just modify your images to place the red channel at the top, the green channel in the middle and the blue channel at the bottom (so that your 3-channel width * height image becomes a 1-channel width * (3*height) image) and feed that single-channel image into the network. This will contain all the same information as your original image, but only train a single set of filter kernels. $\endgroup$ – DrMcCleod Jul 11 '19 at 12:04

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.