Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -84,7 +84,8 @@ def infer(
|
|
| 84 |
controlnet=controlnet,
|
| 85 |
torch_dtype=torch_dtype,
|
| 86 |
safety_checker=None).to(device)
|
| 87 |
-
controlnet_image = load_image(controlnet_image).convert('RGB')
|
|
|
|
| 88 |
else:
|
| 89 |
pipe = StableDiffusionPipeline.from_pretrained(model_id,
|
| 90 |
torch_dtype=torch_dtype,
|
|
@@ -250,8 +251,7 @@ with gr.Blocks(css=css, fill_height=True) as demo:
|
|
| 250 |
)
|
| 251 |
ip_adapter_image = gr.Image(
|
| 252 |
label="IPAdapter condition image",
|
| 253 |
-
type="pil"
|
| 254 |
-
format="png"
|
| 255 |
)
|
| 256 |
ip_adapter_checkbox.change(
|
| 257 |
fn=lambda x: gr.Row.update(visible=x),
|
|
|
|
| 84 |
controlnet=controlnet,
|
| 85 |
torch_dtype=torch_dtype,
|
| 86 |
safety_checker=None).to(device)
|
| 87 |
+
controlnet_image = load_image(controlnet_image).convert('RGB')
|
| 88 |
+
print(type(controlnet_image))
|
| 89 |
else:
|
| 90 |
pipe = StableDiffusionPipeline.from_pretrained(model_id,
|
| 91 |
torch_dtype=torch_dtype,
|
|
|
|
| 251 |
)
|
| 252 |
ip_adapter_image = gr.Image(
|
| 253 |
label="IPAdapter condition image",
|
| 254 |
+
type="pil"
|
|
|
|
| 255 |
)
|
| 256 |
ip_adapter_checkbox.change(
|
| 257 |
fn=lambda x: gr.Row.update(visible=x),
|