Spaces:
Running
Running
justin2341
commited on
Update demo.py
Browse files
demo.py
CHANGED
@@ -148,19 +148,20 @@ with gr.Blocks() as demo:
|
|
148 |
```
|
149 |
"""
|
150 |
)
|
151 |
-
with gr.
|
152 |
-
with gr.
|
153 |
-
with gr.
|
154 |
-
|
155 |
-
|
156 |
-
|
157 |
-
|
158 |
-
|
159 |
-
|
160 |
-
|
161 |
-
|
162 |
-
|
163 |
-
|
|
|
164 |
|
165 |
face_recog_button.click(compare_face, inputs=[image_input1, image_input2], outputs=recog_html_output)
|
166 |
|
|
|
148 |
```
|
149 |
"""
|
150 |
)
|
151 |
+
with gr.Row():
|
152 |
+
with gr.Column(scale=7):
|
153 |
+
with gr.Row():
|
154 |
+
with gr.Column():
|
155 |
+
image_input1 = gr.Image(type='filepath')
|
156 |
+
gr.Examples(['face_examples/1.jpg', 'face_examples/3.jpg', 'face_examples/5.jpg', 'face_examples/7.jpg', 'face_examples/9.jpg'],
|
157 |
+
inputs=image_input1)
|
158 |
+
with gr.Column():
|
159 |
+
image_input2 = gr.Image(type='filepath')
|
160 |
+
gr.Examples(['face_examples/2.jpg', 'face_examples/4.jpg', 'face_examples/6.jpg', 'face_examples/8.jpg', 'face_examples/10.jpg'],
|
161 |
+
inputs=image_input2)
|
162 |
+
face_recog_button = gr.Button("Compare Face", variant="primary", size="lg")
|
163 |
+
with gr.Column(scale=3):
|
164 |
+
recog_html_output = gr.HTML()
|
165 |
|
166 |
face_recog_button.click(compare_face, inputs=[image_input1, image_input2], outputs=recog_html_output)
|
167 |
|