Spaces:
Running
on
Zero
Running
on
Zero
resize back 32
Browse files
app.py
CHANGED
@@ -76,9 +76,9 @@ def process_images(image,prompt="a girl",strength=0.75,seed=0,inference_step=4,p
|
|
76 |
# resize back multiple of 32
|
77 |
if (new_width!=fit_width) or (new_height!=fit_height):
|
78 |
resized_image= pil_image.resize(fit_width,fit_height,Image.LANCZOS)
|
79 |
-
return resized_image
|
80 |
|
81 |
-
return pil_image
|
82 |
|
83 |
output = process_img2img(image,prompt,strength,seed,inference_step)
|
84 |
|
@@ -142,7 +142,7 @@ with gr.Blocks(css=css, elem_id="demo-container") as demo:
|
|
142 |
id_input=gr.Text(label="Name", visible=False)
|
143 |
|
144 |
with gr.Column():
|
145 |
-
image_out = gr.Image(height=800,sources=[],label="Output", elem_id="output-img",format="jpg"
|
146 |
|
147 |
|
148 |
|
|
|
76 |
# resize back multiple of 32
|
77 |
if (new_width!=fit_width) or (new_height!=fit_height):
|
78 |
resized_image= pil_image.resize(fit_width,fit_height,Image.LANCZOS)
|
79 |
+
return np.array(resized_image)
|
80 |
|
81 |
+
return np.array(pil_image)
|
82 |
|
83 |
output = process_img2img(image,prompt,strength,seed,inference_step)
|
84 |
|
|
|
142 |
id_input=gr.Text(label="Name", visible=False)
|
143 |
|
144 |
with gr.Column():
|
145 |
+
image_out = gr.Image(height=800,sources=[],label="Output", elem_id="output-img",format="jpg")
|
146 |
|
147 |
|
148 |
|