精华内容
下载资源
问答
  • 以resnet18为例子,其每一个layer(也就是basic block)由多个 nn.conv/nn.linear/nn.bn/nn.relu组成,但是在 named_children()里,只会返回最外层的basic block,不会往里面深入,但是named_parameters()正好相反,...

    named_children()主要用于返回神经网打包的第一层的layer名称

    named_parameters()主要用于返回神经网打包的每一层的名字

    以resnet18为例子,其每一个layer(也就是basic block)由多个 nn.conv/nn.linear/nn.bn/nn.relu组成,但是在 named_children()里,只会返回最外层的basic block,不会往里面深入,但是named_parameters()正好相反,会深入进去一个子layer一个子layer的返回。

     

    展开全文
  • children():返回包含直接子模块的迭代器 modules():(递归)返回...named_parameters():返回模块参数上的迭代器,产生参数的名称和参数本身 parameters(): 返回模块参数上的迭代器,不包括名称 import torch.nn .
    children():返回包含直接子模块的迭代器
    modules():(递归)返回包含所有子模块(直接、间接)的迭代器
    named_children() :返回包含直接子模块的迭代器,同时产生模块的名称以及模块本身
    named_modules():返回包含所有子模块(直接、间接)的迭代器,同时产生模块的名称以及模块本身
    named_parameters():返回模块参数上的迭代器,产生参数的名称和参数本身
    parameters(): 返回模块参数上的迭代器,不包括名称
    import torch.nn as nn
    
    
    class AlexNet(nn.Module):
        def __init__(self, num_classes=1000, init_weights=False):
            super(AlexNet, self).__init__()
            self.features = nn.Sequential(
                nn.Conv2d(3, 48, kernel_size=11, stride=4, padding=2),  # input[3, 224, 224]  output[48, 55, 55]
                nn.ReLU(inplace=True),
                nn.MaxPool2d(kernel_size=3, stride=2),                  # output[48, 27, 27]
                nn.Conv2d(48, 128, kernel_size=5, padding=2),           # output[128, 27, 27]
                nn.ReLU(inplace=True),
                nn.MaxPool2d(kernel_size=3, stride=2),                  # output[128, 13, 13]
                nn.Conv2d(128, 192, kernel_size=3, padding=1),          # output[192, 13, 13]
                nn.ReLU(inplace=True),
                nn.Conv2d(192, 192, kernel_size=3, padding=1),          # output[192, 13, 13]
                nn.ReLU(inplace=True),
                nn.Conv2d(192, 128, kernel_size=3, padding=1),          # output[128, 13, 13]
                nn.ReLU(inplace=True),
                nn.MaxPool2d(kernel_size=3, stride=2),                  # output[128, 6, 6]
            )
            self.classifier = nn.Sequential(
                nn.Dropout(p=0.5),
                nn.Linear(128 * 6 * 6, 2048),
                nn.ReLU(inplace=True),
                nn.Dropout(p=0.5),
                nn.Linear(2048, 2048),
                nn.ReLU(inplace=True),
                nn.Linear(2048, num_classes),
            )
            if init_weights:
                self._initialize_weights()
    
        def forward(self, x):
            x = self.features(x)
            x = self.classifier(x)
            return x
    
        def _initialize_weights(self):
            for m in self.modules():
                if isinstance(m, nn.Conv2d):
                    nn.init.kaiming_normal_(m.weight, mode='fan_out', nonlinearity='relu')
                    if m.bias is not None:
                        nn.init.constant_(m.bias, 0)
                elif isinstance(m, nn.Linear):
                    nn.init.normal_(m.weight, 0, 0.01)
                    nn.init.constant_(m.bias, 0)
    
    if __name__ == '__main__':
        
        model = AlexNet()
    
        print('model children: ')
        for module in model.children():
            print(module)
        
        print('model modules: ')
        for module in model.modules():
            print(module)
    
        print('model named children: ')
        for name, module in model.named_children():
            print('name: {}, module: {}'.format(name, module))
        
        print('model named modules: ')
        for name, module in  model.named_modules():
            print('name: {}, module: {}'.format(name, module))
    
        print('model named parameters: ')
        for name, parameter in model.named_parameters():
             print('name: {}, parameter: {}'.format(name, parameter))
    
        print('parameters: ')
        for parameter in model.parameters():
            print('parameter: {}'.format(parameter))
    

     

    展开全文
  • 【pytorch】named_parameters()和parameters()

    万次阅读 多人点赞 2019-10-24 18:57:30
    nn.Module里面关于参数有两个很重要的属性,分别是named_parameters()和parameters(),前者给出网络层的名字和参数的迭代器,而后者仅仅是参数的迭代器。 import torchvision.models as models model = models....

    nn.Module


    nn.Module里面关于参数有两个很重要的属性named_parameters()和parameters(),前者给出网络层的名字和参数的迭代器,而后者仅仅是参数的迭代器。

    import torchvision.models as models
    model = models.resnet18()
    for param in model.named_parameters():
        print(param[0])
    '''
    conv1.weight
    bn1.weight
    bn1.bias
    layer1.0.conv1.weight
    layer1.0.bn1.weight
    layer1.0.bn1.bias
    layer1.0.conv2.weight
    layer1.0.bn2.weight
    layer1.0.bn2.bias
    layer1.1.conv1.weight
    layer1.1.bn1.weight
    layer1.1.bn1.bias
    layer1.1.conv2.weight
    layer1.1.bn2.weight
    layer1.1.bn2.bias
    layer2.0.conv1.weight
    layer2.0.bn1.weight
    layer2.0.bn1.bias
    layer2.0.conv2.weight
    layer2.0.bn2.weight
    layer2.0.bn2.bias
    layer2.0.downsample.0.weight
    layer2.0.downsample.1.weight
    layer2.0.downsample.1.bias
    layer2.1.conv1.weight
    layer2.1.bn1.weight
    layer2.1.bn1.bias
    layer2.1.conv2.weight
    layer2.1.bn2.weight
    layer2.1.bn2.bias
    layer3.0.conv1.weight
    layer3.0.bn1.weight
    layer3.0.bn1.bias
    layer3.0.conv2.weight
    layer3.0.bn2.weight
    layer3.0.bn2.bias
    layer3.0.downsample.0.weight
    layer3.0.downsample.1.weight
    layer3.0.downsample.1.bias
    layer3.1.conv1.weight
    layer3.1.bn1.weight
    layer3.1.bn1.bias
    layer3.1.conv2.weight
    layer3.1.bn2.weight
    layer3.1.bn2.bias
    layer4.0.conv1.weight
    layer4.0.bn1.weight
    layer4.0.bn1.bias
    layer4.0.conv2.weight
    layer4.0.bn2.weight
    layer4.0.bn2.bias
    layer4.0.downsample.0.weight
    layer4.0.downsample.1.weight
    layer4.0.downsample.1.bias
    layer4.1.conv1.weight
    layer4.1.bn1.weight
    layer4.1.bn1.bias
    layer4.1.conv2.weight
    layer4.1.bn2.weight
    layer4.1.bn2.bias
    fc.weight
    fc.bias
    '''
    
    展开全文
  • Pytorch net.parameters() net.named_parameters()

    千次阅读 多人点赞 2020-03-03 16:20:32
    Pytorch net.named_parameters() net.parameters()LeNet网络代码netnet.named_parameters()net.parameters() LeNet网络代码 import torch.nn as nn class LeNet(nn.Module): def __init__(self): super().__...

    Pytorch net.named_parameters() net.parameters()

    LeNet网络代码

    import torch.nn as nn
    
    class LeNet(nn.Module):
        def __init__(self):
            super().__init__()
            self.conv = nn.Sequential(
                nn.Conv2d(1, 6, 5),  # in_channels, out_channels, kernel_size
                nn.Sigmoid(),
    
                nn.MaxPool2d(2, 2),  # kernel_size, stride
                nn.Conv2d(6, 16, 5),
                nn.Sigmoid(),
                nn.MaxPool2d(2, 2)
            )
            self.fc = nn.Sequential(
                nn.Linear(16*4*4, 120),
                nn.Sigmoid(),
                nn.Linear(120, 84),
                nn.Sigmoid(),
                nn.Linear(84, 10)
            )
    
        def forward(self, img):
            feature = self.conv(img)
            output = self.fc(feature.view(img.shape[0], -1))  # img.shape[0]是batch_size
            print(img.size())
            return output
    
    
    net = LeNet()
        
    

    net

    首先打印网络结构,方便与后面的输出相对应

    print(net)
    

    得到输出:

    LeNet(
      (conv): Sequential(
        (0): Conv2d(1, 6, kernel_size=(5, 5), stride=(1, 1))
        (1): Sigmoid()
        (2): MaxPool2d(kernel_size=2, stride=2, padding=0, dilation=1, ceil_mode=False)
        (3): Conv2d(6, 16, kernel_size=(5, 5), stride=(1, 1))
        (4): Sigmoid()
        (5): MaxPool2d(kernel_size=2, stride=2, padding=0, dilation=1, ceil_mode=False)
      )
      (fc): Sequential(
        (0): Linear(in_features=256, out_features=120, bias=True)
        (1): Sigmoid()
        (2): Linear(in_features=120, out_features=84, bias=True)
        (3): Sigmoid()
        (4): Linear(in_features=84, out_features=10, bias=True)
      )
    )
    

    net.named_parameters()

    要想明白net.parameters()的输出含义,可以先查看net.named_parameters()的输出

    print(net.named_parameters())
    

    得到的是

    <generator object Module.named_parameters at 0x11b73e750>
    

    因此这里需要输入以下代码,才能够打印包含名字的网络参数

    print(list(net.named_parameters()))
    

    以下的输出是每层的参数,也就是weight和bias的值。
    conv.0.weight:
    conv表示net输出里的(conv)
    0表示net输出里(conv): Sequential()中的(0)
    weight表示以下的参数是权重

    [('conv.0.weight', Parameter containing:
    tensor([[[[-8.8636e-02, -5.4104e-02, -1.6807e-01,  1.3905e-01,  1.1385e-01],
              [ 1.0389e-02,  5.0412e-03, -1.0014e-01,  5.3664e-02, -1.1828e-01],
              [-1.1662e-01, -5.5687e-02, -4.8703e-02,  4.2012e-03, -1.3929e-01],
              [-1.7217e-01, -1.5523e-01, -2.9062e-02,  1.0240e-01,  7.5030e-02],
              [ 1.1929e-01, -3.9018e-02, -8.0756e-02,  1.2704e-01, -1.7309e-01]]],
    
    
            [[[ 1.5224e-01, -1.0218e-01,  1.5778e-01,  1.2104e-01, -1.3668e-01],
              [ 6.1556e-02,  1.5057e-01, -1.9428e-01, -1.3812e-01,  1.6157e-01],
              [-1.2012e-01, -2.2434e-02,  1.1839e-01, -7.0211e-02, -1.5863e-01],
              [ 1.2586e-01, -1.2948e-01, -1.3422e-01,  1.9126e-01, -1.9191e-01],
              [-5.6562e-02, -1.3261e-01,  1.3623e-01,  2.1545e-02,  2.2253e-03]]],
    
    
            [[[ 9.7525e-02,  4.2834e-02,  1.6527e-01, -6.3074e-02, -1.8211e-01],
              [ 2.6208e-02, -7.8474e-02,  3.1492e-02,  3.0745e-02, -1.5622e-01],
              [ 1.8644e-01, -8.3749e-02, -5.0331e-02, -2.0809e-02,  5.0298e-02],
              [-3.1375e-03,  4.7095e-02, -5.2798e-02, -1.1799e-01,  3.8237e-02],
              [-9.8959e-02,  1.5489e-01, -1.6781e-01,  1.5643e-01,  1.8193e-01]]],
    
    
            [[[-1.9969e-01, -1.9616e-01,  4.1322e-02, -4.8752e-02,  6.8828e-02],
              [-3.2417e-02,  7.9432e-02, -4.5820e-02, -2.5165e-02,  1.5689e-01],
              [-1.2741e-02, -4.1241e-02, -1.7265e-01,  7.3976e-02, -2.0814e-03],
              [-8.7040e-02,  3.3587e-02, -4.3834e-02,  7.3228e-02,  2.8394e-02],
              [-1.7196e-01, -5.3602e-02,  1.3836e-01,  1.9646e-01, -1.5470e-02]]],
    
    
            [[[ 1.8697e-01, -1.5770e-01, -4.9302e-02,  1.7862e-01, -6.5692e-03],
              [ 7.2776e-02, -7.9518e-02,  1.2299e-01, -2.9329e-02, -3.7583e-02],
              [-1.9057e-04,  1.8322e-01, -1.3318e-01, -1.9077e-01,  1.1675e-01],
              [ 1.4141e-01,  1.5589e-02,  1.6407e-01,  3.8352e-02, -1.5713e-01],
              [-1.7429e-01,  5.4862e-03, -1.1978e-02, -1.6020e-01,  1.3761e-01]]],
    
    
            [[[-1.1283e-01,  6.5454e-02, -6.1886e-02,  1.9059e-01,  1.1090e-01],
              [ 7.0462e-04, -1.2329e-01,  1.5751e-01, -8.9370e-03, -1.1800e-01],
              [ 1.1182e-01,  1.9491e-01,  6.6073e-02,  2.9575e-02, -6.4495e-02],
              [ 1.3389e-01,  7.3058e-02, -1.7079e-01, -2.6380e-02, -1.2089e-01],
              [ 2.8565e-02,  1.2921e-01,  4.7769e-02, -5.1232e-02,  1.2332e-01]]]],
           requires_grad=True)), ('conv.0.bias', Parameter containing:
    tensor([-0.1569, -0.0493,  0.0409,  0.1007,  0.1389, -0.1706],
           requires_grad=True)), ('conv.3.weight', Parameter containing:
    tensor([[[[-8.1606e-02,  5.6517e-02,  3.7980e-02,  7.1289e-03, -1.6795e-03],
              [-3.8505e-02,  7.1310e-02,  8.0090e-02, -8.5291e-04,  5.6753e-04],
              [ 7.5145e-02,  5.9544e-02,  7.4619e-02,  8.0373e-02,  1.9402e-03],
              [ 7.1386e-03,  7.0045e-02,  5.3086e-02, -6.2345e-02, -3.0490e-02],
              [-1.1411e-02, -1.2612e-03, -7.2515e-02,  2.7722e-02,  5.4500e-02]],
    
             [[ 3.6355e-02, -5.2609e-02,  2.0863e-02,  8.1126e-02, -2.2495e-02],
              [ 5.1328e-02, -5.7777e-02,  5.4162e-02,  3.5651e-02,  5.0253e-02],
              [-4.6732e-02, -5.3988e-02, -2.8679e-02, -5.2551e-02,  7.9183e-02],
              [-3.5005e-02, -1.4911e-02,  5.6855e-02,  1.2167e-02,  3.8633e-02],
              [-4.7664e-02, -2.7232e-02, -1.8169e-02, -6.6960e-02,  6.9893e-02]],
    
             [[ 4.9951e-02, -2.2711e-02,  3.6998e-02,  7.6405e-02,  4.5189e-02],
              [ 3.1078e-02,  3.1847e-02, -3.3296e-02, -7.8067e-02,  4.3615e-02],
              [-1.2505e-03,  3.5373e-02, -9.4055e-03,  7.3588e-02, -5.5593e-03],
              [-6.9308e-02, -7.8105e-02,  6.4335e-02, -5.2039e-02, -6.3989e-02],
              [ 8.0284e-02, -3.8585e-02, -1.3935e-02, -5.2459e-02, -5.4775e-02]],
    
             [[ 2.2106e-03,  2.0453e-02,  6.1637e-02,  6.3764e-03, -5.4513e-02],
              [ 5.9659e-02, -6.9712e-02,  3.2351e-02,  3.3611e-02, -3.6049e-02],
              [ 6.9126e-02, -6.9778e-03, -5.8808e-02, -4.1064e-02, -4.7523e-02],
              [-3.6793e-02,  5.7714e-02, -1.2878e-02, -4.2567e-02,  6.5369e-02],
              [-2.9562e-02,  7.0471e-02, -5.8229e-02,  4.9423e-02,  2.7774e-02]],
    
             [[-3.3261e-02, -7.3599e-02, -1.8584e-02, -4.3785e-03, -5.4702e-02],
              [ 3.2309e-02, -7.5739e-02, -2.9777e-02,  1.7663e-02, -6.5562e-02],
              [ 6.7899e-02, -1.3923e-02,  3.0347e-02,  1.4216e-02,  6.5675e-02],
              [ 2.8668e-02,  2.3815e-02,  5.0514e-02, -9.1128e-03,  5.7252e-02],
              [ 6.3323e-02,  6.3442e-02, -6.4325e-03, -2.9608e-02, -5.5236e-02]],
    
             [[-5.8466e-02,  1.2493e-02, -6.8115e-02,  3.5759e-02,  2.5229e-02],
              [ 4.6055e-02,  3.4923e-02, -4.5888e-02, -4.1145e-02, -3.6031e-04],
              [ 2.7006e-02,  5.9143e-02,  9.8830e-04,  6.6686e-02, -3.1338e-02],
              [-4.3125e-04,  3.4901e-02,  2.0099e-02,  3.1618e-02,  4.1894e-02],
              [ 4.5899e-02, -1.9047e-02,  7.2343e-02,  5.8369e-02, -7.4171e-02]]],
    
    
            [[[-7.9133e-03,  5.1656e-02, -3.5519e-02, -4.9966e-02, -5.8925e-02],
              [-7.4133e-02,  4.1549e-02,  7.7260e-02,  3.7351e-02,  7.5228e-02],
              [ 6.1724e-03, -5.9819e-03, -3.4627e-02, -1.0032e-02, -5.2541e-02],
              [ 5.2386e-02, -6.7341e-02,  6.2119e-02, -4.2592e-03, -2.0209e-02],
              [-2.6972e-02, -3.9151e-02, -7.4550e-02,  5.7551e-02,  7.7260e-02]],
    
             [[-7.3542e-02,  3.6349e-02,  7.2762e-03, -2.9392e-03,  1.4807e-02],
              [-4.2594e-02, -5.6298e-02,  9.3442e-03,  5.4366e-02,  7.5989e-02],
              [-1.4330e-02, -6.9494e-02, -3.2833e-02,  3.1482e-02, -3.3901e-02],
              [ 5.2219e-02,  5.2125e-02,  5.3030e-02, -4.9283e-02, -5.3845e-02],
              [-2.7706e-02, -1.0472e-02,  1.7281e-02, -2.7444e-02, -7.9160e-02]],
    
             [[ 4.9099e-02,  1.0697e-02,  6.0691e-03,  6.4281e-02,  5.5378e-02],
              [ 5.0477e-02, -2.6998e-02,  1.8624e-02, -5.6737e-02, -6.0127e-02],
              [-6.6349e-02,  8.1591e-02,  5.7090e-02,  1.7639e-02,  2.4535e-02],
              [-2.0789e-02,  2.0118e-02, -5.6663e-02, -3.5079e-02, -5.3758e-02],
              [ 1.7683e-02, -7.8950e-02, -5.8404e-02,  1.9304e-02, -3.3575e-02]],
    
             [[ 2.0013e-02,  5.3189e-03,  9.1200e-03,  3.4255e-02,  2.4117e-02],
              [-5.3307e-02, -2.5417e-02,  7.1637e-02, -4.5948e-02,  6.4015e-02],
              [ 7.5321e-02,  3.7049e-02, -3.1390e-03,  5.8623e-03, -7.9563e-02],
              [ 7.1531e-02, -6.2800e-02,  3.6092e-02, -1.4182e-02,  2.7799e-02],
              [-4.4354e-02,  2.3893e-03,  2.2665e-02,  5.6520e-02,  1.7836e-02]],
    
             [[-6.4659e-04,  7.6453e-02, -1.0496e-02,  6.7064e-02, -7.1402e-02],
              [ 2.4126e-02, -8.6234e-03,  5.4490e-02,  2.1146e-02, -1.0601e-02],
              [-5.2156e-02, -2.8523e-02, -5.8706e-02,  2.3795e-02, -1.4744e-02],
              [-4.4707e-02,  8.9603e-03, -6.2387e-03, -3.9253e-02, -6.3208e-02],
              [-8.0869e-02, -1.6241e-02, -2.3223e-02,  7.0673e-02, -8.0446e-02]],
    
             [[ 7.0747e-02, -1.7346e-02,  1.4652e-02, -6.3726e-02,  4.7596e-02],
              [ 8.1330e-02, -5.3212e-02, -7.8493e-02, -4.2923e-02,  7.1303e-02],
              [ 6.4165e-02, -7.8016e-02,  4.0650e-02,  5.2306e-02,  5.2612e-02],
              [-6.6639e-02, -5.0998e-02,  4.0801e-02,  3.2819e-02,  7.8599e-02],
              [-3.4159e-03, -6.6933e-02, -7.8798e-02, -4.2861e-03,  3.3939e-02]]],
    
    
            [[[ 2.9057e-02,  7.8674e-02,  2.6640e-02, -6.5638e-02,  7.1691e-02],
              [-3.6320e-03,  9.2064e-03,  8.0678e-02, -7.1757e-02, -6.4250e-02],
              [-3.5652e-02,  5.1536e-02, -3.9010e-02, -9.9717e-03, -2.4651e-02],
              [ 4.4784e-02, -5.9128e-02, -1.5783e-02,  5.5110e-02,  7.5619e-02],
              [-2.0860e-02, -3.2277e-02, -3.6883e-02, -7.7483e-02, -5.3197e-02]],
    
             [[ 3.0969e-02,  4.1981e-02,  7.4213e-02,  2.8428e-02, -5.0689e-02],
              [ 5.6840e-02,  7.0659e-02, -4.6760e-03, -1.0036e-02, -6.5950e-02],
              [ 2.2974e-02, -6.7547e-02,  4.3048e-02, -4.0016e-02, -7.0425e-02],
              [-5.1536e-02, -2.8084e-02,  1.2433e-02,  7.3716e-02, -1.9252e-02],
              [ 5.5877e-02,  6.8212e-03,  3.3441e-02,  2.3014e-03, -4.9605e-02]],
    
             [[-5.4105e-02,  7.8060e-02,  4.7589e-02,  6.0019e-02,  1.7158e-02],
              [ 2.9694e-02, -7.1154e-02,  1.2766e-02,  5.7769e-02,  5.8098e-02],
              [-3.0980e-02,  7.7493e-02,  1.6189e-02, -4.0631e-02, -3.8438e-02],
              [ 2.8856e-02, -1.8172e-02,  1.1402e-02, -7.2744e-02, -5.6305e-02],
              [ 7.0353e-02,  7.3662e-02, -4.0003e-02,  7.0668e-03, -4.5813e-02]],
    
             [[-2.2399e-02, -4.7097e-02, -2.7818e-02, -5.3087e-02,  4.8572e-02],
              [-3.1414e-02, -5.3070e-02, -3.0830e-02,  6.5263e-02, -1.3606e-02],
              [-5.5188e-02,  7.2686e-02, -4.3698e-02, -7.3788e-02,  5.6790e-02],
              [ 3.3700e-02, -5.0935e-02, -8.0748e-02, -4.1992e-03,  5.5900e-02],
              [ 2.3919e-02, -6.4706e-02,  1.7562e-02, -3.8950e-02,  1.2322e-02]],
    
             [[-1.0331e-02,  1.3683e-02, -2.8881e-02, -3.8759e-02,  5.1845e-02],
              [ 2.7440e-03,  4.7079e-02,  4.0827e-02,  7.7843e-02,  1.0119e-02],
              [-5.7995e-02,  3.4244e-02,  1.4462e-02,  5.6099e-02, -5.6893e-02],
              [-4.7045e-02,  8.0138e-02, -3.4818e-02,  9.5591e-03,  7.4453e-02],
              [-5.2745e-02, -3.4472e-02, -4.6170e-02, -2.1359e-02, -3.5049e-02]],
    
             [[ 1.6154e-02, -5.3620e-02,  2.4113e-02, -2.9533e-02, -1.9857e-02],
              [-4.6417e-02, -2.2675e-02,  6.2978e-03,  6.4346e-02,  3.3277e-02],
              [-2.4742e-02,  1.6745e-03,  1.9269e-02, -3.2509e-02, -3.2720e-02],
              [-7.1782e-03,  7.3785e-02, -3.3636e-02, -5.2071e-02,  1.3959e-02],
              [-1.1213e-02, -2.6289e-02,  2.6017e-02, -1.6679e-02, -5.6544e-02]]],
    
    
            ...,
    
    
            [[[ 1.1637e-02,  1.5615e-03, -3.4414e-02,  6.5634e-02, -4.7697e-02],
              [ 4.2352e-02, -6.5357e-02, -5.2337e-02,  5.7050e-02, -2.4126e-03],
              [ 4.0806e-02, -7.7452e-02, -9.3113e-03,  4.2078e-02,  6.5509e-02],
              [ 6.4601e-02,  3.9354e-02, -2.5164e-02,  4.5652e-03, -4.8777e-02],
              [ 5.4610e-02,  5.8368e-02, -2.4036e-02,  4.3921e-02, -2.7958e-02]],
    
             [[-5.1989e-02, -5.4994e-02, -1.1902e-02,  5.8946e-02, -4.3654e-03],
              [ 1.6891e-02, -3.1257e-02, -7.4797e-02, -6.6190e-02,  2.3538e-02],
              [-4.5497e-02, -3.9984e-02,  3.5387e-02,  6.8001e-02,  5.4936e-02],
              [-6.6888e-02,  2.3405e-02, -5.1077e-02,  6.2742e-02,  4.4172e-02],
              [-1.2571e-02, -2.6557e-03, -7.3533e-02, -1.0317e-02, -8.1154e-02]],
    
             [[ 2.3487e-03,  2.1654e-02,  6.6065e-02,  6.8397e-02, -6.4369e-02],
              [-8.8182e-03,  3.8768e-03, -5.8391e-02,  6.3886e-02,  2.8651e-02],
              [-2.1654e-02,  7.9269e-02, -6.4918e-02,  1.0130e-02,  6.3641e-02],
              [ 9.7113e-03,  5.4602e-02,  1.6673e-02, -5.8576e-02, -4.8172e-02],
              [-3.4011e-03,  4.6585e-02, -3.8083e-02,  7.2888e-02,  8.0656e-02]],
    
             [[-1.1187e-02, -1.7829e-02,  9.3983e-03, -4.3138e-02,  3.3797e-02],
              [ 3.5487e-02,  2.2197e-02,  4.3617e-02,  1.0557e-02, -4.2417e-02],
              [ 6.1524e-02, -7.4790e-02, -3.2217e-02, -4.6766e-02, -6.2434e-02],
              [ 3.6386e-02, -3.3663e-02, -4.5587e-02,  3.8595e-02,  1.6727e-02],
              [-1.8531e-02,  1.3820e-02,  7.2793e-02,  1.1807e-02, -3.8950e-02]],
    
             [[-6.1918e-02, -7.9466e-02,  7.8415e-02, -6.5235e-02, -3.6512e-02],
              [ 2.2598e-02, -1.8896e-02, -3.2385e-04, -4.2461e-02,  5.8245e-02],
              [ 7.7946e-02,  6.8326e-02, -5.7772e-02,  1.6144e-02, -7.9856e-03],
              [ 4.2590e-02, -2.4582e-02,  7.0983e-02, -2.1786e-02, -6.8048e-02],
              [-6.1146e-02,  7.8727e-02,  2.2890e-02,  3.3337e-02, -2.4320e-02]],
    
             [[-2.1410e-03,  2.3616e-02,  6.6877e-02,  7.1799e-02,  3.1102e-02],
              [-6.9160e-02, -1.8230e-02,  4.4417e-02,  9.5311e-03,  5.4292e-02],
              [-1.2988e-02,  6.1585e-02,  4.0756e-02, -7.8522e-02, -2.3632e-02],
              [ 6.3432e-02, -7.7516e-02,  7.8302e-02, -5.9311e-02, -2.2224e-02],
              [-7.2295e-02,  2.1220e-02,  2.1197e-03, -6.7028e-02, -8.0373e-02]]],
    
    
            [[[-6.0983e-02, -6.6257e-02,  3.6482e-02,  6.4058e-02,  6.3727e-02],
              [-1.6197e-03, -3.7426e-02,  1.9008e-02, -2.1375e-02, -5.6982e-02],
              [ 6.1375e-02, -6.2545e-02,  2.1644e-02, -4.5784e-02, -5.8636e-02],
              [ 3.1320e-02,  7.3044e-02,  7.7667e-02,  2.4922e-02,  6.3110e-02],
              [ 1.0242e-02, -5.5940e-03, -6.8011e-02, -6.9326e-02,  8.0235e-04]],
    
             [[ 7.2221e-02, -5.1861e-03,  2.6631e-02, -1.0368e-02,  7.2901e-02],
              [-7.6432e-02, -4.5672e-02, -2.4825e-03, -6.8752e-02, -5.4525e-02],
              [-4.5188e-02,  1.4513e-02,  5.7384e-02, -7.3025e-02, -3.1181e-02],
              [ 3.4508e-02, -4.4255e-02,  8.0517e-02,  6.8251e-02, -1.7235e-03],
              [ 3.9071e-02, -1.2984e-02, -4.1737e-02, -1.5829e-02,  7.6925e-02]],
    
             [[ 7.2747e-02,  7.2952e-02,  6.8089e-02, -2.9644e-02, -3.6298e-02],
              [-4.7840e-03,  8.0953e-02, -1.7395e-03,  3.9285e-02, -2.1554e-02],
              [ 3.0159e-02, -2.7749e-03,  5.1660e-02, -7.9726e-02,  9.9364e-03],
              [ 7.9998e-02,  4.4609e-03, -5.0227e-02, -5.5143e-02, -7.5387e-02],
              [ 7.7339e-02,  5.7260e-02,  3.4882e-02, -5.8889e-02, -1.5042e-02]],
    
             [[-2.9576e-02,  7.6208e-02, -5.7225e-02,  8.7695e-03,  3.6609e-02],
              [ 5.0222e-02,  5.9568e-02,  6.9107e-02, -1.5020e-04, -1.9051e-02],
              [ 5.3948e-02, -1.9289e-02, -5.2382e-02, -5.1973e-02,  1.6765e-02],
              [-6.4184e-02,  8.3054e-03,  1.1778e-02,  6.3767e-02,  6.9911e-02],
              [-9.9837e-03, -5.1808e-03, -5.2055e-02, -6.5044e-02,  3.1634e-03]],
    
             [[-9.5595e-03, -5.1981e-03,  5.3636e-02, -3.3507e-02, -2.9453e-02],
              [ 7.2595e-02,  3.7434e-02, -2.7572e-02, -6.2916e-02,  2.6549e-02],
              [-3.1721e-02, -1.4896e-02, -7.3778e-02, -3.9089e-03,  2.4423e-02],
              [ 2.9365e-02,  4.9271e-02,  6.2599e-02, -1.9325e-02,  4.5338e-02],
              [-7.8843e-02, -1.5090e-03, -4.5780e-02,  3.3896e-02,  7.6286e-02]],
    
             [[ 2.3264e-02, -5.3412e-02, -2.8306e-02, -3.4297e-02,  2.7167e-02],
              [-6.0756e-02, -8.0306e-02,  3.7120e-02, -7.2227e-02,  6.1372e-03],
              [ 5.9604e-02, -2.3899e-02, -9.3569e-03,  6.7534e-02, -7.2318e-03],
              [ 4.3411e-02,  2.5641e-02,  1.6221e-02,  7.0628e-02,  6.4845e-02],
              [ 2.4075e-02, -7.1725e-02, -4.1964e-02, -4.3935e-02, -7.6464e-02]]],
    
    
            [[[-2.0652e-02,  2.2253e-02,  1.5340e-02, -4.5987e-02,  6.9745e-03],
              [ 5.7219e-02,  3.6921e-02,  8.1705e-03, -8.1357e-02, -5.9346e-02],
              [ 8.0237e-02, -2.0576e-02,  4.8090e-02,  1.0069e-02, -6.1285e-02],
              [-4.7972e-02,  4.3851e-02,  5.7308e-02, -7.4966e-02,  3.6584e-03],
              [-5.4083e-02, -2.3608e-02, -3.9667e-02, -5.2193e-02, -6.5460e-02]],
    
             [[ 3.8592e-02, -4.7983e-03,  7.0038e-02, -2.8209e-02,  5.9367e-02],
              [ 5.1646e-02,  3.8123e-02, -4.7679e-02, -1.2986e-02, -7.1070e-02],
              [-7.5278e-02,  1.7155e-02, -6.5242e-02, -7.0537e-02,  4.4725e-02],
              [-1.6702e-03, -4.6572e-02,  1.3320e-02,  9.8712e-03,  3.1747e-02],
              [ 3.3593e-02,  5.7261e-02,  4.5890e-02,  7.0425e-02,  5.3375e-02]],
    
             [[ 6.3588e-02,  5.5896e-02, -5.7100e-02, -7.4458e-02, -6.4169e-02],
              [-5.9793e-02,  1.9769e-02,  2.0071e-02, -6.3158e-02, -3.7733e-02],
              [ 1.3933e-02,  1.9316e-02,  6.0856e-02, -5.5083e-02,  7.7425e-02],
              [-5.8985e-02,  5.7563e-02, -4.4495e-02,  6.8086e-02, -5.2516e-02],
              [ 2.0068e-02,  7.9942e-02, -1.7929e-02,  4.1146e-02,  1.5138e-02]],
    
             [[ 7.9311e-02,  7.6693e-02,  7.0406e-02,  8.1483e-02,  4.7786e-02],
              [-6.5279e-02, -5.6771e-02,  1.2932e-02, -8.1506e-02,  7.0764e-02],
              [-2.3507e-02, -7.5392e-02,  7.5387e-02, -1.7596e-02,  7.5220e-02],
              [-4.7615e-02, -6.2142e-03, -5.1475e-02,  5.9507e-03,  4.6127e-05],
              [-3.4649e-02, -5.8557e-02,  4.9961e-02, -2.5942e-03,  1.8716e-02]],
    
             [[ 7.2308e-02, -8.8122e-03, -1.4296e-02,  5.7393e-02,  5.2996e-02],
              [-6.8959e-02, -5.2348e-02,  1.3180e-04, -3.8515e-02,  7.3680e-02],
              [ 2.2597e-02,  1.4609e-02,  2.7885e-02, -3.4467e-02, -3.8827e-02],
              [ 6.5662e-02,  4.7475e-02,  7.7546e-02, -2.5861e-02, -5.7741e-02],
              [-4.9320e-02,  7.6375e-02, -1.4802e-02,  2.5327e-02, -6.6786e-03]],
    
             [[ 1.1758e-02,  8.1082e-03, -6.9590e-03, -2.6507e-02, -6.1292e-02],
              [ 4.2475e-02, -6.5175e-02, -4.8014e-03,  4.9688e-03,  8.1439e-02],
              [-2.5271e-03, -5.0296e-02,  9.1219e-03, -7.5870e-02,  2.4128e-02],
              [ 6.7473e-02, -1.9677e-02,  2.6301e-02, -5.2330e-02, -1.7758e-02],
              [-1.4710e-02, -4.8149e-02,  1.7658e-02,  1.9943e-02, -1.6895e-02]]]],
           requires_grad=True)), ('conv.3.bias', Parameter containing:
    tensor([-0.0702,  0.0606, -0.0536,  0.0620,  0.0717, -0.0674, -0.0654, -0.0770,
             0.0231, -0.0509, -0.0566,  0.0079,  0.0022, -0.0534, -0.0337, -0.0775],
           requires_grad=True)), ('fc.0.weight', Parameter containing:
    tensor([[ 0.0159, -0.0371,  0.0378,  ...,  0.0093,  0.0353,  0.0607],
            [-0.0203, -0.0387, -0.0447,  ..., -0.0284,  0.0118, -0.0541],
            [ 0.0590, -0.0559, -0.0156,  ...,  0.0023, -0.0222,  0.0342],
            ...,
            [-0.0406,  0.0036, -0.0081,  ..., -0.0049,  0.0018, -0.0188],
            [-0.0358, -0.0212,  0.0519,  ..., -0.0128,  0.0319,  0.0548],
            [-0.0157,  0.0120, -0.0231,  ..., -0.0580,  0.0269,  0.0582]],
           requires_grad=True)), ('fc.0.bias', Parameter containing:
    tensor([-3.3901e-02,  5.7599e-02,  5.8267e-02,  1.7830e-02, -5.1649e-02,
             4.0259e-02, -1.9012e-02,  1.0298e-02,  3.2938e-02,  4.9630e-02,
            -5.6957e-02,  1.9368e-02, -3.6316e-02,  4.9815e-02, -3.3624e-02,
            -4.1501e-03, -4.6522e-02,  7.8386e-03,  8.3237e-03, -3.1134e-02,
             2.3826e-03,  5.9818e-02,  3.5538e-02,  4.7671e-02,  2.2528e-03,
             9.3094e-03, -4.9968e-02, -3.1453e-02,  1.2352e-02, -1.2431e-02,
             5.7654e-03, -4.4617e-02,  3.4665e-02, -4.1069e-02,  8.4864e-03,
             5.7303e-02, -4.8938e-02,  3.5895e-02, -4.5507e-02,  4.9761e-02,
            -2.9288e-02, -2.3534e-03,  4.6395e-05, -2.3313e-02,  2.1920e-02,
             2.1869e-02,  1.7702e-02, -2.5555e-02, -4.7335e-02, -4.7246e-02,
            -5.6174e-02, -9.7506e-04,  2.2077e-02,  1.7203e-02,  1.4453e-02,
            -4.2847e-03, -4.3256e-02, -1.2058e-02, -5.9208e-02,  1.1217e-02,
             3.9915e-02,  1.3976e-02, -7.4786e-03,  2.9575e-02, -3.1721e-02,
             1.6793e-02,  4.6533e-02,  4.5678e-02,  7.5828e-03,  4.1046e-02,
             8.4193e-03, -1.9514e-02,  2.9999e-02, -2.4217e-02,  4.7124e-02,
            -3.0769e-02,  4.9844e-02, -2.4045e-02,  3.7988e-03, -4.4264e-02,
             1.9213e-02, -5.8554e-02,  1.2669e-02,  8.5825e-03,  1.3858e-02,
            -9.6001e-03,  1.3741e-04,  3.2660e-02, -2.1534e-02,  1.6865e-02,
             5.9487e-02, -4.9386e-02, -2.8125e-02, -6.0020e-03, -5.7307e-02,
            -5.9333e-02, -4.4663e-02,  1.0370e-03, -1.4558e-02,  5.0601e-02,
             3.5963e-02,  1.1968e-03, -2.4735e-02,  4.5201e-03,  3.7886e-02,
            -5.3356e-02,  1.9783e-02, -1.4649e-02, -5.5926e-02,  3.2705e-02,
            -4.2774e-02, -3.5712e-03,  1.2812e-02,  1.9321e-02, -3.2243e-02,
            -9.0156e-03,  2.4989e-02,  1.8990e-02,  2.0760e-02,  1.7085e-02],
           requires_grad=True)), ('fc.2.weight', Parameter containing:
    tensor([[-0.0626,  0.0894,  0.0771,  ...,  0.0041, -0.0329, -0.0883],
            [ 0.0146,  0.0010, -0.0848,  ...,  0.0638,  0.0241, -0.0215],
            [ 0.0265, -0.0158, -0.0049,  ...,  0.0356, -0.0440, -0.0355],
            ...,
            [-0.0487,  0.0631,  0.0736,  ...,  0.0154, -0.0202, -0.0669],
            [-0.0590,  0.0139,  0.0485,  ...,  0.0161, -0.0497, -0.0838],
            [ 0.0124,  0.0018,  0.0637,  ..., -0.0333, -0.0420,  0.0648]],
           requires_grad=True)), ('fc.2.bias', Parameter containing:
    tensor([ 0.0676,  0.0825,  0.0304,  0.0424,  0.0556, -0.0198,  0.0051,  0.0052,
            -0.0285,  0.0289, -0.0660,  0.0138, -0.0588, -0.0872, -0.0199, -0.0176,
            -0.0757,  0.0554,  0.0090, -0.0121,  0.0840, -0.0341, -0.0904,  0.0319,
            -0.0272, -0.0833,  0.0671,  0.0837, -0.0077,  0.0036, -0.0478, -0.0490,
            -0.0150,  0.0168, -0.0494, -0.0367, -0.0666, -0.0790,  0.0797, -0.0726,
            -0.0587, -0.0598,  0.0053,  0.0750, -0.0713, -0.0493, -0.0825, -0.0201,
            -0.0558,  0.0299, -0.0214, -0.0588, -0.0011,  0.0691,  0.0069,  0.0359,
            -0.0765,  0.0257,  0.0157,  0.0117,  0.0013, -0.0649, -0.0199,  0.0276,
            -0.0509, -0.0130, -0.0648,  0.0893,  0.0108,  0.0771,  0.0300,  0.0136,
             0.0331,  0.0723, -0.0078,  0.0474, -0.0481, -0.0252, -0.0167, -0.0737,
            -0.0056,  0.0461,  0.0660, -0.0659], requires_grad=True)), ('fc.4.weight', Parameter containing:
    tensor([[ 0.0191, -0.0260, -0.0460, -0.1049,  0.0700,  0.0128, -0.0908, -0.0029,
             -0.0314, -0.0897,  0.1043, -0.0443, -0.0024, -0.1001,  0.0567, -0.0743,
             -0.0062,  0.0499,  0.0044,  0.0538, -0.0724, -0.0304,  0.0526, -0.0728,
             -0.0661, -0.0555,  0.1073,  0.0430,  0.1084,  0.1069, -0.0532, -0.0324,
             -0.0792, -0.0562, -0.0413,  0.0475, -0.0584, -0.0608, -0.0685,  0.0974,
              0.1013,  0.0998, -0.0233, -0.0692, -0.0295,  0.0643,  0.0257, -0.0795,
              0.0043,  0.0522, -0.1027,  0.0214,  0.0751,  0.0454,  0.0147, -0.0349,
             -0.0773,  0.0580, -0.0670, -0.0264,  0.0443, -0.0210,  0.0973,  0.0310,
             -0.0559, -0.0293,  0.0259, -0.0383,  0.0420,  0.0487,  0.0860,  0.0126,
              0.1073, -0.0848, -0.0335,  0.1079,  0.0057, -0.1078, -0.0332,  0.0599,
             -0.0092,  0.0918,  0.0769,  0.0502],
            [ 0.0513,  0.0594, -0.0095, -0.0214,  0.0731, -0.0032, -0.0868,  0.0095,
              0.0589,  0.0920, -0.1091,  0.0521,  0.0525,  0.0147, -0.0042, -0.0148,
              0.0493, -0.0882, -0.0869, -0.0635,  0.0540,  0.0493, -0.0620, -0.0237,
             -0.0498,  0.0577, -0.1042, -0.0349, -0.0021, -0.0556,  0.0208,  0.0295,
             -0.0397, -0.0856,  0.0980, -0.0803,  0.0987, -0.0563, -0.0853,  0.0843,
             -0.0091,  0.0320,  0.0736, -0.0358,  0.0282, -0.0274,  0.0529,  0.0642,
             -0.1002, -0.0310, -0.0537,  0.0007, -0.0671, -0.0057, -0.0470, -0.0767,
              0.0194, -0.0125, -0.0815,  0.0275,  0.0657,  0.0563, -0.0356, -0.0799,
              0.0341,  0.0903, -0.1061, -0.0809,  0.0406,  0.0324,  0.1044,  0.0470,
              0.0760,  0.0471,  0.0420,  0.0173, -0.0760, -0.0715, -0.0167, -0.0596,
              0.0523,  0.0266, -0.0157,  0.0345],
            [-0.0190,  0.0964, -0.0926, -0.0736,  0.0447,  0.0189, -0.0633, -0.0210,
              0.0635,  0.0080, -0.0514, -0.0834, -0.0908,  0.0103, -0.0763, -0.0976,
              0.0176, -0.0999,  0.0804, -0.0509, -0.0308, -0.0606, -0.0260,  0.1039,
              0.0489, -0.1065, -0.0254, -0.0731, -0.0601, -0.0430,  0.0014, -0.0825,
              0.0783,  0.0757, -0.0520, -0.0831, -0.0671, -0.0920,  0.0220, -0.0795,
             -0.0616,  0.0121, -0.0424, -0.0571,  0.0545,  0.0752,  0.0559, -0.0785,
              0.0456,  0.0220,  0.0293, -0.0171, -0.0716,  0.0855,  0.1035, -0.0726,
             -0.0374,  0.0173, -0.0770,  0.0961, -0.1028,  0.0229,  0.0580, -0.0735,
             -0.0022, -0.0767,  0.0457,  0.0339,  0.0983,  0.0646,  0.0243,  0.0802,
              0.0501,  0.0286, -0.0448,  0.0152, -0.0917, -0.0588,  0.0694,  0.0520,
             -0.0411,  0.0699, -0.1033, -0.0859],
            [ 0.1053,  0.0370,  0.0090,  0.1046,  0.0309,  0.1042,  0.0182,  0.0339,
             -0.0976,  0.1052,  0.0311, -0.0426,  0.0893, -0.0945,  0.0130, -0.0149,
              0.0378, -0.0901, -0.0961,  0.0442,  0.0122, -0.0548,  0.0570,  0.1071,
              0.0862, -0.1005,  0.1087,  0.0473,  0.0199,  0.0217,  0.0869,  0.0344,
              0.0415,  0.0236,  0.1015,  0.0792, -0.0900, -0.0470,  0.0968, -0.0274,
              0.0993, -0.0196,  0.1034, -0.0316,  0.0368,  0.0849,  0.0544, -0.0809,
             -0.0151, -0.0097,  0.0826,  0.0761, -0.0096, -0.0594, -0.0372,  0.0646,
             -0.0437, -0.0526, -0.0935, -0.0304, -0.0198,  0.0378,  0.0695, -0.0641,
             -0.0268,  0.0602,  0.0772,  0.0278, -0.0706, -0.0269,  0.0746,  0.0712,
             -0.0177, -0.0523,  0.0359, -0.0423,  0.0141,  0.0546,  0.0226, -0.0050,
             -0.0371, -0.0024,  0.0053, -0.0809],
            [-0.0027,  0.0827,  0.0257,  0.0511,  0.1010,  0.0480,  0.0107,  0.0401,
              0.1044,  0.0006, -0.0995,  0.0593, -0.0560, -0.0416, -0.0953,  0.0174,
              0.0804,  0.0895, -0.0782, -0.0424,  0.0026,  0.0822,  0.0927,  0.0642,
             -0.0497,  0.0639, -0.0355, -0.0125,  0.0273, -0.1010,  0.0823, -0.0544,
             -0.0408,  0.0623,  0.0340,  0.0643, -0.0352, -0.0710, -0.1045, -0.0744,
             -0.0068,  0.0102, -0.0282, -0.0823, -0.1017,  0.0178,  0.0379, -0.1039,
              0.0840,  0.0532, -0.0081,  0.1043,  0.0839, -0.0032,  0.0296,  0.0320,
              0.0955, -0.0168,  0.0363,  0.0968, -0.0305, -0.0226, -0.0498,  0.0061,
              0.0072, -0.0152, -0.0191,  0.0598, -0.0745,  0.0352,  0.0745,  0.0149,
             -0.0694, -0.0117, -0.0982,  0.0424,  0.0513,  0.0078, -0.0399, -0.0758,
             -0.0470,  0.0389, -0.0362,  0.0205],
            [-0.0214, -0.0845,  0.0791, -0.0713, -0.0274,  0.0129,  0.0733,  0.0209,
             -0.0964,  0.0201,  0.0219, -0.0426, -0.0410,  0.0660,  0.0291,  0.0992,
             -0.0844, -0.0184,  0.0014,  0.0922, -0.0784,  0.0463,  0.0466, -0.0621,
              0.0847,  0.0856,  0.0844,  0.0864, -0.0717,  0.0795,  0.0341, -0.1012,
             -0.0297,  0.0765, -0.0812, -0.0263,  0.0251,  0.0586,  0.0633, -0.0506,
             -0.1003, -0.0866, -0.0940,  0.0927,  0.0335, -0.0461,  0.0097,  0.0460,
              0.0368, -0.0543, -0.0626, -0.0898, -0.1065,  0.1035, -0.0533, -0.0096,
              0.0649,  0.0594,  0.0150, -0.0848, -0.0515,  0.0738,  0.0319,  0.0676,
             -0.0109, -0.0249, -0.0558, -0.0937,  0.0071, -0.0809, -0.0892,  0.0144,
              0.0708, -0.0940, -0.0281, -0.0235,  0.0517,  0.0843, -0.0213, -0.0472,
             -0.1058, -0.0374,  0.0547, -0.0960],
            [-0.0997,  0.0629, -0.0211,  0.0536,  0.1049,  0.0890,  0.0076,  0.0556,
             -0.0620,  0.0278, -0.0050, -0.0873,  0.0484,  0.0631, -0.1027, -0.0146,
             -0.0215,  0.0388, -0.0115,  0.1068,  0.0531, -0.0542,  0.0191,  0.0268,
              0.0507, -0.0859,  0.0178, -0.0204,  0.0201,  0.0863,  0.1038, -0.0587,
              0.1036, -0.0273, -0.1073, -0.0443, -0.0308,  0.0907,  0.0668,  0.0694,
             -0.0606, -0.0002, -0.0311,  0.1058, -0.0919,  0.0853, -0.0023, -0.0167,
              0.1061, -0.0608,  0.0556,  0.0347, -0.0416, -0.0016, -0.0359,  0.0321,
              0.0687, -0.0290, -0.0014,  0.0901,  0.0691, -0.0477,  0.0730,  0.0842,
             -0.0223, -0.0550, -0.0195, -0.0244,  0.0125,  0.0025, -0.0996, -0.0470,
              0.0829,  0.0629, -0.0829, -0.0030, -0.0415,  0.0026, -0.0466,  0.0363,
             -0.0992,  0.0510,  0.0169,  0.0320],
            [-0.0248, -0.0139, -0.0761, -0.0894,  0.0212, -0.0247, -0.0440, -0.0746,
             -0.0118,  0.0825, -0.0250, -0.0997,  0.0852, -0.0099, -0.1007, -0.0511,
             -0.1063, -0.0007, -0.0062, -0.0211,  0.0043, -0.0689, -0.0860,  0.0824,
             -0.1015, -0.0303,  0.0814,  0.1055, -0.0114, -0.0563,  0.0173, -0.0601,
              0.1059,  0.0887,  0.0810,  0.0692, -0.1023, -0.0522, -0.0273, -0.0777,
             -0.0697,  0.0056, -0.0857, -0.1009,  0.0027,  0.0354, -0.0625, -0.0510,
             -0.0361, -0.1084,  0.0471,  0.0220,  0.0206,  0.0760,  0.0155, -0.0461,
             -0.0050, -0.0222, -0.0214,  0.0728,  0.0978,  0.0445,  0.1071, -0.0424,
             -0.0453, -0.0243,  0.0965, -0.0362,  0.1090,  0.0560,  0.0993,  0.1083,
             -0.1044, -0.1035,  0.0618,  0.0887,  0.0534,  0.0582, -0.1027, -0.0228,
             -0.0093, -0.0263,  0.0995,  0.0545],
            [-0.0960, -0.0847, -0.0081, -0.0399, -0.0289,  0.0098, -0.0516, -0.0407,
             -0.0481,  0.0350, -0.1064, -0.0284, -0.0050, -0.0268, -0.0633,  0.1073,
             -0.0486, -0.0146,  0.0137,  0.0417,  0.0208, -0.0306,  0.0698,  0.0046,
              0.0142,  0.0778,  0.0057,  0.0532,  0.0863, -0.0880, -0.0578,  0.1039,
             -0.0168, -0.0277, -0.0425, -0.0892,  0.0591,  0.0277, -0.0588, -0.1082,
              0.1003,  0.0606, -0.0744,  0.0094, -0.0170, -0.0393,  0.0552, -0.0317,
             -0.1076, -0.0793, -0.1063,  0.0935,  0.0547,  0.0739,  0.0119,  0.0066,
             -0.0575,  0.1036,  0.0851, -0.0263,  0.0289,  0.0313, -0.0230,  0.0539,
              0.0383, -0.0139, -0.0679,  0.0347, -0.0108, -0.0426, -0.0652, -0.0658,
              0.0016, -0.0006,  0.0119,  0.0836,  0.0721, -0.0161, -0.0995, -0.1081,
             -0.0412, -0.0719,  0.0229, -0.0253],
            [ 0.0494,  0.0233, -0.0247,  0.0813,  0.0354,  0.0482, -0.0773,  0.0205,
              0.0443,  0.0158,  0.0067, -0.0194, -0.0393,  0.0937, -0.0691, -0.0892,
             -0.0842,  0.0331, -0.0625,  0.0306,  0.0464, -0.0769, -0.0769,  0.0035,
             -0.0388, -0.0917, -0.0889, -0.0289,  0.0648, -0.1023, -0.0279,  0.0582,
             -0.0443,  0.0931,  0.0168, -0.0078, -0.0679, -0.1053, -0.0170, -0.0514,
             -0.0532,  0.0205, -0.0574,  0.0124, -0.0016,  0.0052, -0.0139, -0.0457,
             -0.0824,  0.0410, -0.0301, -0.0552, -0.0621, -0.0853,  0.0007,  0.0834,
              0.0966, -0.0621,  0.0118, -0.0470,  0.0905,  0.1009, -0.0542,  0.0351,
             -0.0109,  0.0146, -0.0418,  0.0194, -0.0406,  0.0212, -0.0712,  0.0703,
             -0.0596, -0.1085, -0.0516,  0.0780, -0.0024, -0.0418, -0.0513, -0.0803,
             -0.0984,  0.0883, -0.0831, -0.0894]], requires_grad=True)), ('fc.4.bias', Parameter containing:
    tensor([-0.0709,  0.0330, -0.0493,  0.0086,  0.0448,  0.0476,  0.0004, -0.0461,
             0.0877, -0.0351], requires_grad=True))]
    

    net.parameters()

    这时就很好理解net.parameters()的含义了。

    print(net.parameters())
    
    <generator object Module.parameters at 0x11c33e6d0>
    

    查看net.parameters()里的内容。

    print(list(net.parameters()))
    

    将以下的输出与net.named_parameters()的输出相对比,不难发现net.parameters()的输出里只包含参数的值,不包含参数的所属信息。

    [Parameter containing:
    tensor([[[[ 0.0410,  0.0087, -0.1333,  0.1778, -0.1390],
              [ 0.1892,  0.0961,  0.1061, -0.1052,  0.1079],
              [ 0.1668,  0.1842, -0.0382, -0.1956,  0.0523],
              [-0.0338, -0.1068, -0.0153,  0.0539,  0.0854],
              [ 0.0722,  0.1274,  0.1789,  0.0050,  0.1258]]],
    
    
            [[[ 0.1191,  0.0258,  0.1165,  0.0457,  0.1010],
              [-0.1258,  0.0007, -0.0185, -0.1964,  0.1923],
              [ 0.0609,  0.1677,  0.1662,  0.0938, -0.1873],
              [-0.1976, -0.1000, -0.0090,  0.1893,  0.0803],
              [ 0.0008,  0.1049, -0.1163, -0.1909, -0.0711]]],
    
    
            [[[ 0.0862,  0.0935,  0.1110,  0.1656, -0.1764],
              [ 0.0121, -0.0947,  0.1656, -0.1515, -0.0850],
              [ 0.0260, -0.1160,  0.0607, -0.0970,  0.0819],
              [ 0.1826,  0.0330,  0.0939,  0.0926,  0.0605],
              [-0.0505,  0.1631, -0.1297,  0.0518, -0.0945]]],
    
    
            [[[ 0.0357,  0.0992, -0.1226,  0.1044,  0.1179],
              [ 0.0878,  0.1462,  0.1384, -0.0398, -0.0731],
              [-0.0082, -0.0528, -0.1614,  0.0549,  0.0182],
              [-0.1968,  0.0586, -0.0960, -0.1667,  0.1041],
              [ 0.1257, -0.1673, -0.0406, -0.1308, -0.0155]]],
    
    
            [[[-0.0504, -0.0291, -0.1722, -0.1499,  0.1994],
              [ 0.1542,  0.1790, -0.0852, -0.1510,  0.1750],
              [ 0.0833, -0.0750,  0.1575, -0.1340,  0.0534],
              [ 0.1783,  0.1045, -0.1932,  0.1663,  0.1880],
              [ 0.1939, -0.0878, -0.1378, -0.0950, -0.0034]]],
    
    
            [[[-0.0732,  0.1186,  0.0730, -0.1049, -0.1912],
              [-0.1449, -0.1497,  0.0452, -0.0957,  0.0622],
              [-0.1474, -0.1116,  0.0353, -0.1039, -0.0057],
              [ 0.0020, -0.0547, -0.0182,  0.0955, -0.1281],
              [ 0.0869, -0.1780, -0.0062,  0.1206, -0.0139]]]], requires_grad=True), Parameter containing:
    tensor([-0.1239,  0.1441,  0.1907, -0.1307,  0.1135,  0.1451],
           requires_grad=True), Parameter containing:
    tensor([[[[-2.8963e-02, -2.9098e-03, -7.2477e-02,  3.5132e-02, -5.7784e-02],
              [ 4.8180e-02,  7.0770e-02, -3.9908e-03,  8.7891e-03, -6.4889e-02],
              [ 2.7601e-03, -5.2457e-02, -8.0490e-02, -1.8532e-02,  1.4432e-02],
              [ 5.8826e-02, -6.8718e-02, -7.2983e-02, -4.7448e-03,  6.6563e-02],
              [-2.3231e-02, -3.8217e-02, -5.7033e-02,  2.8378e-02,  1.0303e-02]],
    
             [[ 6.1817e-02, -5.7112e-02, -5.4775e-02,  8.7853e-03, -5.4520e-02],
              [ 3.0687e-02, -2.0470e-02, -3.5586e-02, -4.8132e-02,  6.1796e-02],
              [-2.8766e-03, -6.7307e-02, -5.2765e-02, -5.4711e-02, -7.6920e-02],
              [-5.5143e-02, -5.9496e-02,  7.0684e-02,  6.9688e-02, -2.8603e-02],
              [-7.7250e-02,  2.2666e-02,  2.6096e-02, -5.9670e-02, -6.0042e-02]],
    
             [[ 2.3628e-02,  3.9973e-03,  7.2141e-02, -3.4467e-02,  5.0605e-02],
              [ 3.2730e-03, -7.6666e-02, -4.7560e-02, -4.4962e-02,  7.2767e-02],
              [ 7.8844e-02,  4.7429e-02, -5.9860e-02, -4.8475e-02,  8.0821e-02],
              [-1.6961e-02, -7.5435e-02, -5.5244e-02,  4.1177e-02, -5.2729e-02],
              [ 7.4287e-02,  2.0302e-02, -3.4219e-02,  8.0755e-02,  1.0213e-02]],
    
             [[ 4.8082e-02, -9.2911e-03, -5.4356e-02,  5.1020e-02,  3.4330e-02],
              [ 3.8759e-02, -5.7922e-02, -8.0954e-02,  6.5382e-02, -4.6607e-02],
              [-7.3735e-02, -1.5173e-02, -4.8325e-02, -3.4208e-02, -7.9941e-02],
              [-7.6420e-02,  4.8138e-02, -6.0602e-02, -2.4346e-02,  5.2293e-02],
              [-1.8432e-02, -6.9902e-02,  5.2862e-02,  5.9985e-02, -3.3153e-02]],
    
             [[-5.2250e-02,  5.4422e-02,  6.3708e-02, -6.9918e-02,  2.7033e-02],
              [-6.9591e-02, -4.3221e-02,  2.8472e-02, -4.6924e-02, -6.3932e-02],
              [-4.3063e-02,  5.5538e-02,  5.1849e-02, -1.5760e-02,  7.3081e-02],
              [-3.3648e-03, -1.4109e-02, -1.8481e-02,  3.7719e-02, -6.4667e-03],
              [-1.4156e-02, -7.5164e-02, -2.6569e-02, -4.3967e-02, -5.6993e-02]],
    
             [[ 4.9329e-02,  3.1797e-02,  1.6622e-02, -5.3848e-02, -3.4816e-02],
              [-2.8487e-02, -1.1739e-02, -2.7306e-02,  4.4192e-02,  7.8720e-02],
              [ 6.6871e-02, -1.0399e-02,  4.9169e-02,  6.7737e-02,  7.3373e-02],
              [-3.0103e-02, -6.8764e-02, -6.3355e-02, -2.9528e-02,  4.7830e-02],
              [ 8.1528e-02,  6.0569e-02,  7.2046e-02,  7.1726e-02, -7.4708e-02]]],
    
    
            [[[ 6.8940e-02, -4.2813e-02, -2.2521e-02,  5.4037e-03, -3.9581e-02],
              [ 5.1579e-03,  5.9322e-03,  5.3795e-02, -6.6632e-02,  7.8148e-02],
              [ 1.5671e-02, -6.1238e-02,  6.4609e-02,  6.0379e-02, -6.3641e-03],
              [ 4.3215e-02,  7.7208e-02,  2.5349e-02, -4.6437e-02,  6.2033e-02],
              [ 4.1911e-02,  6.9520e-02, -6.6026e-02,  2.1334e-02,  4.3888e-02]],
    
             [[-1.2545e-03, -5.4130e-02,  6.1511e-02, -6.7956e-02,  4.8630e-02],
              [-3.3846e-02,  2.6091e-02, -3.4873e-02, -1.5935e-02, -3.7051e-02],
              [ 6.4495e-03, -4.2525e-02, -7.0826e-02, -1.1609e-02, -4.8163e-02],
              [-3.0650e-02,  7.2477e-02,  7.6664e-02,  1.7468e-02,  1.8646e-02],
              [-3.2821e-02,  6.5105e-02, -2.5739e-02, -7.7000e-02, -4.3495e-02]],
    
             [[ 7.4074e-02, -5.6415e-02,  4.2063e-02,  5.8861e-02,  6.7619e-02],
              [ 3.0597e-02, -7.5530e-02,  2.5615e-02, -1.1965e-02, -4.8025e-02],
              [-4.1109e-02, -3.8860e-02, -7.1784e-02,  2.0767e-02, -3.2796e-02],
              [-3.7898e-02,  4.3461e-02,  5.2736e-02, -2.7785e-02,  1.0612e-02],
              [-8.9870e-03,  7.4863e-02,  4.9618e-02, -3.9111e-03, -2.4767e-02]],
    
             [[ 6.0977e-02, -5.9753e-02, -7.7501e-02, -4.2407e-02,  6.4220e-02],
              [ 4.9666e-02, -7.1719e-03, -2.7490e-02,  4.6435e-02, -2.6879e-02],
              [-6.6493e-02,  3.8603e-03, -2.9617e-02, -1.0009e-03,  7.6103e-02],
              [-5.7345e-02, -1.3031e-02, -6.0397e-02,  5.4500e-02, -7.2243e-02],
              [-8.2337e-03,  1.5865e-02, -1.6706e-02,  4.7578e-02, -7.5731e-02]],
    
             [[-4.8035e-03, -5.5092e-02, -3.0751e-03, -7.0136e-03, -4.0719e-02],
              [-8.2313e-03, -1.0686e-02, -1.2555e-02,  2.5128e-02, -3.1423e-03],
              [ 4.0408e-03,  6.4090e-02, -6.1057e-02,  2.9454e-02,  3.5719e-02],
              [ 4.1708e-02, -6.2678e-02,  7.6516e-02,  1.4917e-02, -6.1162e-02],
              [ 3.2299e-02, -6.4477e-02,  7.1619e-02, -7.9505e-02, -6.9479e-02]],
    
             [[ 2.2419e-02,  1.7650e-02, -2.3487e-02, -5.5158e-02, -3.8079e-02],
              [ 6.5762e-02,  1.5358e-02, -5.3016e-02, -7.2853e-02, -1.0024e-02],
              [-1.2081e-02, -6.7160e-02,  9.6406e-04, -1.7273e-02,  6.5218e-02],
              [ 8.8176e-03,  4.0456e-02,  4.8698e-02, -4.1231e-02, -5.0352e-02],
              [ 1.1263e-02,  3.3423e-02, -7.4625e-02, -6.9672e-03, -6.4870e-02]]],
    
    
            [[[-1.5700e-02,  2.9963e-02,  4.8813e-03, -4.0353e-02,  7.0948e-02],
              [-1.7778e-02, -3.8914e-02,  4.8550e-02, -6.1970e-02, -2.6693e-02],
              [ 2.4974e-02,  1.5828e-03,  9.2727e-03,  6.6837e-02, -4.5953e-03],
              [-6.0175e-02,  5.4504e-02, -2.2963e-02,  2.0925e-02,  5.6399e-02],
              [-6.2549e-02,  6.8775e-02,  5.6015e-03, -2.5060e-02, -7.1567e-02]],
    
             [[-7.5507e-02,  5.5136e-02,  5.0185e-02, -7.7853e-02, -6.7106e-02],
              [-3.0236e-02,  6.3774e-02, -3.5332e-02,  5.2689e-02,  7.2057e-02],
              [ 3.4244e-03, -3.7071e-03, -4.5977e-02,  3.9994e-02,  8.0881e-02],
              [ 6.5955e-02, -1.9152e-02,  3.6607e-02, -3.1184e-02, -2.6080e-02],
              [ 2.9632e-02, -1.4070e-02,  2.6950e-02, -5.4370e-02,  3.6169e-02]],
    
             [[-6.6057e-02, -4.6405e-03, -1.9906e-02,  6.1993e-02,  3.2244e-02],
              [-3.7318e-02,  8.0351e-02,  5.3680e-02, -7.4121e-02, -7.4254e-02],
              [-2.6765e-02, -1.1703e-04,  6.8430e-02,  7.7011e-02, -5.7064e-02],
              [-2.9441e-02,  1.2167e-02,  1.9417e-02, -3.3268e-03, -7.4295e-02],
              [-1.1700e-02, -2.5405e-02, -6.7093e-02, -1.1647e-02,  7.9966e-02]],
    
             [[-6.9606e-02, -1.8622e-02,  6.2916e-02, -4.7264e-02,  3.2849e-02],
              [ 2.8261e-03, -5.5592e-02, -2.6301e-02,  1.9978e-02,  4.3346e-02],
              [-6.4162e-02,  3.5391e-02,  2.6387e-02, -5.8692e-02, -4.0991e-02],
              [-3.9600e-02,  6.2004e-02, -7.2942e-02,  1.4340e-02,  2.7500e-02],
              [-2.1774e-02,  1.0178e-02,  5.7392e-02,  3.8199e-02,  1.7461e-02]],
    
             [[-3.7614e-02, -3.2366e-02, -6.0066e-02,  5.5485e-02,  1.9672e-02],
              [-2.7670e-02,  1.4319e-03, -7.9320e-02, -1.9771e-02, -7.2843e-02],
              [ 7.8097e-02, -4.9131e-02,  7.2546e-02,  2.9516e-02, -3.9846e-03],
              [-3.6015e-02, -3.2198e-02, -6.0768e-02,  1.4562e-02, -6.5114e-02],
              [ 1.4656e-02, -5.9281e-02,  3.0640e-02, -4.5712e-02,  1.2611e-03]],
    
             [[ 2.8566e-02, -6.9925e-02,  6.8540e-02,  3.3783e-02, -3.6372e-02],
              [-3.9064e-02, -2.6633e-02, -2.6111e-02,  4.1179e-02, -3.1080e-02],
              [ 7.8710e-02, -2.0327e-02, -3.1146e-03,  1.3000e-02,  2.5061e-02],
              [ 3.8896e-02,  1.4993e-02, -1.1621e-03,  1.9493e-02, -7.9767e-03],
              [-2.3762e-02, -3.6319e-02,  3.5764e-02,  6.1390e-02,  4.3489e-02]]],
    
    
            ...,
    
    
            [[[-7.9247e-02, -1.6262e-02,  4.6512e-02, -6.3749e-02, -1.8689e-02],
              [-3.6147e-02, -5.6463e-02,  6.3543e-02, -1.4711e-02,  2.8662e-02],
              [-5.8296e-02,  6.8720e-02,  3.7628e-02, -7.6084e-02,  6.4086e-02],
              [-4.5766e-02,  4.9432e-02, -1.8870e-02, -2.3774e-02,  8.0839e-02],
              [-4.9609e-02,  2.6880e-03, -5.1678e-02, -6.1433e-02, -4.0386e-02]],
    
             [[ 6.9284e-02, -4.1973e-02, -6.3685e-03, -2.8147e-02, -8.0874e-02],
              [-5.7934e-02, -5.9883e-02, -6.5266e-02, -7.3571e-02, -9.9703e-03],
              [-7.8139e-02,  6.8472e-02, -2.6451e-02,  7.4826e-02,  6.9501e-02],
              [ 6.7803e-02,  5.1744e-02,  1.5820e-03,  4.8103e-02,  4.4573e-02],
              [ 1.7196e-02, -3.7756e-03, -1.6192e-02,  7.9102e-02, -3.8238e-02]],
    
             [[ 7.4826e-02, -4.3101e-02,  4.7018e-02, -7.8275e-02, -4.4333e-02],
              [-2.3578e-02, -7.1448e-02,  7.2239e-02, -6.5737e-02,  7.2115e-03],
              [ 2.8724e-02,  2.7590e-02, -4.4404e-02,  1.0346e-02,  4.6916e-02],
              [-2.7060e-02,  5.5961e-02, -5.1265e-02, -1.4966e-02,  3.3431e-02],
              [ 2.1349e-02,  1.6908e-02,  2.0520e-02,  3.0048e-02,  9.1663e-03]],
    
             [[-7.2711e-02,  7.8514e-03, -2.6890e-02,  3.4914e-02,  3.3108e-02],
              [ 5.1972e-02, -5.4517e-02,  6.9205e-03, -1.8841e-03, -6.2788e-02],
              [ 2.1441e-03, -2.8718e-02,  4.4018e-02,  6.3667e-02, -4.2750e-02],
              [ 3.9548e-02,  3.8377e-02,  4.6587e-03,  6.9412e-03,  7.0009e-03],
              [-5.8346e-02, -2.2396e-03, -6.6151e-02,  5.2126e-03,  1.2585e-02]],
    
             [[ 1.4102e-03, -7.3538e-02, -3.4312e-02, -4.9866e-02,  4.6846e-02],
              [ 1.4512e-03, -4.7476e-02,  6.7894e-02,  2.8975e-02, -2.7963e-03],
              [ 4.0158e-02,  4.7094e-02,  6.6540e-02, -1.0405e-02,  4.4982e-02],
              [-1.8426e-02, -3.8863e-02,  2.2584e-02, -8.4745e-03, -6.0421e-03],
              [-1.6939e-02, -4.6613e-02, -4.6251e-02,  2.8112e-02, -7.0524e-02]],
    
             [[-6.5741e-03,  3.3762e-02, -6.1685e-02, -9.6785e-03, -2.1676e-02],
              [ 7.8025e-02,  8.1469e-02, -8.0218e-02,  4.8415e-02, -2.0223e-02],
              [ 4.1636e-02,  9.4511e-03,  5.7086e-03,  7.4077e-02,  2.9475e-02],
              [-2.8554e-02,  4.9481e-02, -4.1975e-02,  6.1363e-02, -3.5292e-02],
              [-4.2593e-02, -1.4256e-02,  6.0404e-02, -2.9885e-02,  3.3893e-02]]],
    
    
            [[[-7.5500e-02, -4.5625e-02,  6.9478e-02, -2.2403e-02,  7.6093e-02],
              [ 5.9733e-02, -7.5538e-02,  6.1601e-05, -7.1882e-02, -2.6070e-02],
              [-2.2260e-02,  1.6907e-02,  6.5197e-02, -1.2651e-02, -1.9864e-02],
              [-8.8667e-03, -4.0787e-02,  6.2739e-02,  7.3264e-02,  5.0783e-02],
              [ 1.4677e-02,  1.2192e-02, -2.4456e-02,  4.5488e-03, -6.6156e-03]],
    
             [[ 3.4777e-02,  6.7579e-04, -1.4962e-02,  2.1922e-02,  2.4187e-02],
              [-2.1658e-02, -8.5521e-03,  7.4014e-02,  7.8755e-02, -6.8202e-02],
              [-6.0348e-02,  3.5042e-02, -2.7001e-03, -2.1861e-02,  8.6169e-03],
              [ 3.7000e-03, -6.3358e-02,  7.6107e-02,  3.2191e-02,  1.6767e-02],
              [ 2.0840e-02, -7.4857e-02,  7.9910e-02,  7.6407e-02, -3.6156e-02]],
    
             [[ 3.4754e-02,  4.9448e-02, -3.7052e-02, -4.6018e-02, -4.5467e-03],
              [-6.6047e-02, -5.9378e-03,  7.0414e-02, -4.5499e-03, -3.9428e-02],
              [-6.3372e-02, -7.2713e-02,  6.9092e-02, -5.6979e-02,  4.6475e-02],
              [-6.1525e-02,  1.6748e-02,  7.3203e-04, -1.0556e-02, -8.8385e-03],
              [-7.4622e-03,  6.5255e-02,  4.5906e-02, -6.9077e-02, -3.0107e-02]],
    
             [[ 1.0513e-04,  3.9094e-02,  1.0730e-02, -9.0341e-03,  6.4399e-02],
              [ 6.4052e-02, -1.1505e-02,  2.5839e-02, -1.4346e-02, -2.1266e-02],
              [-5.0057e-02,  4.9276e-02, -1.2757e-02, -4.0354e-02,  5.9740e-02],
              [-3.4600e-02, -6.0690e-02, -2.9586e-02,  1.6307e-02,  7.5232e-02],
              [-7.2830e-02, -7.7550e-02,  3.3646e-02,  6.1103e-02, -5.2657e-02]],
    
             [[ 5.4872e-02, -7.4650e-02,  1.6541e-02,  7.8543e-02,  7.8050e-02],
              [ 3.7544e-02,  4.9240e-02,  7.9944e-03,  1.0217e-02,  3.8372e-02],
              [ 7.8395e-02, -2.4000e-02, -3.0910e-02,  4.7569e-02, -3.6238e-02],
              [ 3.5622e-02,  1.1800e-02,  2.1467e-02, -3.9506e-02, -6.5340e-02],
              [-5.0346e-02, -4.7460e-02, -6.1105e-02,  1.5823e-02,  7.0169e-02]],
    
             [[-4.2157e-02,  4.4219e-02,  2.9132e-02,  2.0793e-02,  6.9149e-02],
              [-1.4266e-02,  1.2880e-02,  6.9789e-03,  7.2753e-02, -5.9546e-02],
              [-4.4822e-02,  9.1137e-03, -3.7866e-02,  6.3453e-02, -1.2861e-03],
              [ 3.2834e-02,  4.2014e-02, -1.7143e-03, -1.4081e-02,  7.5274e-02],
              [-1.5480e-02,  3.5807e-02, -6.9051e-02, -2.4274e-02, -5.6691e-02]]],
    
    
            [[[-2.2833e-03,  3.3301e-02,  4.1768e-02, -1.7934e-02,  2.8930e-03],
              [ 6.0746e-02, -7.1399e-02, -1.1018e-03, -4.8968e-02,  6.2150e-02],
              [-5.1771e-02,  5.3984e-02,  7.3118e-02,  1.8111e-02,  6.3114e-02],
              [ 4.0392e-02, -1.2633e-02,  1.2531e-02,  6.0250e-02,  8.8036e-03],
              [-5.1320e-03,  4.3080e-02, -6.1660e-02, -3.4335e-02, -2.9997e-02]],
    
             [[-3.2320e-02, -5.8163e-02,  6.5511e-02, -1.4306e-02, -6.8662e-04],
              [-8.0749e-02,  4.1665e-02,  5.7938e-02, -4.8792e-02,  6.7698e-03],
              [-5.4154e-02, -5.8755e-02,  3.2709e-02,  1.3108e-02, -3.2793e-02],
              [ 1.9453e-02,  5.5604e-02, -3.7737e-02,  5.3620e-02,  1.2426e-02],
              [-4.4390e-02, -5.7698e-03,  3.7961e-02,  4.8892e-02, -6.6512e-02]],
    
             [[ 2.0963e-02, -2.1631e-02,  1.5182e-02, -5.3852e-02,  5.2485e-02],
              [ 5.5099e-02, -3.1139e-02,  2.9413e-02,  7.0662e-02, -4.5816e-02],
              [ 3.1409e-02,  4.5691e-03, -7.0160e-02, -2.2321e-02, -8.0069e-02],
              [ 3.6123e-02,  4.0221e-02, -2.0069e-03,  7.7441e-02, -2.7235e-03],
              [-2.2219e-02, -3.7452e-02, -6.8167e-02,  4.2610e-02, -3.5328e-02]],
    
             [[-6.0438e-02,  7.7323e-02, -5.7719e-02,  7.8942e-02,  8.8516e-03],
              [ 5.1480e-02,  2.7628e-02, -4.6864e-02,  6.7227e-02,  3.5049e-02],
              [ 4.0685e-02,  6.7781e-02, -4.4310e-02, -2.4059e-02, -7.0231e-02],
              [ 4.3356e-02, -2.2007e-02, -6.9719e-02,  2.2936e-02, -1.5587e-03],
              [-5.6923e-02,  5.2186e-02, -3.7489e-03,  7.8067e-02,  6.1181e-02]],
    
             [[-7.4544e-02,  1.5348e-02,  5.6739e-02,  6.7409e-02,  5.1177e-03],
              [ 7.0433e-02, -5.3445e-04,  6.4773e-02,  7.7484e-02, -1.9484e-02],
              [ 2.1259e-03,  2.5516e-02, -3.1720e-02,  8.4753e-03, -7.7631e-02],
              [-6.3258e-02, -6.6547e-02, -5.3897e-02, -7.1886e-03,  1.5505e-02],
              [-1.5022e-02, -4.4072e-02,  5.8662e-02, -4.3674e-02,  5.2709e-02]],
    
             [[-1.9810e-02,  5.0917e-02,  3.9759e-02, -7.7648e-02, -4.7125e-03],
              [-3.9929e-02,  3.8429e-02, -5.3146e-02,  3.1286e-02, -2.2515e-02],
              [ 7.6312e-02, -1.3954e-02, -3.7200e-02,  3.1017e-02,  5.9228e-03],
              [ 4.4261e-02,  3.5193e-02, -7.7872e-02,  5.5385e-02,  6.1767e-02],
              [-7.4532e-02,  2.1826e-02,  6.5674e-02,  1.9984e-02,  6.8654e-02]]]],
           requires_grad=True), Parameter containing:
    tensor([ 0.0678,  0.0369,  0.0342,  0.0405, -0.0266, -0.0779, -0.0757, -0.0209,
             0.0630, -0.0382, -0.0468, -0.0690, -0.0683, -0.0030,  0.0483,  0.0491],
           requires_grad=True), Parameter containing:
    tensor([[ 0.0513,  0.0410,  0.0382,  ...,  0.0213,  0.0361,  0.0081],
            [-0.0182,  0.0314, -0.0430,  ...,  0.0044,  0.0621, -0.0449],
            [ 0.0202,  0.0397, -0.0596,  ..., -0.0244,  0.0337,  0.0145],
            ...,
            [ 0.0320, -0.0142,  0.0270,  ..., -0.0290,  0.0442,  0.0547],
            [ 0.0391,  0.0505,  0.0070,  ..., -0.0357, -0.0528,  0.0459],
            [-0.0352,  0.0147, -0.0250,  ..., -0.0082, -0.0507, -0.0250]],
           requires_grad=True), Parameter containing:
    tensor([ 0.0113,  0.0031, -0.0317,  0.0594, -0.0525, -0.0114,  0.0581,  0.0274,
             0.0292,  0.0055, -0.0213, -0.0435, -0.0413,  0.0477, -0.0005,  0.0545,
             0.0428, -0.0532,  0.0326,  0.0589, -0.0456, -0.0242,  0.0454,  0.0260,
            -0.0287,  0.0353, -0.0348, -0.0098, -0.0548, -0.0155,  0.0142,  0.0570,
            -0.0238, -0.0282, -0.0268, -0.0162, -0.0424, -0.0187,  0.0482, -0.0511,
            -0.0569, -0.0326, -0.0005, -0.0175,  0.0613,  0.0052,  0.0090, -0.0587,
            -0.0243, -0.0602,  0.0480, -0.0082, -0.0019, -0.0556,  0.0112, -0.0089,
            -0.0382,  0.0201,  0.0072,  0.0302,  0.0391,  0.0387,  0.0013,  0.0450,
            -0.0287, -0.0407,  0.0338, -0.0398,  0.0575, -0.0138, -0.0163,  0.0527,
             0.0374, -0.0375, -0.0085, -0.0313,  0.0491, -0.0202,  0.0422,  0.0097,
             0.0129, -0.0158,  0.0436, -0.0207, -0.0369,  0.0385,  0.0177,  0.0222,
             0.0432,  0.0099, -0.0018, -0.0302,  0.0200, -0.0125,  0.0499, -0.0536,
            -0.0173,  0.0338,  0.0071, -0.0455, -0.0544, -0.0318,  0.0045,  0.0558,
            -0.0202, -0.0283,  0.0463,  0.0010, -0.0182,  0.0338,  0.0241, -0.0311,
             0.0300, -0.0100,  0.0409, -0.0511,  0.0570,  0.0057,  0.0472, -0.0139],
           requires_grad=True), Parameter containing:
    tensor([[-0.0890, -0.0383,  0.0878,  ...,  0.0310,  0.0564, -0.0808],
            [ 0.0576, -0.0858, -0.0621,  ..., -0.0026,  0.0120, -0.0341],
            [-0.0450,  0.0144, -0.0543,  ...,  0.0356, -0.0233, -0.0653],
            ...,
            [ 0.0648, -0.0684, -0.0326,  ...,  0.0065, -0.0058, -0.0420],
            [-0.0585,  0.0686, -0.0484,  ...,  0.0509,  0.0448, -0.0674],
            [-0.0035,  0.0649, -0.0592,  ..., -0.0319,  0.0646,  0.0588]],
           requires_grad=True), Parameter containing:
    tensor([-0.0633,  0.0455,  0.0280, -0.0609,  0.0850,  0.0157, -0.0283,  0.0237,
             0.0255,  0.0857,  0.0116,  0.0152, -0.0532, -0.0033,  0.0520,  0.0483,
             0.0443,  0.0262, -0.0723,  0.0222, -0.0716,  0.0064, -0.0563,  0.0375,
             0.0029, -0.0847,  0.0801,  0.0104, -0.0056, -0.0383,  0.0549, -0.0880,
            -0.0295, -0.0564, -0.0076, -0.0430,  0.0695, -0.0635,  0.0879,  0.0036,
             0.0236, -0.0112,  0.0703,  0.0850, -0.0697, -0.0092,  0.0831, -0.0589,
             0.0251,  0.0022, -0.0332, -0.0475, -0.0013,  0.0520,  0.0090,  0.0245,
             0.0090,  0.0828,  0.0867, -0.0658, -0.0815, -0.0580,  0.0603,  0.0076,
             0.0038, -0.0839,  0.0799,  0.0519,  0.0462,  0.0285, -0.0007,  0.0413,
            -0.0572, -0.0630,  0.0040,  0.0451, -0.0700,  0.0080, -0.0657, -0.0501,
             0.0763,  0.0420, -0.0159,  0.0668], requires_grad=True), Parameter containing:
    tensor([[-3.6386e-02, -7.5612e-02, -3.3518e-02,  1.4540e-03,  9.4882e-02,
              4.5503e-02, -6.1533e-02,  6.6970e-02,  6.3393e-02,  6.2845e-02,
              9.0250e-02,  6.4183e-02, -9.9777e-02,  8.3458e-02, -5.6648e-02,
             -3.2242e-02, -1.0210e-01, -3.4709e-02, -4.3793e-02,  1.0092e-01,
             -6.7078e-02, -9.4087e-02,  8.9792e-02, -3.8702e-02, -2.2616e-02,
             -1.0415e-01,  1.0543e-01, -1.2626e-02,  9.0107e-03,  6.0382e-02,
              4.1577e-02, -2.3903e-02, -4.2621e-03, -4.3189e-02, -6.6097e-02,
              3.0445e-02, -7.7118e-03, -3.2404e-02, -1.2146e-02, -4.2914e-03,
              2.8186e-02, -9.0773e-02, -1.1838e-02,  2.1362e-02, -1.0525e-01,
             -9.2063e-02,  9.4274e-02, -1.0045e-01, -9.0591e-02, -3.0428e-02,
              1.4315e-02, -4.0064e-02, -4.7963e-02,  9.2005e-02, -8.2900e-02,
              1.0288e-01, -1.3765e-02, -3.8088e-02,  6.8671e-02, -3.3005e-02,
              5.7502e-02,  9.8560e-04, -6.3017e-02, -8.5585e-02, -4.3825e-02,
             -6.7568e-02,  9.4429e-02,  5.2574e-02,  6.5422e-02, -3.9275e-02,
              8.0115e-02, -9.6867e-02,  7.0743e-03, -9.9576e-02, -5.4559e-02,
              2.6863e-02, -2.6273e-02, -6.5362e-02, -6.4335e-02,  1.2955e-02,
              6.0012e-02, -2.3485e-02, -1.6260e-02,  9.4532e-02],
            [-5.0317e-02,  8.6468e-02, -1.9755e-02, -6.9467e-02, -5.4839e-02,
              8.7977e-02,  3.5099e-02, -4.7161e-02,  4.2828e-02, -9.6357e-02,
             -2.4457e-02, -2.8137e-02,  5.5173e-02,  3.4454e-02, -5.9090e-02,
              1.6396e-02, -1.0215e-01, -4.5904e-02,  5.2007e-02,  9.3490e-03,
             -3.4958e-02, -2.2684e-02, -7.6629e-02,  2.8934e-02, -1.0464e-01,
             -2.2579e-02,  6.2805e-02,  4.2103e-02, -7.1579e-02, -8.4758e-02,
              9.1291e-02,  3.3716e-03,  7.4650e-02,  4.7561e-02, -8.6074e-02,
              7.3462e-02, -4.2406e-02, -4.8041e-02,  3.8306e-02,  1.0615e-01,
             -2.3629e-02,  1.4357e-02,  1.2356e-02,  1.9959e-02, -8.2264e-02,
             -8.5730e-02, -4.3924e-02, -6.7238e-02, -1.6528e-03,  8.6641e-02,
             -7.8528e-02,  4.1036e-02, -5.2856e-03,  1.6136e-02, -6.9556e-03,
              3.8389e-02, -4.5973e-02, -9.6278e-02, -1.1061e-02,  2.6612e-02,
             -1.0853e-01, -4.7798e-02,  5.0719e-02,  9.0884e-02, -6.0419e-02,
              3.2022e-02, -9.3310e-04,  8.4557e-03,  3.0089e-02,  1.6014e-02,
             -1.4716e-03,  6.0982e-02,  9.2107e-02,  8.1138e-02,  1.0421e-01,
             -1.9497e-02,  1.0560e-01, -2.9459e-02, -5.2058e-02, -9.7952e-02,
              1.5477e-02,  7.4985e-02,  8.9651e-02,  6.3363e-02],
            [ 3.0208e-02, -1.9767e-02,  1.5079e-02,  5.1502e-02,  9.1195e-02,
             -2.9254e-02, -9.1265e-02, -1.8142e-02,  1.2918e-03,  6.6398e-02,
             -1.9874e-03, -4.7915e-02, -9.4007e-02, -3.3326e-02, -8.5119e-02,
              3.9335e-02, -4.4174e-02,  7.7702e-03, -4.5256e-03, -1.3154e-02,
             -5.0678e-02, -5.1647e-02,  4.7730e-02, -5.7502e-02,  7.5471e-02,
              6.5450e-02,  8.8071e-02, -1.2887e-02, -7.5714e-02, -9.6250e-02,
             -8.8555e-02,  8.1908e-02,  9.1045e-02, -9.9165e-03,  4.9054e-03,
             -6.7292e-03, -8.7853e-02,  5.7791e-02, -3.2609e-02, -1.0200e-01,
             -8.2626e-03,  7.0677e-02, -5.1523e-02,  7.0271e-02,  4.5593e-02,
             -9.7476e-02,  9.2197e-02,  6.2481e-02, -3.7979e-02,  2.7765e-02,
              4.4584e-02,  8.1821e-03,  4.1069e-02,  9.2782e-02, -2.9300e-02,
              4.4233e-02,  6.0771e-02,  3.6433e-02, -9.6801e-02, -6.5366e-02,
             -1.4144e-02, -7.4618e-02,  1.0075e-01, -8.9531e-02,  4.9829e-02,
             -1.0086e-01,  2.0289e-02,  5.0525e-02,  4.4842e-02, -1.0856e-01,
             -6.5582e-02,  8.4446e-02, -6.3685e-02, -8.4885e-02,  8.1084e-02,
              1.6807e-02,  2.0948e-02, -3.1429e-02, -9.6671e-02,  1.0331e-01,
              1.0905e-01,  3.3493e-02, -2.5160e-02, -2.7594e-02],
            [-1.0750e-01,  1.5754e-03,  9.4579e-02, -9.6466e-02, -1.6102e-02,
              6.7770e-02, -9.1392e-02, -3.2254e-02,  1.4040e-02, -4.3080e-02,
              4.1318e-02, -1.0239e-01, -1.0444e-01, -9.8844e-02,  2.7821e-02,
              7.2258e-02,  5.1104e-02, -5.1923e-02,  1.0016e-01,  8.7752e-02,
             -2.9829e-02, -1.0154e-01, -9.4609e-02,  9.2035e-02, -1.7863e-02,
              5.2856e-02, -1.0145e-01, -9.6503e-02,  5.3276e-02, -4.0296e-02,
             -6.0391e-02, -4.0476e-02, -2.6268e-02,  6.0211e-02,  1.3897e-02,
             -9.3714e-02, -1.0263e-01, -1.0240e-02,  3.2961e-03, -7.4508e-02,
             -4.4669e-02,  1.0582e-01, -3.1710e-02, -4.1936e-03,  3.9233e-02,
             -7.3520e-02, -1.4513e-02, -8.7190e-03, -9.3036e-02, -4.9512e-02,
             -4.8323e-02, -1.2182e-02,  7.8546e-02, -1.4734e-02, -4.7487e-02,
             -8.0177e-02,  1.0143e-01, -3.5455e-02,  1.4562e-02, -1.0467e-01,
              1.0126e-01,  4.0935e-02,  2.7359e-02, -2.8587e-02,  3.3592e-02,
              8.3130e-02,  3.9802e-02,  2.4663e-02, -3.9062e-02, -8.4517e-02,
              8.8452e-02, -5.9931e-02,  5.2263e-02, -8.6667e-02,  3.2252e-02,
             -1.2878e-02, -1.0024e-01, -6.2088e-03,  1.0653e-01,  4.5513e-02,
              9.2196e-02, -1.0193e-01, -5.2427e-02, -7.4088e-02],
            [ 6.1146e-02,  7.1998e-02,  5.0817e-03,  2.9839e-02, -6.0738e-02,
              7.4407e-02,  4.9660e-03,  1.7257e-02,  8.9644e-02,  1.0166e-01,
             -7.9003e-02,  3.1016e-02, -1.0282e-01, -3.4413e-02, -7.1400e-02,
             -5.7055e-02, -1.0687e-01, -2.4351e-02, -1.9439e-02,  8.4380e-03,
             -4.0189e-02, -4.6372e-02, -2.4307e-02, -9.1113e-02,  7.1963e-02,
             -4.6406e-02,  3.0909e-02, -1.5908e-03, -4.2981e-03,  9.0392e-02,
             -8.0804e-02, -1.0631e-01,  7.0188e-02, -1.6976e-02,  5.9801e-02,
              1.0504e-01, -1.3394e-02, -3.7976e-02, -5.9558e-02,  5.5488e-02,
              7.1022e-02, -8.5150e-04,  7.6335e-02, -2.5111e-02, -1.0709e-01,
              4.9914e-02, -1.0673e-01,  4.5119e-02,  8.9661e-02, -1.0085e-01,
             -4.4432e-02,  1.0257e-01,  4.1100e-02, -5.1784e-02,  2.9209e-03,
              8.5102e-02,  7.2529e-02, -1.6541e-02,  7.6805e-02,  6.6119e-03,
             -8.0215e-02, -2.0578e-02,  7.5022e-03, -1.0727e-03,  6.9429e-02,
              5.7830e-02, -1.0790e-01, -9.6679e-02, -8.6152e-02, -9.4943e-02,
              8.1462e-02, -5.8394e-02, -1.0256e-01, -5.5599e-02,  9.3751e-02,
             -7.0657e-02, -4.0052e-02, -7.0332e-02,  2.2784e-02, -5.4529e-02,
             -5.4662e-02, -5.7277e-02,  1.4437e-02,  1.2149e-02],
            [ 3.8866e-02, -7.2644e-02, -4.5336e-02, -7.2174e-03, -9.8546e-02,
             -5.2182e-02, -3.9291e-02, -2.5983e-02, -1.0295e-01, -6.3502e-02,
             -4.1473e-02,  4.5859e-02,  2.7641e-02, -2.6850e-02,  3.9798e-02,
              5.3340e-02,  8.6995e-02, -5.8024e-02,  7.4455e-02, -1.0696e-01,
             -1.5863e-02,  1.0751e-01, -4.7459e-02, -1.5922e-02, -8.2261e-02,
             -1.0526e-01, -3.4973e-02,  6.2265e-02,  1.2063e-03,  4.4859e-02,
             -8.0358e-02, -2.0814e-02, -1.0345e-01,  4.8143e-02, -9.1006e-02,
             -5.0193e-02, -4.1720e-02,  6.9656e-03, -1.8449e-02,  9.2898e-02,
             -2.0530e-03,  7.2708e-02,  7.2717e-02, -7.0943e-02, -3.6722e-02,
              5.7738e-03, -1.0001e-01, -8.2471e-02,  3.7489e-02,  8.8267e-02,
             -3.9706e-02,  2.4869e-02,  7.0312e-02, -7.3247e-02,  4.7573e-02,
              5.6678e-02,  8.1566e-02, -8.8834e-02,  2.1508e-02, -2.0825e-03,
             -9.3444e-02, -8.9208e-02,  7.1779e-02,  4.8020e-02,  6.3238e-02,
             -4.4839e-02, -5.0632e-02,  8.9627e-02, -6.7394e-02,  3.6466e-02,
             -4.3583e-02,  6.0448e-02, -9.3000e-03,  1.3505e-02, -1.0730e-01,
             -5.5369e-02,  5.5980e-02, -4.4605e-02,  6.9085e-02,  9.6867e-02,
              7.7629e-02, -6.5440e-03, -5.6384e-02,  9.7064e-02],
            [ 5.0708e-02, -7.0111e-02, -2.0744e-02,  6.0857e-02, -5.0635e-02,
              1.7039e-02,  6.5897e-02,  9.6267e-02, -2.0696e-02,  9.4343e-02,
             -7.0419e-02,  4.4685e-02, -1.8413e-02,  2.0547e-02, -6.6552e-02,
              5.0159e-02, -7.3504e-02, -1.0492e-02, -1.8667e-02,  8.4969e-02,
              3.8293e-02, -5.4837e-02, -9.4619e-02, -1.0034e-01,  6.5945e-02,
              1.1107e-02, -4.7042e-03,  1.5454e-02,  1.1526e-02, -4.8668e-02,
              2.5132e-02, -2.4420e-03,  7.3299e-02, -8.3444e-02,  9.7377e-02,
             -6.7371e-02, -5.8938e-02, -1.7242e-03, -3.6254e-02, -1.0387e-01,
              1.0440e-01,  4.6552e-03, -2.3136e-02,  7.8454e-02,  8.4281e-02,
             -1.1467e-02, -6.7206e-02, -9.2270e-02, -5.8444e-02, -2.2304e-02,
             -7.2272e-02, -3.7415e-02,  7.3007e-02, -1.1023e-02, -7.9971e-02,
             -1.8473e-02, -1.6350e-02,  2.4930e-02, -3.6162e-02,  7.4666e-02,
             -5.4134e-02,  1.0857e-01, -3.9097e-03,  1.8842e-02, -9.2155e-02,
             -1.0481e-01,  7.7692e-02,  1.0065e-01, -6.8519e-02, -2.0794e-02,
              3.4494e-02, -2.1841e-02, -3.9106e-02, -5.9967e-02,  1.0216e-01,
              7.5524e-02,  6.7092e-02,  7.6529e-02,  7.5286e-02,  6.7789e-02,
             -1.4697e-02, -1.3314e-02,  9.7935e-02, -6.8620e-02],
            [ 5.0607e-02, -8.2870e-02, -1.6189e-02, -2.4078e-02, -2.3985e-03,
             -7.4225e-02, -4.5165e-02, -9.8096e-02, -3.4397e-02, -3.5845e-02,
             -2.7014e-02,  6.1684e-02, -8.2043e-03,  3.5161e-03,  9.9549e-02,
              6.2777e-02,  7.0429e-02, -4.9991e-02, -7.1380e-02, -2.1621e-02,
              5.8705e-02,  4.2713e-02, -7.9030e-02,  9.8759e-02,  1.6264e-02,
              1.0744e-01,  7.7823e-02, -5.5156e-02,  3.0468e-02,  9.4384e-02,
             -9.2617e-02, -1.0246e-01,  4.3196e-02,  1.4461e-02, -6.7200e-02,
             -8.9693e-02,  2.5468e-02, -4.8936e-02,  8.1182e-02, -1.0881e-01,
             -8.9377e-02, -1.0545e-01, -7.5940e-02,  1.0469e-01, -3.3574e-02,
             -4.6298e-02, -2.9602e-02,  8.4512e-02, -6.1724e-02,  1.0186e-01,
             -3.1081e-02,  1.6060e-02, -7.0562e-02, -5.2786e-02,  1.0441e-02,
              1.9851e-02, -6.0174e-02, -2.3637e-02,  3.0766e-02, -5.9857e-02,
              9.1335e-02,  3.5998e-02, -6.3090e-02, -2.3622e-02, -1.0768e-01,
             -5.4553e-02, -4.9022e-02,  2.7522e-02, -1.0263e-01, -1.0168e-02,
              7.8986e-02,  7.2121e-02,  7.2154e-02, -1.8192e-02, -1.6958e-02,
             -6.3634e-02,  4.1967e-02, -7.2658e-02, -8.4010e-02,  5.1538e-02,
              8.8619e-02, -6.1079e-02, -4.6724e-02,  7.3064e-02],
            [-7.2866e-02, -4.9262e-03, -6.9382e-02, -8.4297e-02, -1.1513e-02,
              6.6993e-02,  5.1857e-02,  9.4692e-02, -5.8517e-02,  5.0415e-02,
             -2.5790e-02, -3.2096e-02, -1.4373e-02,  8.6973e-02,  1.0380e-01,
             -1.0905e-01, -7.2004e-02, -6.2544e-02, -2.0196e-02, -4.1834e-02,
             -8.8467e-02, -1.9361e-02, -9.1549e-02, -6.8652e-02, -5.3905e-02,
              7.4712e-02, -9.8439e-02, -8.9861e-02,  8.8598e-02, -6.0307e-02,
              1.4517e-02,  8.5560e-02,  5.0226e-02,  1.0879e-02, -7.1400e-02,
              1.0590e-01,  9.0517e-02, -8.7123e-02, -9.5143e-02, -2.3503e-02,
              5.1154e-02,  6.5253e-02,  5.0746e-03,  9.8675e-02,  3.8361e-02,
             -3.7910e-02,  3.5644e-02,  7.7644e-02, -1.0573e-01, -2.8797e-02,
              2.1448e-02, -7.2062e-02,  3.6224e-02, -7.3736e-02, -1.1190e-02,
             -9.8272e-02,  8.1385e-02,  3.4032e-02,  4.7809e-02, -4.1794e-02,
              6.3176e-02,  7.7939e-02, -4.8825e-02,  7.3850e-03,  7.2412e-02,
             -9.7425e-02, -4.8019e-02,  5.1571e-02,  5.3046e-02, -7.4308e-02,
              7.5107e-02, -3.5483e-02, -1.0244e-01, -5.1666e-02,  3.8744e-02,
              2.9136e-02, -7.3850e-02, -5.8942e-02,  3.8802e-02, -5.6168e-02,
             -1.0624e-01,  2.9254e-03, -9.7513e-02, -9.1059e-02],
            [-2.0568e-02,  7.4619e-02,  8.3663e-02,  8.4776e-02,  1.0220e-01,
             -5.9590e-02, -9.4820e-02, -6.3656e-02,  2.0908e-02, -5.3912e-02,
              2.5803e-02, -1.9115e-02, -5.1186e-02, -9.2199e-02,  4.1088e-02,
             -8.3359e-02,  3.3246e-02,  3.9068e-02,  1.4653e-02, -3.1885e-03,
              9.3133e-02,  9.1292e-02, -1.0260e-01, -8.7743e-02, -7.4692e-03,
              7.9978e-02, -1.0668e-01,  2.6780e-02, -2.4737e-02,  8.2099e-03,
             -2.6465e-02,  8.4724e-02, -5.5508e-02,  7.5358e-02,  5.3514e-02,
              9.9297e-02, -2.5902e-02, -6.3541e-02, -3.3830e-02,  9.9681e-02,
              1.0678e-01, -5.2969e-03, -1.3729e-03,  1.0819e-01, -7.7439e-02,
              2.5772e-02,  7.1406e-02,  3.9831e-03,  4.5043e-02, -7.3841e-02,
             -3.2391e-02, -2.3922e-02, -5.5451e-02,  7.1813e-02,  8.0033e-02,
             -3.9055e-02, -1.0562e-01, -6.8675e-03,  9.6633e-02, -8.2716e-02,
              3.7245e-02, -7.4261e-02, -7.3440e-02, -5.8544e-02,  3.8791e-02,
             -3.4096e-02, -3.7217e-03, -9.0024e-02, -3.6971e-02,  6.5495e-02,
             -4.5573e-02, -8.8379e-05, -1.0775e-01, -5.8573e-02,  8.4288e-02,
              1.0197e-01,  3.0589e-02, -4.3301e-02,  6.5042e-03, -4.3514e-02,
              4.0834e-02, -6.7375e-04, -4.8847e-02,  9.9802e-02]],
           requires_grad=True), Parameter containing:
    tensor([ 0.0892,  0.0370, -0.0758, -0.1002, -0.0598,  0.0666, -0.0814,  0.0643,
             0.0834,  0.0980], requires_grad=True)]
    

    如有错误希望大家批评指正!感谢!

    展开全文
  • model.named_parameters() 迭代打印model.named_parameters()将会打印每一次迭代元素的名字和param。 for name, param in net.named_parameters(): print(name,param.requires_grad) param.requires_grad = ...
  • named_modules 1. named_modules 内部采用yield关键字,得到生成器。可以看到函数内部给出的例子,当外部迭代调用net.named_modules()时,会先返回prefix=’’,以及net对象本身。然后下一步会递归的调用named_...
  • model.state_dict(), model.named_parameters, model.named_parameters.三种方式有细微的差别: model.state_dict(): 返回的是字典对象,包含可学习与不可学习的所有参数,所以常常用来保存模型或者加载模型。 model....
  • 1、model.named_parameters(),迭代打印model.named_parameters()将会打印每一次迭代元素的名字和param for name, param in model.named_parameters(): print(name,param.requires_grad) param.requires_grad=...
  • 函数model.named_parameters(),返回各层中参数名称和数据。 class MLP(nn.Module): def __init__(self): super(MLP, self).__init__() self.hidden = nn.Sequential( nn.Linear(256,64), nn.ReLU(inplace=True...
  • 在使用pytorch过程中,我发现了torch中存在3个功能极其类似的方法,它们分别是model.parameters()、model.named_parameters()和model.state_dict(),下面就具体来说说这三个函数的差异 首先,说说比较接近的model....
  • net.named_parameters() net.named_parameters()中param是len为2的tuple param[0]是name,比如:fc1.weight、fc1.bias等 param[1]是fc1.weight、fc1.bias等对应的值 for _,param in enumerate(net.named_parameters...
  • model.state_dict和model.parameters和model.named_parameters区别 在pytorch中,针对model,有上述方法,他们都包含模型参数,但是他们有些区别。下面对它们简单总结。 model.state_dict::该方法常用来保存模型,...
  • torch中存在3个功能极其类似的方法,它们分别是model.parameters()、model.named_parameters()、model.state_dict(),下面就具体来说说这三个函数的差异: 1.首先,说说比较接近的model.parameters()和model.named_...
  • 可见,named_parameters()输出模型中每一个 参数 的名称(字符串)与这个参数(Parameter类);而named_modules()与named_children()则输出的是每一块 模型的 名称(字符串)与这个模型(Conv2d、Linear、Sequence...
  • named_parameters(prefix='', recurse=True)[source] 返回模块参数上的迭代器,生成参数的名称和参数本身。 参数: prefix (str) – 在所有参数名称前加上前缀。 recurse (bool) – 如果为真,则生成此...
  • 参考链接: torch.nn.Module.named_parameters(prefix=’’, recurse=True)
  • bias=True) named_parameters():返回模块参数上的迭代器,产生参数的名称和参数本身 for name, parameter in model.named_parameters(): print(name, parameter) rnn.weight_ih_l0 Parameter containing: [432, 34...
  • for name, module in model.named_modules(): print('children name:', name) print('children module:', module) #named_parameters()是给出网络的名字和参数的迭代器, parameters()会给出一个网络的全部参数的选...
  • pytorch model.named_parameters() ,model.parameters() ,model.state_dict().items() 1、model.named_parameters(),迭代打印model.named_parameters()将会打印每一次迭代元素的名字和param。 for name, param in ...
  • #k,v就分别是w和b for k, v in net.named_parameters(): ...model.state_dict()、model.parameters()、model.named_parameters()这三个方法都可以查看Module的参数信息,用于更新参数,或者用于模型的保存。 ...
  • Pytorch中有3个功能极其类似的方法,分别是model.parameters()、model.named_parameters()和model.state_dict(),下面就来探究一下这三种方法的区别。 它们的差异主要体现在3方面: 返回值类型不同 存储的模型...

空空如也

空空如也

1 2 3 4 5 ... 20
收藏数 37,859
精华内容 15,143
关键字:

named_parameters()