DrishtiSharma commited on
Commit
b9eb1b0
1 Parent(s): 40d4f6a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -32,7 +32,7 @@ def predict_and_ctc_lm_decode(input_file):
32
  harassment_detection = pipe3(transcribed_text)
33
  harassment_detection={dic["label"]: dic["score"] for dic in harassment_detection}
34
  #harassment_detection = np.where(harassment_detection['label']== 0, 'No Harassment', 'Harassment')
35
- return sentiment
36
  #sexism_detection, harassment_detection
37
 
38
  gr.Interface(
@@ -42,7 +42,7 @@ gr.Interface(
42
  ],
43
  #outputs=[gr.outputs.Label(num_top_classes=2),gr.outputs.Label(num_top_classes=2), gr.outputs.Label(num_top_classes=2)],
44
  outputs=[gr.outputs.Label(num_top_classes=2)],
45
- examples=[["respiracion_happiness.wav"]],
46
  title="Sentiment Analysis of Spanish Transcribed Audio",
47
  description="This is a Gradio demo for Sentiment Analysis of Transcribed Spanish Audio",
48
  layout="horizontal",
 
32
  harassment_detection = pipe3(transcribed_text)
33
  harassment_detection={dic["label"]: dic["score"] for dic in harassment_detection}
34
  #harassment_detection = np.where(harassment_detection['label']== 0, 'No Harassment', 'Harassment')
35
+ return sexism_detection
36
  #sexism_detection, harassment_detection
37
 
38
  gr.Interface(
 
42
  ],
43
  #outputs=[gr.outputs.Label(num_top_classes=2),gr.outputs.Label(num_top_classes=2), gr.outputs.Label(num_top_classes=2)],
44
  outputs=[gr.outputs.Label(num_top_classes=2)],
45
+ examples=[["audio_test.wav"]],
46
  title="Sentiment Analysis of Spanish Transcribed Audio",
47
  description="This is a Gradio demo for Sentiment Analysis of Transcribed Spanish Audio",
48
  layout="horizontal",