MCPcopy Create free account
hub / github.com/ZhengPeng7/BiRefNet / forward

Method forward

models/modules/mlp.py:112–117  ·  view source on GitHub ↗
(self, x)

Source from the content-addressed store, hash-verified

110 self.norm = nn.LayerNorm(embed_dim)
111
112 def forward(self, x):
113 x = self.proj(x)
114 _, _, H, W = x.shape
115 x = x.flatten(2).transpose(1, 2)
116 x = self.norm(x)
117 return x, H, W
118

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected