Spaces:
Runtime error
Runtime error
remove to device
Browse files
app.py
CHANGED
@@ -36,7 +36,6 @@ def download_image(url):
|
|
36 |
response = requests.get(url)
|
37 |
return PIL.Image.open(BytesIO(response.content)).convert("RGB")
|
38 |
|
39 |
-
device = "cpu"
|
40 |
model_path = "runwayml/stable-diffusion-inpainting"
|
41 |
|
42 |
pipe = StableDiffusionInpaintPipeline.from_pretrained(
|
@@ -44,7 +43,7 @@ pipe = StableDiffusionInpaintPipeline.from_pretrained(
|
|
44 |
revision="fp16",
|
45 |
torch_dtype=torch.float16,
|
46 |
use_auth_token=True
|
47 |
-
)
|
48 |
|
49 |
img_url = "https://cdn.faire.com/fastly/893b071985d70819da5f0d485f1b1bb97ee4f16a6e14ef1bdd4a086b3588be58.png" # wino
|
50 |
image = download_image(img_url).resize((512, 512))
|
|
|
36 |
response = requests.get(url)
|
37 |
return PIL.Image.open(BytesIO(response.content)).convert("RGB")
|
38 |
|
|
|
39 |
model_path = "runwayml/stable-diffusion-inpainting"
|
40 |
|
41 |
pipe = StableDiffusionInpaintPipeline.from_pretrained(
|
|
|
43 |
revision="fp16",
|
44 |
torch_dtype=torch.float16,
|
45 |
use_auth_token=True
|
46 |
+
)
|
47 |
|
48 |
img_url = "https://cdn.faire.com/fastly/893b071985d70819da5f0d485f1b1bb97ee4f16a6e14ef1bdd4a086b3588be58.png" # wino
|
49 |
image = download_image(img_url).resize((512, 512))
|