Does Convolution kernel size affect number of channels?how to propagate error from convolutional layer to previous layer?TensorFlow: number of channels of conv1d filtertuning a convolution neural net, sample sizeProof of Kernel PropertyHow does convolution operation perform in CNN?Why convolution over volume sums up across channels?What advantage does Guassian kernel have than any other kernels, such as linear kernel, polynomial kernel and so on?What is the purpose of a 1x1 convolutional layer?degeneracy of a CNN having only 1 convolution kernel down to a fully connected NNHow to choose the number of output channels in a convolutional layer?
Is this toilet slogan correct usage of the English language?
Query about absorption line spectra
Loading commands from file
what is different between Do you interest vs interested in something?
Could the E-bike drivetrain wear down till needing replacement after 400 km?
Why is so much work done on numerical verification of the Riemann Hypothesis?
What should you do when eye contact makes your subordinate uncomfortable?
Travelling outside the UK without a passport
How do I nest cases?
What is this called? Old film camera viewer?
Customize circled numbers
Varistor? Purpose and principle
Is a model fitted to data or is data fitted to a model?
Count the occurrence of each unique word in the file
Why did the EU agree to delay the Brexit deadline?
Offered money to buy a house, seller is asking for more to cover gap between their listing and mortgage owed
Should I stop contributing to retirement accounts?
What should you do if you miss a job interview (deliberately)?
Why do we read the Megillah by night and by day?
Is there a name for this algorithm to calculate the concentration of a mixture of two solutions containing the same solute?
Which one is correct as adjective “protruding” or “protruded”?
Can I use Seifert-van Kampen theorem infinite times
Yosemite Fire Rings - What to Expect?
Why does the Sun have different day lengths, but not the gas giants?
Does Convolution kernel size affect number of channels?
how to propagate error from convolutional layer to previous layer?TensorFlow: number of channels of conv1d filtertuning a convolution neural net, sample sizeProof of Kernel PropertyHow does convolution operation perform in CNN?Why convolution over volume sums up across channels?What advantage does Guassian kernel have than any other kernels, such as linear kernel, polynomial kernel and so on?What is the purpose of a 1x1 convolutional layer?degeneracy of a CNN having only 1 convolution kernel down to a fully connected NNHow to choose the number of output channels in a convolutional layer?
$begingroup$
I am going through Dilated Residual Network blog post. In this, Under 2.Multi-scale Context aggregation
heading, author mentioned this.
The last one is the 1×1 convolutions for mapping the number of
channels to be the same as the input one. Therefore, the input and the
output has the same number of channels. And it can be inserted to
different kinds of convolutional neural networks.
I thought, we decide number of channels in the next layer and kernels will be initialized randomly. These kernels shape is decided by us which are 1x1 or 3x3 etc., So, what did author mean when he said, 1x1 convolutions for mapping the number of channels to be the same as the input one.When, Even if its 2x2 convolutional kernel, number of channels are not changed.
deep-learning cnn kernel
$endgroup$
add a comment |
$begingroup$
I am going through Dilated Residual Network blog post. In this, Under 2.Multi-scale Context aggregation
heading, author mentioned this.
The last one is the 1×1 convolutions for mapping the number of
channels to be the same as the input one. Therefore, the input and the
output has the same number of channels. And it can be inserted to
different kinds of convolutional neural networks.
I thought, we decide number of channels in the next layer and kernels will be initialized randomly. These kernels shape is decided by us which are 1x1 or 3x3 etc., So, what did author mean when he said, 1x1 convolutions for mapping the number of channels to be the same as the input one.When, Even if its 2x2 convolutional kernel, number of channels are not changed.
deep-learning cnn kernel
$endgroup$
add a comment |
$begingroup$
I am going through Dilated Residual Network blog post. In this, Under 2.Multi-scale Context aggregation
heading, author mentioned this.
The last one is the 1×1 convolutions for mapping the number of
channels to be the same as the input one. Therefore, the input and the
output has the same number of channels. And it can be inserted to
different kinds of convolutional neural networks.
I thought, we decide number of channels in the next layer and kernels will be initialized randomly. These kernels shape is decided by us which are 1x1 or 3x3 etc., So, what did author mean when he said, 1x1 convolutions for mapping the number of channels to be the same as the input one.When, Even if its 2x2 convolutional kernel, number of channels are not changed.
deep-learning cnn kernel
$endgroup$
I am going through Dilated Residual Network blog post. In this, Under 2.Multi-scale Context aggregation
heading, author mentioned this.
The last one is the 1×1 convolutions for mapping the number of
channels to be the same as the input one. Therefore, the input and the
output has the same number of channels. And it can be inserted to
different kinds of convolutional neural networks.
I thought, we decide number of channels in the next layer and kernels will be initialized randomly. These kernels shape is decided by us which are 1x1 or 3x3 etc., So, what did author mean when he said, 1x1 convolutions for mapping the number of channels to be the same as the input one.When, Even if its 2x2 convolutional kernel, number of channels are not changed.
deep-learning cnn kernel
deep-learning cnn kernel
asked Mar 20 at 12:00
InAFlashInAFlash
3521315
3521315
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
$begingroup$
Normally a convolutional neural network will get flattened into a single column vector after the convolutions and then maybe be processed by dense layer. In this model, the convolution $1times1$ is used as an output layer. It will have $C$ channels like every other layer, but it is not dilatated. Hence, you can use this layer as the input to other convolutional neural networks.
The kernel size will not influence the channels. Imagine an RGB image with 4 by 4 pixels. If we have a $2times 2$ convolution with $2times 2$ stride we will get an output of dimension $3times 2 times 2$ (without padding). Hence the channels do not change. If we have $K$ filters we will ket $K$ times a $3times 2 times 2$ output. If the kernel size is $4times 4$ with a stride of $2times 2$ we will get a $3times 1 times 1$ (without padding) output for each of the $K$ filters. The kernel size only influences how large the receptive field of the convolutions are. Hence, it only influences how the layer is scaling the individual dimensions of the width and height (by using RGB images as an example).
If you flatten the output of a layer you will always reduce its dimensionality to $1$. In the dilated convolutional neural network they do not have a layer that flattens the input.
New contributor
$endgroup$
$begingroup$
i think, it does not have 3 channels. Number of channels are increased if you actually see.It increased till last layer and Its C in last layers. Am i wrong?
$endgroup$
– InAFlash
Mar 20 at 12:21
$begingroup$
@InAFlash: For the basic network the layer always stays at $C$ channels. I assumed RGB images, hence $C=3$. I corrected this. You could also take any other layer of the basic network and feed it into another network.
$endgroup$
– MachineLearner
Mar 20 at 12:24
$begingroup$
if you see, for large network, its not. And my question was how kernel size is related to number of channels.Thanks
$endgroup$
– InAFlash
Mar 20 at 12:27
1
$begingroup$
@InAFlash I reached the same conclusion. Kernel 1x1 can give C channels, 2C channels, any channels. Just like kernel 3x3, which can give C channels, 32C channels, any channels. So the statement "1x1 because the same channels" seems unjustified in the article.
$endgroup$
– Esmailian
Mar 20 at 12:44
2
$begingroup$
@InAFlash: The author just wants to emphasize that the last layer is not flattened to ensure that the output can be used for other networks. The author could have been more precise in explaining his/her point.
$endgroup$
– MachineLearner
Mar 20 at 12:46
|
show 3 more comments
Your Answer
StackExchange.ifUsing("editor", function ()
return StackExchange.using("mathjaxEditing", function ()
StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix)
StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
);
);
, "mathjax-editing");
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "557"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fdatascience.stackexchange.com%2fquestions%2f47665%2fdoes-convolution-kernel-size-affect-number-of-channels%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
$begingroup$
Normally a convolutional neural network will get flattened into a single column vector after the convolutions and then maybe be processed by dense layer. In this model, the convolution $1times1$ is used as an output layer. It will have $C$ channels like every other layer, but it is not dilatated. Hence, you can use this layer as the input to other convolutional neural networks.
The kernel size will not influence the channels. Imagine an RGB image with 4 by 4 pixels. If we have a $2times 2$ convolution with $2times 2$ stride we will get an output of dimension $3times 2 times 2$ (without padding). Hence the channels do not change. If we have $K$ filters we will ket $K$ times a $3times 2 times 2$ output. If the kernel size is $4times 4$ with a stride of $2times 2$ we will get a $3times 1 times 1$ (without padding) output for each of the $K$ filters. The kernel size only influences how large the receptive field of the convolutions are. Hence, it only influences how the layer is scaling the individual dimensions of the width and height (by using RGB images as an example).
If you flatten the output of a layer you will always reduce its dimensionality to $1$. In the dilated convolutional neural network they do not have a layer that flattens the input.
New contributor
$endgroup$
$begingroup$
i think, it does not have 3 channels. Number of channels are increased if you actually see.It increased till last layer and Its C in last layers. Am i wrong?
$endgroup$
– InAFlash
Mar 20 at 12:21
$begingroup$
@InAFlash: For the basic network the layer always stays at $C$ channels. I assumed RGB images, hence $C=3$. I corrected this. You could also take any other layer of the basic network and feed it into another network.
$endgroup$
– MachineLearner
Mar 20 at 12:24
$begingroup$
if you see, for large network, its not. And my question was how kernel size is related to number of channels.Thanks
$endgroup$
– InAFlash
Mar 20 at 12:27
1
$begingroup$
@InAFlash I reached the same conclusion. Kernel 1x1 can give C channels, 2C channels, any channels. Just like kernel 3x3, which can give C channels, 32C channels, any channels. So the statement "1x1 because the same channels" seems unjustified in the article.
$endgroup$
– Esmailian
Mar 20 at 12:44
2
$begingroup$
@InAFlash: The author just wants to emphasize that the last layer is not flattened to ensure that the output can be used for other networks. The author could have been more precise in explaining his/her point.
$endgroup$
– MachineLearner
Mar 20 at 12:46
|
show 3 more comments
$begingroup$
Normally a convolutional neural network will get flattened into a single column vector after the convolutions and then maybe be processed by dense layer. In this model, the convolution $1times1$ is used as an output layer. It will have $C$ channels like every other layer, but it is not dilatated. Hence, you can use this layer as the input to other convolutional neural networks.
The kernel size will not influence the channels. Imagine an RGB image with 4 by 4 pixels. If we have a $2times 2$ convolution with $2times 2$ stride we will get an output of dimension $3times 2 times 2$ (without padding). Hence the channels do not change. If we have $K$ filters we will ket $K$ times a $3times 2 times 2$ output. If the kernel size is $4times 4$ with a stride of $2times 2$ we will get a $3times 1 times 1$ (without padding) output for each of the $K$ filters. The kernel size only influences how large the receptive field of the convolutions are. Hence, it only influences how the layer is scaling the individual dimensions of the width and height (by using RGB images as an example).
If you flatten the output of a layer you will always reduce its dimensionality to $1$. In the dilated convolutional neural network they do not have a layer that flattens the input.
New contributor
$endgroup$
$begingroup$
i think, it does not have 3 channels. Number of channels are increased if you actually see.It increased till last layer and Its C in last layers. Am i wrong?
$endgroup$
– InAFlash
Mar 20 at 12:21
$begingroup$
@InAFlash: For the basic network the layer always stays at $C$ channels. I assumed RGB images, hence $C=3$. I corrected this. You could also take any other layer of the basic network and feed it into another network.
$endgroup$
– MachineLearner
Mar 20 at 12:24
$begingroup$
if you see, for large network, its not. And my question was how kernel size is related to number of channels.Thanks
$endgroup$
– InAFlash
Mar 20 at 12:27
1
$begingroup$
@InAFlash I reached the same conclusion. Kernel 1x1 can give C channels, 2C channels, any channels. Just like kernel 3x3, which can give C channels, 32C channels, any channels. So the statement "1x1 because the same channels" seems unjustified in the article.
$endgroup$
– Esmailian
Mar 20 at 12:44
2
$begingroup$
@InAFlash: The author just wants to emphasize that the last layer is not flattened to ensure that the output can be used for other networks. The author could have been more precise in explaining his/her point.
$endgroup$
– MachineLearner
Mar 20 at 12:46
|
show 3 more comments
$begingroup$
Normally a convolutional neural network will get flattened into a single column vector after the convolutions and then maybe be processed by dense layer. In this model, the convolution $1times1$ is used as an output layer. It will have $C$ channels like every other layer, but it is not dilatated. Hence, you can use this layer as the input to other convolutional neural networks.
The kernel size will not influence the channels. Imagine an RGB image with 4 by 4 pixels. If we have a $2times 2$ convolution with $2times 2$ stride we will get an output of dimension $3times 2 times 2$ (without padding). Hence the channels do not change. If we have $K$ filters we will ket $K$ times a $3times 2 times 2$ output. If the kernel size is $4times 4$ with a stride of $2times 2$ we will get a $3times 1 times 1$ (without padding) output for each of the $K$ filters. The kernel size only influences how large the receptive field of the convolutions are. Hence, it only influences how the layer is scaling the individual dimensions of the width and height (by using RGB images as an example).
If you flatten the output of a layer you will always reduce its dimensionality to $1$. In the dilated convolutional neural network they do not have a layer that flattens the input.
New contributor
$endgroup$
Normally a convolutional neural network will get flattened into a single column vector after the convolutions and then maybe be processed by dense layer. In this model, the convolution $1times1$ is used as an output layer. It will have $C$ channels like every other layer, but it is not dilatated. Hence, you can use this layer as the input to other convolutional neural networks.
The kernel size will not influence the channels. Imagine an RGB image with 4 by 4 pixels. If we have a $2times 2$ convolution with $2times 2$ stride we will get an output of dimension $3times 2 times 2$ (without padding). Hence the channels do not change. If we have $K$ filters we will ket $K$ times a $3times 2 times 2$ output. If the kernel size is $4times 4$ with a stride of $2times 2$ we will get a $3times 1 times 1$ (without padding) output for each of the $K$ filters. The kernel size only influences how large the receptive field of the convolutions are. Hence, it only influences how the layer is scaling the individual dimensions of the width and height (by using RGB images as an example).
If you flatten the output of a layer you will always reduce its dimensionality to $1$. In the dilated convolutional neural network they do not have a layer that flattens the input.
New contributor
edited Mar 20 at 12:51
New contributor
answered Mar 20 at 12:18
MachineLearnerMachineLearner
32410
32410
New contributor
New contributor
$begingroup$
i think, it does not have 3 channels. Number of channels are increased if you actually see.It increased till last layer and Its C in last layers. Am i wrong?
$endgroup$
– InAFlash
Mar 20 at 12:21
$begingroup$
@InAFlash: For the basic network the layer always stays at $C$ channels. I assumed RGB images, hence $C=3$. I corrected this. You could also take any other layer of the basic network and feed it into another network.
$endgroup$
– MachineLearner
Mar 20 at 12:24
$begingroup$
if you see, for large network, its not. And my question was how kernel size is related to number of channels.Thanks
$endgroup$
– InAFlash
Mar 20 at 12:27
1
$begingroup$
@InAFlash I reached the same conclusion. Kernel 1x1 can give C channels, 2C channels, any channels. Just like kernel 3x3, which can give C channels, 32C channels, any channels. So the statement "1x1 because the same channels" seems unjustified in the article.
$endgroup$
– Esmailian
Mar 20 at 12:44
2
$begingroup$
@InAFlash: The author just wants to emphasize that the last layer is not flattened to ensure that the output can be used for other networks. The author could have been more precise in explaining his/her point.
$endgroup$
– MachineLearner
Mar 20 at 12:46
|
show 3 more comments
$begingroup$
i think, it does not have 3 channels. Number of channels are increased if you actually see.It increased till last layer and Its C in last layers. Am i wrong?
$endgroup$
– InAFlash
Mar 20 at 12:21
$begingroup$
@InAFlash: For the basic network the layer always stays at $C$ channels. I assumed RGB images, hence $C=3$. I corrected this. You could also take any other layer of the basic network and feed it into another network.
$endgroup$
– MachineLearner
Mar 20 at 12:24
$begingroup$
if you see, for large network, its not. And my question was how kernel size is related to number of channels.Thanks
$endgroup$
– InAFlash
Mar 20 at 12:27
1
$begingroup$
@InAFlash I reached the same conclusion. Kernel 1x1 can give C channels, 2C channels, any channels. Just like kernel 3x3, which can give C channels, 32C channels, any channels. So the statement "1x1 because the same channels" seems unjustified in the article.
$endgroup$
– Esmailian
Mar 20 at 12:44
2
$begingroup$
@InAFlash: The author just wants to emphasize that the last layer is not flattened to ensure that the output can be used for other networks. The author could have been more precise in explaining his/her point.
$endgroup$
– MachineLearner
Mar 20 at 12:46
$begingroup$
i think, it does not have 3 channels. Number of channels are increased if you actually see.It increased till last layer and Its C in last layers. Am i wrong?
$endgroup$
– InAFlash
Mar 20 at 12:21
$begingroup$
i think, it does not have 3 channels. Number of channels are increased if you actually see.It increased till last layer and Its C in last layers. Am i wrong?
$endgroup$
– InAFlash
Mar 20 at 12:21
$begingroup$
@InAFlash: For the basic network the layer always stays at $C$ channels. I assumed RGB images, hence $C=3$. I corrected this. You could also take any other layer of the basic network and feed it into another network.
$endgroup$
– MachineLearner
Mar 20 at 12:24
$begingroup$
@InAFlash: For the basic network the layer always stays at $C$ channels. I assumed RGB images, hence $C=3$. I corrected this. You could also take any other layer of the basic network and feed it into another network.
$endgroup$
– MachineLearner
Mar 20 at 12:24
$begingroup$
if you see, for large network, its not. And my question was how kernel size is related to number of channels.Thanks
$endgroup$
– InAFlash
Mar 20 at 12:27
$begingroup$
if you see, for large network, its not. And my question was how kernel size is related to number of channels.Thanks
$endgroup$
– InAFlash
Mar 20 at 12:27
1
1
$begingroup$
@InAFlash I reached the same conclusion. Kernel 1x1 can give C channels, 2C channels, any channels. Just like kernel 3x3, which can give C channels, 32C channels, any channels. So the statement "1x1 because the same channels" seems unjustified in the article.
$endgroup$
– Esmailian
Mar 20 at 12:44
$begingroup$
@InAFlash I reached the same conclusion. Kernel 1x1 can give C channels, 2C channels, any channels. Just like kernel 3x3, which can give C channels, 32C channels, any channels. So the statement "1x1 because the same channels" seems unjustified in the article.
$endgroup$
– Esmailian
Mar 20 at 12:44
2
2
$begingroup$
@InAFlash: The author just wants to emphasize that the last layer is not flattened to ensure that the output can be used for other networks. The author could have been more precise in explaining his/her point.
$endgroup$
– MachineLearner
Mar 20 at 12:46
$begingroup$
@InAFlash: The author just wants to emphasize that the last layer is not flattened to ensure that the output can be used for other networks. The author could have been more precise in explaining his/her point.
$endgroup$
– MachineLearner
Mar 20 at 12:46
|
show 3 more comments
Thanks for contributing an answer to Data Science Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
Use MathJax to format equations. MathJax reference.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fdatascience.stackexchange.com%2fquestions%2f47665%2fdoes-convolution-kernel-size-affect-number-of-channels%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown