Massyanya
Massyanya

Reputation: 2934

What are channels in tf.nn.conv2D?

I've looked through some great explanations on what different arguments of tf.nn.conv2D represent, but I still can't understand what exactly in_channels and out_channels represent.

Could someone please clarify this for me?

Upvotes: 7

Views: 14324

Answers (1)

Vijay Mariappan
Vijay Mariappan

Reputation: 17201

Lets say you have a image of size 64x64. It is composed of R-G-B of 64x64 each, so the input size is 64x64x3 and 3 is the input channel in this case. Now you want to convolve this input with a kernel of 5x5x3, you get an output of 64x64x1 (with padding). Suppose you have 100 such kernels and convolve each one of them with the input, you get 64x64x100. Here the output channels are 100.

Upvotes: 23

Related Questions