DrishtiSharma commited on
Commit
e62fbf9
·
1 Parent(s): 9f5f6fd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -20,7 +20,7 @@ asr = pipeline("automatic-speech-recognition", model="jonatasgrosman/wav2vec2-la
20
 
21
  def predict_and_ctc_lm_decode(input_file):
22
  speech = load_and_fix_data(input_file, sampling_rate)
23
- transcribed_text = asr(speech, chunk_length_s=5, stride_length_s=1)["text"]
24
  pipe3 = pipeline("text-classification", model = "hackathon-pln-es/Detect-Acoso-Twitter-Es")
25
  harassment_detection = pipe3(transcribed_text)[0]['label']
26
 
 
20
 
21
  def predict_and_ctc_lm_decode(input_file):
22
  speech = load_and_fix_data(input_file, sampling_rate)
23
+ transcribed_text = asr(speech, chunk_length_s=10, stride_length_s=1)["text"]
24
  pipe3 = pipeline("text-classification", model = "hackathon-pln-es/Detect-Acoso-Twitter-Es")
25
  harassment_detection = pipe3(transcribed_text)[0]['label']
26