Update modules/whisper/whisper_base.py
Browse files
modules/whisper/whisper_base.py
CHANGED
|
@@ -279,6 +279,17 @@ class WhisperBase(ABC):
|
|
| 279 |
output_dir=self.output_dir
|
| 280 |
)
|
| 281 |
files_to_download[file_name+"_srt"] = {"path": file_path}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 282 |
|
| 283 |
total_result = ''
|
| 284 |
total_info = ''
|
|
|
|
| 279 |
output_dir=self.output_dir
|
| 280 |
)
|
| 281 |
files_to_download[file_name+"_srt"] = {"path": file_path}
|
| 282 |
+
|
| 283 |
+
## Add output file as csv
|
| 284 |
+
file_name, file_ext = os.path.splitext(os.path.basename(file))
|
| 285 |
+
subtitle, file_path = self.generate_and_write_file(
|
| 286 |
+
file_name=file_name,
|
| 287 |
+
transcribed_segments=transcribed_segments,
|
| 288 |
+
add_timestamp=add_timestamp,
|
| 289 |
+
file_format="csv",
|
| 290 |
+
output_dir=self.output_dir
|
| 291 |
+
)
|
| 292 |
+
files_to_download[file_name+"_csv"] = {"path": file_path}
|
| 293 |
|
| 294 |
total_result = ''
|
| 295 |
total_info = ''
|