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

Class WanLayerNorm

models/wan/model.py:89–99  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

87
88
89class WanLayerNorm(nn.LayerNorm):
90
91 def __init__(self, dim, eps=1e-6, elementwise_affine=False):
92 super().__init__(dim, elementwise_affine=elementwise_affine, eps=eps)
93
94 def forward(self, x):
95 r"""
96 Args:
97 x(Tensor): Shape [B, L, C]
98 """
99 return super().forward(x.float()).type_as(x)
100
101
102class WanSelfAttention(nn.Module):

Callers 2

__init__Method · 0.85
__init__Method · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected