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

Method __init__

lib/VIT/decoder/decoder_p.py:82–87  ·  view source on GitHub ↗
(self, dim, LayerNorm_type)

Source from the content-addressed store, hash-verified

80
81class LayerNorm(nn.Module):
82 def __init__(self, dim, LayerNorm_type):
83 super(LayerNorm, self).__init__()
84 if LayerNorm_type =='BiasFree':
85 self.body = BiasFree_LayerNorm(dim)
86 else:
87 self.body = WithBias_LayerNorm(dim)
88
89 def forward(self, x):
90 h, w = x.shape[-2:]

Callers

nothing calls this directly

Calls 3

BiasFree_LayerNormClass · 0.85
WithBias_LayerNormClass · 0.85
__init__Method · 0.45

Tested by

no test coverage detected