Max pooling layers have weights. interesting work
In the pytorch tutorial step of " Deep Learning with PyTorch: A 60 Minute Blitz > Neural Networks " 

I have a question that what dose mean params[1] in the networks?

The reason why i have this think is because of max polling dose not have any weight values. 

for example.

If you write some codes like that 
'
def init(self) :
    self.conv1 = nn.Conv2d(1 , 6 , 5)
'

this means input has 1 channel, 6 output channel, conv(5,5)

So i understood that params[0] has  6 channel, 5 by 5 matrix random mapping values when init.

for the same reason

params[2] has like same form, but 16 channel. i understood this too.

but params[1], what dose mean? 

Maybe it is just presentation method of existence for max polling. 

but at the end of this tutorial, in step of the " update the weights " 
It's likely updated by this code below.

learning_rate = 0.01
for f in net.parameters():
    f.data.sub_(f.grad.data * learning_rate)




this is code for construct a network

import torch
import torch.nn as nn
import torch.nn.functional as F


class Net(nn.Module):

    def __init__(self):
        super(Net, self).__init__()
        # 1 input image channel, 6 output channels, 5x5 square convolution
        # kernel
        self.conv1 = nn.Conv2d(1, 6, 5)
        self.conv2 = nn.Conv2d(6, 16, 5)
        # an affine operation: y = Wx + b
        self.fc1 = nn.Linear(16 * 5 * 5, 120)
        self.fc2 = nn.Linear(120, 84)
        self.fc3 = nn.Linear(84, 10)

    def forward(self, x):
        # Max pooling over a (2, 2) window
        x = F.max_pool2d(F.relu(self.conv1(x)), (2, 2))
        # If the size is a square you can only specify a single number
        x = F.max_pool2d(F.relu(self.conv2(x)), 2)
        x = x.view(-1, self.num_flat_features(x))
        x = F.relu(self.fc1(x))
        x = F.relu(self.fc2(x))
        x = self.fc3(x)
        return x

    def num_flat_features(self, x):
        size = x.size()[1:]  # all dimensions except the batch dimension
        num_features = 1
        for s in size:
            num_features *= s
        return num_features




params = list(net.parameters())
print(params[1])




Parameter containing:
tensor([-0.0614, -0.0778,  0.0968, -0.0420,  0.1779, -0.0843],
       requires_grad=True)




please visit this pytorch tutorial site. 
https://pytorch.org/tutorials/beginner/blitz/neural_networks_tutorial.html#sphx-glr-beginner-blitz-neural-networks-tutorial-py



Summary

I have a one question.

that is why max pooling layers has four weights which can be updated ?

I think they shouldn't have any weights right?

Am I wrong?

Please help me. I'm a korean.

You are wrong about that. It has nothing to do with max_pooling.
As you can read in your "linked" Tutorial, is the "nn.paramter"-Tensor automatically registered as parameter when it gets assigned to a Module.

Which, in your case basically, means that everything listed within the __init__ is a module and parameter can be assigned to.

What the values mean inside parameter, well its the parameter your model needs to calculate its steps. to picture it

params[0] -&gt; self.conf1 -&gt; Layer-Input
params[1] -&gt; self.conf1 -&gt; Layer-Output
params[2] -&gt; self.conf2 -&gt; Layer-Input
params[3] -&gt; self.conf2 -&gt; Layer-Output
params[4] -&gt; self.fc1   -&gt; Layer-Input
params[5] -&gt; self.fc1   -&gt; Layer-Output


and so on until you reach params[9], which is the end of your whole parameter list.

EDIT: forgot about the weights
These values are indicator of what your Net has learned.
Therefore you have the ability to alter these values in order to fine-tune your Net to fit your needs.

And if you ask why then 2 rows for each layer?
Well, when you do backpropagation you need these values to locate issues within your Layers.
That's why it stored before passed into a Layer and then after returning from that layer.

hope things are a little clearer now.
