Spaces:
Sleeping
Sleeping
Support AdamW optimizer
Browse files- app.py +1 -1
- inference.py +1 -1
- style_images/Scream.jpg +3 -0
app.py
CHANGED
@@ -55,7 +55,7 @@ def run(content_image, style_name, style_strength, output_quality, progress=gr.P
|
|
55 |
print('HIGH QUALITY:', output_quality)
|
56 |
|
57 |
style_features = cached_style_features[style_name][0 if img_size == 512 else 1]
|
58 |
-
converted_lr = 0.001 + (0.
|
59 |
|
60 |
st = time.time()
|
61 |
generated_img = inference(
|
|
|
55 |
print('HIGH QUALITY:', output_quality)
|
56 |
|
57 |
style_features = cached_style_features[style_name][0 if img_size == 512 else 1]
|
58 |
+
converted_lr = 0.001 + (0.009 / 99) * (style_strength - 1) # [0.001, 0.01]
|
59 |
|
60 |
st = time.time()
|
61 |
generated_img = inference(
|
inference.py
CHANGED
@@ -26,7 +26,7 @@ def inference(
|
|
26 |
content_image,
|
27 |
style_features,
|
28 |
lr,
|
29 |
-
iterations=
|
30 |
optim_caller=optim.AdamW,
|
31 |
alpha=1,
|
32 |
beta=1
|
|
|
26 |
content_image,
|
27 |
style_features,
|
28 |
lr,
|
29 |
+
iterations=100,
|
30 |
optim_caller=optim.AdamW,
|
31 |
alpha=1,
|
32 |
beta=1
|
style_images/Scream.jpg
ADDED
Git LFS Details
|