fffiloni commited on
Commit
ba5d2e8
1 Parent(s): 2e85629

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -9
app.py CHANGED
@@ -22,15 +22,15 @@ def infer(prompt, init_image):
22
  init_image = Image.open(init_image).convert("RGB")
23
  init_image = init_image.resize((128, 128))
24
 
25
- with torch.autocast('cuda'):
26
- res = pipe.train(
27
- prompt,
28
- init_image,
29
- guidance_scale=7.5,
30
- num_inference_steps=50,
31
- generator=generator,
32
- text_embedding_optimization_steps=100,
33
- model_fine_tuning_optimization_steps=500)
34
 
35
  #with torch.no_grad():
36
  # torch.cuda.empty_cache()
 
22
  init_image = Image.open(init_image).convert("RGB")
23
  init_image = init_image.resize((128, 128))
24
 
25
+
26
+ res = pipe.train(
27
+ prompt,
28
+ init_image,
29
+ guidance_scale=7.5,
30
+ num_inference_steps=50,
31
+ generator=generator,
32
+ text_embedding_optimization_steps=100,
33
+ model_fine_tuning_optimization_steps=500)
34
 
35
  #with torch.no_grad():
36
  # torch.cuda.empty_cache()