Spaces:
Runtime error
Runtime error
progress bar
Browse files
app.py
CHANGED
@@ -103,11 +103,12 @@ if __name__ == "__main__":
|
|
103 |
|
104 |
uploaded_files_count = len(uploaded_files)
|
105 |
suppress_output_threshold = 2
|
106 |
-
|
|
|
107 |
|
108 |
if uploaded_file is not None:
|
109 |
wav_file = get_path_to_wav_format(uploaded_file, uploaded_files_count>suppress_output_threshold)
|
110 |
result = model.recognize(wav_file, langcode)
|
111 |
results[uploaded_file.name] = result
|
112 |
-
|
113 |
st.write(results)
|
|
|
103 |
|
104 |
uploaded_files_count = len(uploaded_files)
|
105 |
suppress_output_threshold = 2
|
106 |
+
my_bar = st.progress(0)
|
107 |
+
for i, uploaded_file in enumerate(uploaded_files):
|
108 |
|
109 |
if uploaded_file is not None:
|
110 |
wav_file = get_path_to_wav_format(uploaded_file, uploaded_files_count>suppress_output_threshold)
|
111 |
result = model.recognize(wav_file, langcode)
|
112 |
results[uploaded_file.name] = result
|
113 |
+
st.progress(i/uploaded_files_count)
|
114 |
st.write(results)
|