Spaces:
Runtime error
Runtime error
rodragon737
commited on
Commit
β’
ae753fc
1
Parent(s):
d2eab53
Add application file
Browse files
README.md
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
---
|
2 |
-
title:
|
3 |
emoji: π
|
4 |
colorFrom: pink
|
5 |
colorTo: red
|
@@ -9,5 +9,12 @@ app_file: app.py
|
|
9 |
pinned: false
|
10 |
license: mit
|
11 |
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
12 |
|
13 |
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
|
|
1 |
---
|
2 |
+
title: Sen
|
3 |
emoji: π
|
4 |
colorFrom: pink
|
5 |
colorTo: red
|
|
|
9 |
pinned: false
|
10 |
license: mit
|
11 |
---
|
12 |
+
%%capture
|
13 |
+
##para no ver consola de instalacion#
|
14 |
+
!pip install gradio
|
15 |
+
!pip install transformers
|
16 |
+
!pip install torch
|
17 |
+
!pip install xformers
|
18 |
+
!pip install ffmpeg
|
19 |
|
20 |
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
app.py
CHANGED
@@ -14,21 +14,14 @@ def texto_a_sentimiento(text):
|
|
14 |
demo = gr.Blocks()
|
15 |
|
16 |
with demo:
|
17 |
-
gr.Markdown("
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
escrito = gr.Textbox()
|
23 |
-
b1 = gr.Button("Escribe lo hablado")
|
24 |
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
-
label=gr.Label()
|
29 |
-
b2=gr.Button("ΒΏComo se Sintio?")
|
30 |
|
31 |
-
|
32 |
-
b2.click(texto_a_sentimiento, inputs=texto, outputs=label)
|
33 |
-
|
34 |
-
demo.launch()
|
|
|
14 |
demo = gr.Blocks()
|
15 |
|
16 |
with demo:
|
17 |
+
gr.Markdown("demo de sentimientos leidos")
|
18 |
+
audio = gr.Audio(source="microphone", type="filepath")
|
19 |
+
texto = gr.Textbox()
|
20 |
+
b1 = gr.Button("transcribir")
|
21 |
+
b1.click(audio_a_text, inputs=audio, outputs=texto)
|
|
|
|
|
22 |
|
23 |
+
label = gr.Label()
|
24 |
+
b2 = gr.Button("ΒΏGusto?")
|
25 |
+
b2.click(texto_a_sentimiento, inputs=texto, outputs=label)
|
|
|
|
|
26 |
|
27 |
+
demo.launch(share=True)
|
|
|
|
|
|