#2912 ValueError: unsupported device mps

23.185* Posted at: 20 hours ago 👁9

Traceback (most recent call last):
File "/Users/cullbu/pyvideotrans/videotrans/process/stt_fun.py", line 177, in faster_whisper

model = WhisperModel(

File "/Users/cullbu/pyvideotrans/.venv/lib/python3.10/site-packages/faster_whisper/transcribe.py", line 689, in init

self.model = ctranslate2.models.Whisper(

ValueError: unsupported device mps


=
system:macOS-15.1-arm64-arm-64bit
version:v3.95
frozen:False
language:zh
root_dir:/Users/cullbu/pyvideotrans
Python: 3.10.19 (main, Jan 14 2026, 23:38:29) [Clang 21.1.4 ]

1 Replies

这是由于在 macOS 上使用了不支持 MPS 设备的 faster-whisper 版本导致的。

  1. 问题原因faster-whisper 库的当前版本不支持苹果的 MPS (Metal Performance Shaders) 后端,因此无法在 Apple Silicon (M1/M2/M3) 芯片上使用 GPU 加速。错误信息 unsupported device mps 明确指出了这一点。
  2. 解决方案

    • 方法一(推荐):在软件设置中,将“语音识别渠道”从 faster-whisper 切换到 openai-whisperopenai-whisper 支持 MPS 加速,可以在你的 Mac 上正常运行。
    • 方法二:如果你必须使用 faster-whisper,则需要在代码中强制指定使用 CPU 进行计算。这需要修改源码,对于大多数用户不推荐。
    • 方法三:考虑使用在线语音识别 API(如 OpenAI Whisper API、阿里百炼 Qwen3-ASR 等),这可以绕过本地设备限制。

参考文档:

Post Your Reply
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.

Related resource