MCPcopy Create free account
hub / github.com/OpenImagingLab/FlashVSR / __init__

Method __init__

diffsynth/models/sd3_dit.py:70–75  ·  view source on GitHub ↗
(self, dim, single=False, dual=False)

Source from the content-addressed store, hash-verified

68
69class AdaLayerNorm(torch.nn.Module):
70 def __init__(self, dim, single=False, dual=False):
71 super().__init__()
72 self.single = single
73 self.dual = dual
74 self.linear = torch.nn.Linear(dim, dim * [[6, 2][single], 9][dual])
75 self.norm = torch.nn.LayerNorm(dim, elementwise_affine=False, eps=1e-6)
76
77 def forward(self, x, emb):
78 emb = self.linear(torch.nn.functional.silu(emb))

Callers

nothing calls this directly

Calls 1

__init__Method · 0.45

Tested by

no test coverage detected