MCPcopy
hub / github.com/DingXiaoH/RepVGG / __init__

Method __init__

example_pspnet.py:10–20  ·  view source on GitHub ↗
(self, in_dim, reduction_dim, bins, BatchNorm)

Source from the content-addressed store, hash-verified

8
9class PPM(nn.Module):
10 def __init__(self, in_dim, reduction_dim, bins, BatchNorm):
11 super(PPM, self).__init__()
12 self.features = []
13 for bin in bins:
14 self.features.append(nn.Sequential(
15 nn.AdaptiveAvgPool2d(bin),
16 nn.Conv2d(in_dim, reduction_dim, kernel_size=1, bias=False),
17 BatchNorm(reduction_dim),
18 nn.ReLU(inplace=True)
19 ))
20 self.features = nn.ModuleList(self.features)
21
22 def forward(self, x):
23 x_size = x.size()

Callers 1

__init__Method · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected