MCPcopy Create free account
hub / github.com/Sygil-Dev/sygil-webui / forward

Method forward

ldm/modules/diffusionmodules/model.py:71–78  ·  view source on GitHub ↗
(self, x)

Source from the content-addressed store, hash-verified

69 )
70
71 def forward(self, x):
72 if self.with_conv:
73 pad = (0, 1, 0, 1)
74 x = torch.nn.functional.pad(x, pad, mode="constant", value=0)
75 x = self.conv(x)
76 else:
77 x = torch.nn.functional.avg_pool2d(x, kernel_size=2, stride=2)
78 return x
79
80
81class ResnetBlock(nn.Module):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected