MCPcopy Create free account
hub / github.com/tdrussell/diffusion-pipe / forward

Method forward

models/ideogram4.py:233–240  ·  view source on GitHub ↗
(self, inputs)

Source from the content-addressed store, hash-verified

231
232 @torch.autocast('cuda', dtype=AUTOCAST_DTYPE)
233 def forward(self, inputs):
234 h, attn_mask, adaln_input, sizes, *freqs_cis = inputs
235
236 self.offloader.wait_for_block(self.block_idx)
237 h = self.layer(h, attn_mask, freqs_cis, adaln_input)
238 self.offloader.submit_move_blocks_forward(self.block_idx)
239
240 return make_contiguous(h, attn_mask, adaln_input, sizes, *freqs_cis)
241
242
243class FinalLayer(nn.Module):

Callers

nothing calls this directly

Calls 3

make_contiguousFunction · 0.90
wait_for_blockMethod · 0.80

Tested by

no test coverage detected