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

Method forward

k_diffusion/layers.py:428–430  ·  view source on GitHub ↗
(self, input)

Source from the content-addressed store, hash-verified

426 self.register_buffer('weight', torch.randn([out_features // 2, in_features]) * std)
427
428 def forward(self, input):
429 f = 2 * math.pi * input @ self.weight.T
430 return torch.cat([f.cos(), f.sin()], dim=-1)
431
432
433# U-Nets

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected