aboutsummaryrefslogtreecommitdiffstats
path: root/modules/codeformer
diff options
context:
space:
mode:
authorAUTOMATIC <16777216c@gmail.com>2023-05-10 18:21:32 +0000
committerAUTOMATIC <16777216c@gmail.com>2023-05-10 18:21:32 +0000
commit3ec7b705c78b7aca9569c92a419837352c7a4ec6 (patch)
tree98248bc21aa4ad9715205f0a65a654532c6cfcc0 /modules/codeformer
parentd25219b7e889cf34bccae9cb88497708796efda2 (diff)
downloadstable-diffusion-webui-gfx803-3ec7b705c78b7aca9569c92a419837352c7a4ec6.tar.gz
stable-diffusion-webui-gfx803-3ec7b705c78b7aca9569c92a419837352c7a4ec6.tar.bz2
stable-diffusion-webui-gfx803-3ec7b705c78b7aca9569c92a419837352c7a4ec6.zip
suggestions and fixes from the PR
Diffstat (limited to 'modules/codeformer')
-rw-r--r--modules/codeformer/codeformer_arch.py7
1 files changed, 2 insertions, 5 deletions
diff --git a/modules/codeformer/codeformer_arch.py b/modules/codeformer/codeformer_arch.py
index ff1c0b4b..45c70f84 100644
--- a/modules/codeformer/codeformer_arch.py
+++ b/modules/codeformer/codeformer_arch.py
@@ -161,13 +161,10 @@ class Fuse_sft_block(nn.Module):
class CodeFormer(VQAutoEncoder):
def __init__(self, dim_embd=512, n_head=8, n_layers=9,
codebook_size=1024, latent_size=256,
- connect_list=None,
- fix_modules=None):
+ connect_list=('32', '64', '128', '256'),
+ fix_modules=('quantize', 'generator')):
super(CodeFormer, self).__init__(512, 64, [1, 2, 2, 4, 4, 8], 'nearest',2, [16], codebook_size)
- connect_list = connect_list or ['32', '64', '128', '256']
- fix_modules = fix_modules or ['quantize', 'generator']
-
if fix_modules is not None:
for module in fix_modules:
for param in getattr(self, module).parameters():