Manjushri commited on
Commit
3c290dc
1 Parent(s): abaf388

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -3,14 +3,14 @@ import modin.pandas as pd
3
  import torch
4
  import numpy as np
5
  from PIL import Image
6
- from diffusers import StableDiffusionImg2ImgPipeline
7
  from huggingface_hub import login
8
  import os
9
 
10
  login(token=os.environ.get('HF_KEY'))
11
 
12
  device = "cuda" if torch.cuda.is_available() else "cpu"
13
- pipe = StableDiffusionImg2ImgPipeline.from_pretrained("stabilityai/stable-diffusion-xl-refiner-0.9", torch_dtype=torch.float16) if torch.cuda.is_available() else StableDiffusionImg2ImgPipeline.from_pretrained("stabilityai/stable-diffusion-xl-refiner-0.9")
14
  pipe = pipe.to(device)
15
 
16
  def resize(value,img):
 
3
  import torch
4
  import numpy as np
5
  from PIL import Image
6
+ from diffusers import StableDiffusionPipeline
7
  from huggingface_hub import login
8
  import os
9
 
10
  login(token=os.environ.get('HF_KEY'))
11
 
12
  device = "cuda" if torch.cuda.is_available() else "cpu"
13
+ pipe = StableDiffusionPipeline.from_pretrained("stabilityai/stable-diffusion-xl-refiner-0.9", torch_dtype=torch.float16) if torch.cuda.is_available() else StableDiffusionPipeline.from_pretrained("stabilityai/stable-diffusion-xl-refiner-0.9")
14
  pipe = pipe.to(device)
15
 
16
  def resize(value,img):