Upload server.py
Browse files
server.py
CHANGED
@@ -10,7 +10,7 @@ device = torch.device('cuda' if torch.cuda.is_available() else 'cpu')
|
|
10 |
# stable diffusion (inpainting)
|
11 |
sd_pipe = StableDiffusionInpaintPipeline.from_pretrained(
|
12 |
"stabilityai/stable-diffusion-2-inpainting",
|
13 |
-
torch_dtype=torch.float16,
|
14 |
).to(device)
|
15 |
|
16 |
def generate_image(image, mask, prompt, negative_prompt, pipe, seed):
|
|
|
10 |
# stable diffusion (inpainting)
|
11 |
sd_pipe = StableDiffusionInpaintPipeline.from_pretrained(
|
12 |
"stabilityai/stable-diffusion-2-inpainting",
|
13 |
+
# torch_dtype=torch.float16,
|
14 |
).to(device)
|
15 |
|
16 |
def generate_image(image, mask, prompt, negative_prompt, pipe, seed):
|