Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -304,7 +304,13 @@ def sample_then_run():
|
|
304 |
steps = 25
|
305 |
image = inference( prompt, negative_prompt, cfg, steps, seed)
|
306 |
torch.save(network.value.proj, "model.pt" )
|
307 |
-
net =
|
|
|
|
|
|
|
|
|
|
|
|
|
308 |
|
309 |
return image, "model.pt", net #, network.value.cpu()
|
310 |
|
|
|
304 |
steps = 25
|
305 |
image = inference( prompt, negative_prompt, cfg, steps, seed)
|
306 |
torch.save(network.value.proj, "model.pt" )
|
307 |
+
net = LoRAw2w( sample, mean, std, v,
|
308 |
+
unet,
|
309 |
+
rank=1,
|
310 |
+
multiplier=1.0,
|
311 |
+
alpha=27.0,
|
312 |
+
train_method="xattn-strict"
|
313 |
+
).to(device.value, torch.bfloat16)
|
314 |
|
315 |
return image, "model.pt", net #, network.value.cpu()
|
316 |
|