Vaibhavs10 / insanely-fast-whisper

Apache License 2.0
7.73k stars 545 forks source link

Issue on macOS Ventura - ProductVersion: 13.6.3 - BuildVersion: 22G436? #165

Open yvervoort opened 10 months ago

yvervoort commented 10 months ago

$ insanely-fast-whisper --model-name distil-whisper/large-v2 --device-id mps --file-name TEST_1_CPY.wav

Traceback (most recent call last):
  File "/Users/me/.local/bin/insanely-fast-whisper", line 10, in <module>
    sys.exit(main())
             ^^^^^^
  File "/Users/me/Library/Application Support/pipx/venvs/insanely-fast-whisper/lib/python3.11/site-packages/insanely_fast_whisper/cli.py", line 94, in main
    pipe = pipeline(
           ^^^^^^^^^
  File "/Users/me/Library/Application Support/pipx/venvs/insanely-fast-whisper/lib/python3.11/site-packages/transformers/pipelines/__init__.py", line 1070, in pipeline
    return pipeline_class(model=model, framework=framework, task=task, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/me/Library/Application Support/pipx/venvs/insanely-fast-whisper/lib/python3.11/site-packages/transformers/pipelines/automatic_speech_recognition.py", line 239, in __init__
    self.model.to(device)
  File "/Users/me/Library/Application Support/pipx/venvs/insanely-fast-whisper/lib/python3.11/site-packages/transformers/modeling_utils.py", line 2460, in to
    return super().to(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/me/Library/Application Support/pipx/venvs/insanely-fast-whisper/lib/python3.11/site-packages/torch/nn/modules/module.py", line 1160, in to
    return self._apply(convert)
           ^^^^^^^^^^^^^^^^^^^^
  File "/Users/me/Library/Application Support/pipx/venvs/insanely-fast-whisper/lib/python3.11/site-packages/torch/nn/modules/module.py", line 810, in _apply
    module._apply(fn)
  File "/Users/me/Library/Application Support/pipx/venvs/insanely-fast-whisper/lib/python3.11/site-packages/torch/nn/modules/module.py", line 810, in _apply
    module._apply(fn)
  File "/Users/me/Library/Application Support/pipx/venvs/insanely-fast-whisper/lib/python3.11/site-packages/torch/nn/modules/module.py", line 810, in _apply
    module._apply(fn)
  File "/Users/me/Library/Application Support/pipx/venvs/insanely-fast-whisper/lib/python3.11/site-packages/torch/nn/modules/module.py", line 833, in _apply
    param_applied = fn(param)
                    ^^^^^^^^^
  File "/Users/me/Library/Application Support/pipx/venvs/insanely-fast-whisper/lib/python3.11/site-packages/torch/nn/modules/module.py", line 1158, in convert
    return t.to(device, dtype if t.is_floating_point() or t.is_complex() else None, non_blocking)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
RuntimeError: The MPS backend is supported on MacOS 12.3+.Current OS version can be queried using `sw_vers`
cherrries commented 10 months ago

Which version of MacOS are you using?

yvervoort commented 10 months ago

Which version of MacOS are you using?

Hi @cherrries - ProductVersion 13.6.3 is macOS Ventura. Any thoughts?