MCPcopy Create free account
hub / github.com/RolandGao/RegSeg / __init__

Method __init__

competitor_blocks.py:85–93  ·  view source on GitHub ↗
(self, in_chan, out_chan)

Source from the content-addressed store, hash-verified

83 return x
84class AttentionRefinementModule(nn.Module):
85 def __init__(self, in_chan, out_chan):
86 super(AttentionRefinementModule, self).__init__()
87 self.conv=ConvBnAct(in_chan,out_chan,3,1,1)
88 self.scale = nn.Sequential(
89 nn.AdaptiveAvgPool2d(1),
90 nn.Conv2d(out_chan, out_chan, 1, bias=False),
91 nn.BatchNorm2d(out_chan),
92 nn.Sigmoid(),
93 )
94
95 def forward(self, x):
96 x = self.conv(x)

Callers

nothing calls this directly

Calls 2

ConvBnActClass · 0.90
__init__Method · 0.45

Tested by

no test coverage detected