MCPcopy Create free account
hub / github.com/PowerHouseMan/ComfyUI-AdvancedLivePortrait / __init__

Method __init__

LivePortrait/modules/util.py:191–197  ·  view source on GitHub ↗
(self, block_expansion, in_features, num_blocks=3, max_features=256)

Source from the content-addressed store, hash-verified

189 """
190
191 def __init__(self, block_expansion, in_features, num_blocks=3, max_features=256):
192 super(Encoder, self).__init__()
193
194 down_blocks = []
195 for i in range(num_blocks):
196 down_blocks.append(DownBlock3d(in_features if i == 0 else min(max_features, block_expansion * (2 ** i)), min(max_features, block_expansion * (2 ** (i + 1))), kernel_size=3, padding=1))
197 self.down_blocks = nn.ModuleList(down_blocks)
198
199 def forward(self, x):
200 outs = [x]

Callers

nothing calls this directly

Calls 2

DownBlock3dClass · 0.85
__init__Method · 0.45

Tested by

no test coverage detected