zhiweili
commited on
Commit
·
bd5747f
1
Parent(s):
4743900
fix image format error
Browse files- app_base.py +3 -1
app_base.py
CHANGED
|
@@ -17,7 +17,7 @@ def create_demo() -> gr.Blocks:
|
|
| 17 |
|
| 18 |
@spaces.GPU(duration=10)
|
| 19 |
def image_to_image(
|
| 20 |
-
|
| 21 |
input_image_prompt: str,
|
| 22 |
edit_prompt: str,
|
| 23 |
seed: int,
|
|
@@ -29,6 +29,8 @@ def create_demo() -> gr.Blocks:
|
|
| 29 |
):
|
| 30 |
w2 = 1.0
|
| 31 |
|
|
|
|
|
|
|
| 32 |
run_model = base_run
|
| 33 |
res_image = run_model(
|
| 34 |
input_image,
|
|
|
|
| 17 |
|
| 18 |
@spaces.GPU(duration=10)
|
| 19 |
def image_to_image(
|
| 20 |
+
input_image_path: str,
|
| 21 |
input_image_prompt: str,
|
| 22 |
edit_prompt: str,
|
| 23 |
seed: int,
|
|
|
|
| 29 |
):
|
| 30 |
w2 = 1.0
|
| 31 |
|
| 32 |
+
input_image = Image.open(input_image_path)
|
| 33 |
+
|
| 34 |
run_model = base_run
|
| 35 |
res_image = run_model(
|
| 36 |
input_image,
|