MCPcopy
hub / github.com/Robbyant/lingbot-world / forward

Method forward

wan/modules/t5.py:301–310  ·  view source on GitHub ↗
(self, ids, mask=None)

Source from the content-addressed store, hash-verified

299 self.apply(init_weights)
300
301 def forward(self, ids, mask=None):
302 x = self.token_embedding(ids)
303 x = self.dropout(x)
304 e = self.pos_embedding(x.size(1),
305 x.size(1)) if self.shared_pos else None
306 for block in self.blocks:
307 x = block(x, mask, pos_bias=e)
308 x = self.norm(x)
309 x = self.dropout(x)
310 return x
311
312
313class T5Decoder(nn.Module):

Callers

nothing calls this directly

Calls 1

sizeMethod · 0.80

Tested by

no test coverage detected