Spaces:
Runtime error
Runtime error
Commit
·
1ebca6a
1
Parent(s):
4cf5032
Agregada función de clasificar imágenes (#1)
Browse files- Agregada función de clasificar imágenes (4720fd5eab89c5c9cb3568bcc53fedfa70a2fd3b)
Co-authored-by: Gabriel Ichcanziho <[email protected]>
app.py
CHANGED
|
@@ -20,13 +20,16 @@ with demo:
|
|
| 20 |
b2 = gr.Button('Dime el sentimiento por favor')
|
| 21 |
|
| 22 |
with gr.TabItem('Clasificador de imágenes perros VS gatos'):
|
| 23 |
-
|
| 24 |
-
|
| 25 |
-
|
| 26 |
-
|
| 27 |
|
| 28 |
|
| 29 |
b1.click(audio_a_text, inputs = audio, outputs = transcription)
|
| 30 |
b2.click(texto_a_sentimiento, inputs = texto, outputs = label)
|
|
|
|
|
|
|
|
|
|
| 31 |
|
| 32 |
demo.launch()
|
|
|
|
| 20 |
b2 = gr.Button('Dime el sentimiento por favor')
|
| 21 |
|
| 22 |
with gr.TabItem('Clasificador de imágenes perros VS gatos'):
|
| 23 |
+
with gr.Row():
|
| 24 |
+
image = gr.Image(shape = (224,224))
|
| 25 |
+
lb_image = gr.Label(num_top_classes = 3)
|
| 26 |
+
b3 = gr.Button("Clasifica un perro o un gato")
|
| 27 |
|
| 28 |
|
| 29 |
b1.click(audio_a_text, inputs = audio, outputs = transcription)
|
| 30 |
b2.click(texto_a_sentimiento, inputs = texto, outputs = label)
|
| 31 |
+
b3.click(clasifica_imagen, inputs = image, outputs = lb_image)
|
| 32 |
+
|
| 33 |
+
|
| 34 |
|
| 35 |
demo.launch()
|