(self, source: Tensor, pos_map: Tensor = None)
| 218 | self.depth = depth |
| 219 | |
| 220 | def forward(self, source: Tensor, pos_map: Tensor = None) -> Tensor: |
| 221 | x = source |
| 222 | |
| 223 | x = self.norm1(x) |
| 224 | |
| 225 | x = self.cat(x, pos_map) |
| 226 | x = self.conv1(x) |
| 227 | x = self.activation(x) |
| 228 | |
| 229 | att = self.attention(x) |
| 230 | |
| 231 | x = x * att |
| 232 | x = self.conv2(x) |
| 233 | |
| 234 | x = self.dropout1(x) |
| 235 | |
| 236 | y = source + x * self.beta |
| 237 | |
| 238 | x = self.conv3(self.norm2(y)) |
| 239 | x = self.activation(x) |
| 240 | x = self.conv4(x) |
| 241 | |
| 242 | x = self.dropout2(x) |
| 243 | |
| 244 | ret = y + x * self.gamma |
| 245 | |
| 246 | return ret |
| 247 | |
| 248 | class FeedForwardNetwork(nn.Module): |
| 249 | def __init__( |
nothing calls this directly
no outgoing calls
no test coverage detected