What is the corresponding part of resnet101's "res4b22" in torchvision's pretrained model

username: jangbi
cooked: <p><div class="lightbox-wrapper"><a class="lightbox" href="https://discuss.pytorch.org/uploads/default/original/2X/0/0be7c57d183d8dbee0c7414a688dcb51b6fee48d.png" data-download-href="https://discuss.pytorch.org/uploads/default/0be7c57d183d8dbee0c7414a688dcb51b6fee48d" title="image"><img src="https://discuss.pytorch.org/uploads/default/original/2X/0/0be7c57d183d8dbee0c7414a688dcb51b6fee48d.png" alt="image" data-base62-sha1="1HjOQPsayKeFVvEGxKyKSSpMrlX" width="690" height="358" data-dominant-color="ECECEC"><div class="meta"><svg class="fa d-icon d-icon-far-image svg-icon" aria-hidden="true"><use href="#far-image"></use></svg><span class="filename">image</span><span class="informations">707×367 60.4 KB</span><svg class="fa d-icon d-icon-discourse-expand svg-icon" aria-hidden="true"><use href="#discourse-expand"></use></svg></div></a></div></p>
<p>When i turn to the resnet source code in <code>torchvision.model</code></p>
<pre><code class="lang-auto">model = ResNet(Bottleneck, [3, 4, 23, 3], **kwargs)
</code></pre>
<p>And the constructor of Resnet</p>
<pre><code class="lang-auto">        self.conv1 = nn.Conv2d(3, 64, kernel_size=7, stride=2, padding=3,
                               bias=False)
        self.bn1 = nn.BatchNorm2d(64)
        self.relu = nn.ReLU(inplace=True)
        self.maxpool = nn.MaxPool2d(kernel_size=3, stride=2, padding=1)
        self.layer1 = self._make_layer(block, 64, layers[0])
        self.layer2 = self._make_layer(block, 128, layers[1], stride=2)
        self.layer3 = self._make_layer(block, 256, layers[2], stride=2)
        self.layer4 = self._make_layer(block, 512, layers[3], stride=2)
</code></pre>
<p>Compared to this image, it seems that the <code>layer4</code> is corresponding with <code>conv5</code><br>
<img src="https://img-blog.csdn.net/20180114205444652?watermark/2/text/aHR0cDovL2Jsb2cuY3Nkbi5uZXQvbGFucmFuMg==/font/5a6L5L2T/fontsize/400/fill/I0JBQkFCMA==/dissolve/70/gravity/SouthEast" alt="这里写图片描述" width="690" height="297"><br>
So, how should i perform fine-tune mentioned in the paper on pytorch resnet101 model?<br>
Is the “res4b22” corresponding to</p>
<pre><code class="lang-auto">list(model.layer3.children())[-1]
</code></pre>
<p>What about the “res5a”, “res5b” and “res5c”, Are they corresponding to the 3 Bottleneck of conv5_x?</p>

username: lyakaap
cooked: <p>res4b22 correspond to model.layer3[-1]<br>
And res5* correspond to model.layer5.<br>
ref: <a href="https://github.com/KaimingHe/deep-residual-networks/blob/master/prototxt/ResNet-101-deploy.prototxt" rel="nofollow noopener">https://github.com/KaimingHe/deep-residual-networks/blob/master/prototxt/ResNet-101-deploy.prototxt</a></p>

username: Andrew_Paint
cooked: <p>The naming rule of ResNet as follows:<br>
stage 2 and stage 5 both have 3 layers, so they are named as ‘a’, ‘b’, and ‘c’.<br>
stage 3 and stage 4 has more than 3 layers. And there are clear differences between the first layer and rest layers of those two stages. So, their first layer is named as ‘a’, and rest layers are all 'b’s. In order to differentiate those 'b’s, they are named as ‘b1’, ‘b2’, and so on. Hence, for ResNet-101, stage 4 has 23 layers. They are one ‘a’ layer and 22 ‘b’ layers, ranging from ‘b1’ to ‘b22’.</p>