File tree 2 files changed +3
-3
lines changed
2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change 35
35
torch ._inductor .config .fx_graph_cache = True
36
36
37
37
MAX_SEQ_LEN = 4096
38
- MAX_BLOCK_LEN = 4096
38
+ MAX_BLOCK_LEN = 2048
39
39
LEN_MS = 30000
40
40
STRIDE_FACTOR = 3
41
41
CHUNK_LEN_MS = LEN_MS // STRIDE_FACTOR
@@ -294,7 +294,7 @@ def process_segments(
294
294
# to make sure that a sequence of the correct format is returned. Right now
295
295
# it messes things up somehow
296
296
if not all (_idx <= idx for _idx in eos_idxs ):
297
- logger .warning ("Context length overflow when transcribing segment" )
297
+ logger .warning ("Context length overflow when transcribing segment(s) " )
298
298
299
299
results = [
300
300
tokenizer .decode (seq [_idx , : eos_idxs [_idx ] + 1 ])
Original file line number Diff line number Diff line change @@ -467,7 +467,7 @@ def transcribe(
467
467
468
468
files_to_process = []
469
469
for audio_path in file_paths :
470
- if segments_by_audio_file .get (audio_path , None ):
470
+ if segments_by_audio_file .get (audio_path , None ) is not None :
471
471
file_info = {
472
472
"path" : audio_path ,
473
473
"segments" : segments_by_audio_file [audio_path ],
You can’t perform that action at this time.
0 commit comments