MCPcopy Create free account
hub / github.com/deepbrainai-research/float / __init__

Method __init__

models/__init__.py:240–255  ·  view source on GitHub ↗
(self, inplanes, planes, stride=1, downsample=None, groups=1,
                 base_width=64, dilation=1, norm_layer=None,
                 *, reduction=16)

Source from the content-addressed store, hash-verified

238 expansion = 4
239
240 def __init__(self, inplanes, planes, stride=1, downsample=None, groups=1,
241 base_width=64, dilation=1, norm_layer=None,
242 *, reduction=16):
243 super(SEBottleneck, self).__init__()
244 if norm_layer is None:
245 norm_layer= nn.BatchNorm2d
246 self.conv1 = nn.Conv2d(inplanes, planes, kernel_size=1, bias=False)
247 self.bn1 = norm_layer(planes)
248 self.conv2 = nn.Conv2d(planes, planes, kernel_size=3, stride=stride, padding=1, bias=False)
249 self.bn2 = norm_layer(planes)
250 self.conv3 = nn.Conv2d(planes, planes * 4, kernel_size=1, bias=False)
251 self.bn3 = norm_layer(planes * 4)
252 self.relu = nn.ReLU(inplace=True)
253 self.se = SELayer(planes * 4, reduction)
254 self.downsample = downsample
255 self.stride = stride
256
257 def forward(self, x):
258 residual = x

Callers

nothing calls this directly

Calls 2

SELayerClass · 0.85
__init__Method · 0.45

Tested by

no test coverage detected