Add `.to("cuda")` to the example snippet for float16 compatibility #25
by
anton-l
HF staff
- opened
README.md
CHANGED
@@ -42,6 +42,7 @@ pipe = StableDiffusionInpaintPipeline.from_pretrained(
|
|
42 |
revision="fp16",
|
43 |
torch_dtype=torch.float16,
|
44 |
)
|
|
|
45 |
prompt = "Face of a yellow cat, high resolution, sitting on a park bench"
|
46 |
#image and mask_image should be PIL images.
|
47 |
#The mask structure is white for inpainting and black for keeping as is
|
42 |
revision="fp16",
|
43 |
torch_dtype=torch.float16,
|
44 |
)
|
45 |
+
pipe.to("cuda")
|
46 |
prompt = "Face of a yellow cat, high resolution, sitting on a park bench"
|
47 |
#image and mask_image should be PIL images.
|
48 |
#The mask structure is white for inpainting and black for keeping as is
|