(self, x)
| 94 | return nn.Sequential(*layers) |
| 95 | |
| 96 | def forward(self, x): |
| 97 | bsz = x.size(0) |
| 98 | out = relu(self.bn1(self.conv1(x.view(bsz, 3, 32, 32)))) |
| 99 | out = self.layer1(out) |
| 100 | out = self.layer2(out) |
| 101 | out = self.layer3(out) |
| 102 | out = self.layer4(out) |
| 103 | out = avg_pool2d(out, 4) |
| 104 | out = out.view(out.size(0), -1) |
| 105 | out = self.linear(out) |
| 106 | return out |
| 107 | |
| 108 | |
| 109 | def ResNet18(nclasses, nf=20, bias=True): |
nothing calls this directly
no outgoing calls
no test coverage detected