MCPcopy Create free account
hub / github.com/alinlab/SelfPatch / forward

Method forward

segmentation/backbones/mit.py:82–88  ·  view source on GitHub ↗
(self, x, hw_shape, identity=None)

Source from the content-addressed store, hash-verified

80 dropout_layer) if dropout_layer else torch.nn.Identity()
81
82 def forward(self, x, hw_shape, identity=None):
83 out = nlc_to_nchw(x, hw_shape)
84 out = self.layers(out)
85 out = nchw_to_nlc(out)
86 if identity is None:
87 identity = x
88 return identity + self.dropout_layer(out)
89
90
91class EfficientMultiheadAttention(MultiheadAttention):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected