MCPcopy Create free account
hub / github.com/ChunmingHe/WS-SAM / __init__

Method __init__

lib/Modules.py:975–985  ·  view source on GitHub ↗
(self, in_channels)

Source from the content-addressed store, hash-verified

973
974class Decoder_noRCAB(nn.Module):
975 def __init__(self, in_channels):
976 super(Decoder_noRCAB, self).__init__()
977
978 self.spade_a = Spade(in_channels, in_channels)
979 self.spade_b = Spade(in_channels, in_channels)
980
981 self.crb = BasicConv2d(in_channels*2, in_channels, kernel_size=3, padding=1)
982 self.out_e = nn.Conv2d(in_channels, 1, kernel_size=3, padding=1)
983
984 self.conv3x3 = BasicConv2d(in_channels * 2, in_channels, kernel_size=3, padding=1)
985 self.out_s = nn.Conv2d(in_channels, 1, kernel_size=3, padding=1)
986
987 def forward(self, f, f_s, f_e, p_s, p_e):
988 prior_cam = F.interpolate(p_s, size=f.size()[2:], mode='bilinear', align_corners=True) # 2,1,12,12->2,1,48,48

Callers

nothing calls this directly

Calls 3

SpadeClass · 0.85
BasicConv2dClass · 0.85
__init__Method · 0.45

Tested by

no test coverage detected