#9039 Error during speech recognition stage[faster-whisper(Built-in)] :Traceback (most recent call last): File

1.53**3 Posted at: 8 hours ago

Error during speech recognition stage[faster-whisper(Built-in)] :Traceback (most recent call last):
File "videotrans\process\stt_faster.py", line 115, in faster_whisper
File "faster_whisper\transcribe.py", line 916, in transcribe
File "faster_whisper\feature_extractor.py", line 215, in call
File "faster_whisper\feature_extractor.py", line 189, in stft
File "numpy\fft\_pocketfft.py", line 409, in rfft
File "numpy\fft\_pocketfft.py", line 70, in _raw_fft
MemoryError

Traceback (most recent call last):

File "videotrans\task\job.py", line 35, in run

File "videotrans\task\job.py", line 98, in process_task

File "videotrans\task\speech2text.py", line 147, in recogn

File "videotrans\recognition\__init__.py", line 167, in run

File "videotrans\recognition\_base.py", line 98, in run

File "videotrans\recognition\_whisper.py", line 41, in _exec

File "videotrans\recognition\_whisper.py", line 137, in _faster

File "videotrans\configure\base.py", line 285, in _new_process

videotrans.configure.excepts.VideoTransError: :Traceback (most recent call last):
File "videotrans\process\stt_faster.py", line 115, in faster_whisper
File "faster_whisper\transcribe.py", line 916, in transcribe
File "faster_whisper\feature_extractor.py", line 215, in call
File "faster_whisper\feature_extractor.py", line 189, in stft
File "numpy\fft\_pocketfft.py", line 409, in rfft
File "numpy\fft\_pocketfft.py", line 70, in _raw_fft
MemoryError
trk=Speech-To-Text
self.cfg.name='E:/BaiduNetdiskDownload/STVK/2017-2018飛宮三才學(未流通)/20180630-台灣飛宮三才學第十一講/20180630-台灣飛宮三才學第十一講縮錄1.mp4',
self.cfg.target_dir='D:/win-pyvideotrans-v4.20/output',
self.cfg.cache_folder='D:/win-pyvideotrans-v4.20/tmp/7980/b12c78a4a3'
self.cfg.is_cuda=True
STT Service:faster-whisper(Built-in), large-v3-turbo, Spoken: zh
Max Speech Duration (s): 5s
Min Speech Duration (ms): 3000ms
Min Silence Duration for Split (ms): 600ms
VAD Speech Threshold: 0.45
VAD Engine: silero
Compute Type:default
Beam Size:5
Best Of:5
Condition on Previous Text:False
Repetition Penalty:1.0
Compression Ratio Threshold:2.4
Output Format: srt
Max Line Length (CJK Characters):15, Max Line Length (Non-CJK):40
self.cfg=TaskCfgSTT(uuid='b12c78a4a3', name='E:/BaiduNetdiskDownload/STVK/2017-2018飛宮三才學(未流通)/20180630-台灣飛宮三才學第十一講/20180630-台灣飛宮三才學第十一講縮錄1.mp4', dirname='E:/BaiduNetdiskDownload/STVK/2017-2018飛宮三才學(未流通)/20180630-台灣飛宮三才學第十一講', noextname='20180630-台灣飛宮三才學第十一講縮錄1', basename='20180630-台灣飛宮三才學第十一講縮錄1.mp4', ext='mp4', target_dir='D:/win-pyvideotrans-v4.20/output', cache_folder='D:/win-pyvideotrans-v4.20/tmp/7980/b12c78a4a3', is_cuda=True, source_language='', source_language_code='', source_sub=None, source_wav=None, source_wav_output=None, target_language='', target_language_code='', target_sub='D:/win-pyvideotrans-v4.20/output/20180630-台灣飛宮三才學第十一講縮錄1.srt', target_wav=None, target_wav_output=None, detect_language='zh', recogn_type=0, model_name='large-v3-turbo', shibie_audio='D:/win-pyvideotrans-v4.20/tmp/7980/b12c78a4a3/20180630-台灣飛宮三才學第十一講縮錄1-1796115405.5701783.wav', remove_noise=False, enable_diariz=False, nums_diariz=0, rephrase=False, fix_punc=0)


=
system:Windows-10-10.0.19045-SP0
version:v4.20
frozen:True
language:en_US
root_dir:D:/win-pyvideotrans-v4.20

1 Replies

#1 DeepSeek reply at 8 hours ago

This is a system memory (RAM) exhaustion error: not a VRAM issue. faster-whisper loads the entire audio into memory and performs an STFT (numpy rfft), and MemoryError occurs when the array overflows RAM. A long video plus large-v3-turbo plus Compute Type: default plus Beam Size: 5 / Best Of: 5 uses a very large amount of memory.

Solutions (try in order):

  1. Reduce memory usage

    • Menu → Tools/Options → Advanced Options → Speech Recognition (ASR):

      • Compute Type changed from default to int8 (least memory) or float16
      • Beam Size and Best Of both changed from 5 to 1
      • Condition on Previous Text keep as False (already fine)
  2. Downgrade the model: change large-v3-turbo to medium or small, then try again. If it works, that confirms the cause is insufficient memory.
  3. Expand virtual memory: Windows → System Properties → Advanced → Performance Settings → Advanced → Virtual Memory, set the page file to a fixed value of at least 16GB (or system-managed on a drive with plenty of free space), then restart the software.
  4. Close other programs that use memory, and confirm no other sp.exe instance is running.
  5. Split the long video: for a video of several hours, use Menu → Tools → Trim Video by Subtitles or cut it into 30–60 minute segments and process them separately.

Also, fix the file path (required):
The current path E:/BaiduNetdiskDownload/STVK/2017-2018飛宮三才學(未流通)/... contains Chinese characters, full-width parentheses (), and the full-width : is not applicable, but the full-width brackets are; this can cause other FFmpeg and read/write errors. Move the video to a shallow path containing only English letters and digits (e.g. D:/videos/video1.mp4).

Note: self.cfg.is_cuda=True was selected. If your GPU VRAM is below 8GB, also change the model to medium; otherwise CUDA errors may follow.

If the same MemoryError still occurs after the above settings, please provide the last 30 lines of the latest .log file in the software installation directory's logs/ folder, along with the video duration, computer RAM size, and GPU model and VRAM.

Please refer to the related documentation:

Thinking...
Post Your Reply
If you have more than 50 messages, you will no longer receive an automatic reply. Please ask a new question!
Open source and free maintenance is not easy. If this project is helpful to you, please consider making a small donation to help the project continue to maintain and update.

Dondate via ko-fi.com

Related resource