Selim321 commited on
Commit
f0dde55
·
1 Parent(s): 60be308

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -0
app.py CHANGED
@@ -9,6 +9,8 @@ device = "cpu"
9
  model_id_or_path = "runwayml/stable-diffusion-v1-5"
10
  pipe = StableDiffusionImg2ImgPipeline.from_pretrained(model_id_or_path, torch_dtype=torch.float16,)
11
  pipe = pipe.to(device)
 
 
12
 
13
 
14
  def transform (init_image, textPrompt, strength=0.5, guidance_scale=15):
 
9
  model_id_or_path = "runwayml/stable-diffusion-v1-5"
10
  pipe = StableDiffusionImg2ImgPipeline.from_pretrained(model_id_or_path, torch_dtype=torch.float16,)
11
  pipe = pipe.to(device)
12
+ pipe.enable_attention_slicing()
13
+
14
 
15
 
16
  def transform (init_image, textPrompt, strength=0.5, guidance_scale=15):