MCPcopy Create free account
hub / github.com/Royalvice/DocDiff / __init__

Method __init__

model/DocDiff.py:140–144  ·  view source on GitHub ↗
(self, in_channels: int, out_channels: int, time_channels: int, is_noise: bool = True)

Source from the content-addressed store, hash-verified

138 """
139
140 def __init__(self, in_channels: int, out_channels: int, time_channels: int, is_noise: bool = True):
141 super().__init__()
142 # The input has `in_channels + out_channels` because we concatenate the output of the same resolution
143 # from the first half of the U-Net
144 self.res = ResidualBlock(in_channels + out_channels, out_channels, time_channels, is_noise=is_noise)
145
146 def forward(self, x: torch.Tensor, t: torch.Tensor):
147 x = self.res(x, t)

Callers

nothing calls this directly

Calls 2

ResidualBlockClass · 0.85
__init__Method · 0.45

Tested by

no test coverage detected