#8472 mkl_malloc: failed to allocate memory:Traceback (most recent call last): File

171.249**3 Posted at: 1 hour ago

mkl_malloc: failed to allocate memory:Traceback (most recent call last):
File "videotrans\process\stt_faster.py", line 139, in faster_whisper
File "faster_whisper\transcribe.py", line 1851, in restore_speech_timestamps
File "faster_whisper\transcribe.py", line 1213, in generate_segments
File "faster_whisper\transcribe.py", line 1446, in generate_with_fallback
RuntimeError: mkl_malloc: failed to allocate memory

Traceback (most recent call last):
File "videotrans\task\only_one.py", line 71, in run
File "videotrans\task\_stage_recogn.py", line 64, in recogn
File "videotrans\recognition\__init__.py", line 141, in run
File "videotrans\recognition\_base.py", line 101, in run
File "videotrans\recognition\_whisper.py", line 39, in _exec
File "videotrans\recognition\_whisper.py", line 136, in _faster
File "videotrans\configure\base.py", line 277, in _new_process
videotrans.configure.excepts.VideoTransError: mkl_malloc: failed to allocate memory:Traceback (most recent call last):
File "videotrans\process\stt_faster.py", line 139, in faster_whisper
File "faster_whisper\transcribe.py", line 1851, in restore_speech_timestamps
File "faster_whisper\transcribe.py", line 1213, in generate_segments
File "faster_whisper\transcribe.py", line 1446, in generate_with_fallback
RuntimeError: mkl_malloc: failed to allocate memory

trk=[TransCreate]: uuid='eea4c735d9', proxy_str=None, cfg=[TaskCfgVTT]当前工作模式: 翻译视频 单视频模式
原始输入文件名: C:/Users/PC/Downloads/mda-sjb7ksnwc2n7uw8p.mp4,
输出结果保存到文件夹: C:/Users/PC/Downloads/_video_out/mda-sjb7ksnwc2n7uw8p-mp4,
临时文件夹: E:/win-pyvideotrans-v4.17/tmp/7824/eea4c735d9
已选 清理已存在
未启用CUDA加速
STT Service:faster-whisper(Built-in), large-v3, 发音语言: Simplified Chinese, , 数据类型:default
发音语言和目标语言相同,不翻译字幕
未选 配音角色,不进行配音
字幕: Hard Subtitles
已选 仅输出mp4, precent=4, hasend=False, should_recogn=True, should_trans=False, should_dubbing=False, should_hebing=True, is_copy_video=True, video_codec_num=264, ignore_align=False, is_audio_trans=False, clone_ref='', should_recogn2=False, do_diarize=True
video_duration_ms=709040


=
system:Windows-10-10.0.26300-SP0
version:v4.17
frozen:True
language:en_US
root_dir:E:/win-pyvideotrans-v4.17

1 Replies

#1 DeepSeek reply at 1 hour ago

This is caused by insufficient memory: the task ran faster-whisper large-v3 in CPU mode with CUDA acceleration not enabled. This model needs roughly 8GB+ of available RAM (plus more for a 12-minute video), and MKL failed to allocate a contiguous block, so the process crashed hard.

Handling steps (in order of priority):

  1. Enable GPU acceleration (most effective): install NVIDIA driver, CUDA 12.8, cuDNN 9.11, then check CUDA Acceleration on the main interface and run again.
  2. Downgrade the model: switch Model from large-v3 to large-v3-turbo (~6GB) or medium/small.
  3. Reduce memory usage: Menu → Tools/Options → Advanced Options → Speech Recognition (ASR):

    • Compute Type → int8 (lowest memory usage)
    • Beam Size → 1
    • Best Of → 1
    • Condition on Previous Text → off
  4. Free up memory: close browsers and other memory-heavy programs before running; check that the system page file is not disabled or too small.
  5. If it still fails, use Qwen-ASR 0.6B / FunASR (both better for Chinese and lighter), or use Alibaba FunASR(Built-in) with the paraformer-zh model.

Note: this video is about 709 seconds long. In CPU mode, large-v3 also needs to hold the whole transcription context in memory; the above combination of settings is usually required to complete it.

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