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

Method forward

models/modules/attentions.py:16–22  ·  view source on GitHub ↗
(self, x)

Source from the content-addressed store, hash-verified

14 self.sigmoid = nn.Sigmoid()
15
16 def forward(self, x):
17 out = self.avg_pool(x)
18 out = self.fc1(out)
19 out = self.relu(out)
20 out = self.fc2(out)
21 weight = self.sigmoid(out)
22 return weight
23
24
25class PSA(nn.Module):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected