Spaces:
Running
Running
justin2341
commited on
Update demo.py
Browse files
demo.py
CHANGED
@@ -135,31 +135,6 @@ with gr.Blocks() as demo:
|
|
135 |
##### Documentation - Help Center - https://docs.kby-ai.com
|
136 |
"""
|
137 |
)
|
138 |
-
with gr.TabItem("Face Recognition"):
|
139 |
-
gr.Markdown(
|
140 |
-
"""
|
141 |
-
##### Docker Hub - https://hub.docker.com/r/kbyai/face-recognition
|
142 |
-
```bash
|
143 |
-
sudo docker pull kbyai/face-recognition:latest
|
144 |
-
sudo docker run -e LICENSE="xxxxx" -p 8081:8080 -p 9001:9000 kbyai/face-recognition:latest
|
145 |
-
```
|
146 |
-
"""
|
147 |
-
)
|
148 |
-
with gr.Column(scale=7):
|
149 |
-
with gr.Row():
|
150 |
-
with gr.Column():
|
151 |
-
image_input1 = gr.Image(type='filepath')
|
152 |
-
gr.Examples(['face_examples/1.jpg', 'face_examples/3.jpg', 'face_examples/5.jpg', 'face_examples/7.jpg', 'face_examples/9.jpg'],
|
153 |
-
inputs=image_input1)
|
154 |
-
with gr.Column():
|
155 |
-
image_input2 = gr.Image(type='filepath')
|
156 |
-
gr.Examples(['face_examples/2.jpg', 'face_examples/4.jpg', 'face_examples/6.jpg', 'face_examples/8.jpg', 'face_examples/10.jpg'],
|
157 |
-
inputs=image_input2)
|
158 |
-
face_recog_button = gr.Button("Compare Face", variant="primary", size="lg")
|
159 |
-
with gr.Column(scale=3):
|
160 |
-
recog_html_output = gr.HTML()
|
161 |
-
|
162 |
-
face_recog_button.click(compare_face, inputs=[image_input1, image_input2], outputs=recog_html_output)
|
163 |
gr.HTML('<a href="https://visitorbadge.io/status?path=https%3A%2F%2Fhuggingface.co%2Fspaces%2Fkby-ai%2FFaceRecognition"><img src="https://api.visitorbadge.io/api/combined?path=https%3A%2F%2Fhuggingface.co%2Fspaces%2Fkby-ai%2FFaceRecognition&countColor=%23263759" /></a>')
|
164 |
|
165 |
demo.launch(server_name="0.0.0.0", server_port=7860, share=True)
|
|
|
135 |
##### Documentation - Help Center - https://docs.kby-ai.com
|
136 |
"""
|
137 |
)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
138 |
gr.HTML('<a href="https://visitorbadge.io/status?path=https%3A%2F%2Fhuggingface.co%2Fspaces%2Fkby-ai%2FFaceRecognition"><img src="https://api.visitorbadge.io/api/combined?path=https%3A%2F%2Fhuggingface.co%2Fspaces%2Fkby-ai%2FFaceRecognition&countColor=%23263759" /></a>')
|
139 |
|
140 |
demo.launch(server_name="0.0.0.0", server_port=7860, share=True)
|