MCPcopy Create free account
hub / github.com/Meshcapade/difflocks / NoAttentionTransformerLayer

Class NoAttentionTransformerLayer

k_diffusion/models/modules.py:545–552  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

543
544
545class NoAttentionTransformerLayer(nn.Module):
546 def __init__(self, d_model, d_ff, cond_features, dropout=0.0):
547 super().__init__()
548 self.ff = FeedForwardBlock(d_model, d_ff, cond_features, dropout=dropout)
549
550 def forward(self, x, pos, cond):
551 x = checkpoint(self.ff, x, cond)
552 return x
553
554
555class Level(nn.ModuleList):

Callers 1

__init__Method · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected