Mihaj commited on
Commit
a694d9e
·
verified ·
1 Parent(s): 7226dcf

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -4
app.py CHANGED
@@ -146,15 +146,17 @@ def transcribe(audio):
146
  chars, char_start_times, char_end_times = count_char_borders(predicted_ids, input_values, processor)
147
 
148
  clusters_and_duration, sum_dur_vowels, total_duration, pauses = preprocess(chars, char_start_times)
149
-
 
 
150
  # параметры для ΔC
151
  for x in clusters_and_duration:
152
  if x[0] == 'C':
153
  cons_clusters.append(x[1])
154
-
155
  # параметры для %V
156
- vowels_duration += sum_dur_vowels
157
- duration_without_pauses += total_duration - pauses
158
 
159
  # расчёт метрик
160
  dC = delta_C(cons_clusters)
 
146
  chars, char_start_times, char_end_times = count_char_borders(predicted_ids, input_values, processor)
147
 
148
  clusters_and_duration, sum_dur_vowels, total_duration, pauses = preprocess(chars, char_start_times)
149
+
150
+ cons_clusters = []
151
+
152
  # параметры для ΔC
153
  for x in clusters_and_duration:
154
  if x[0] == 'C':
155
  cons_clusters.append(x[1])
156
+
157
  # параметры для %V
158
+ vowels_duration = sum_dur_vowels
159
+ duration_without_pauses = total_duration - pauses
160
 
161
  # расчёт метрик
162
  dC = delta_C(cons_clusters)