Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversion from Whisper to OpenVino failed #1870

Open
ClaraSev1 opened this issue Feb 16, 2024 · 0 comments
Open

Conversion from Whisper to OpenVino failed #1870

ClaraSev1 opened this issue Feb 16, 2024 · 0 comments

Comments

@ClaraSev1
Copy link

Hi there,

I have followed all instructions on the README document to use OpenVino. However, when I try to run python3 convert-whisper-to-openvino.py --model base.en, it gives me the following error:

/home/clara/whisper.cpp/models/openvino_conv_env/lib/python3.10/site-packages/whisper/model.py:166: TracerWarning: Converting a tensor to a Python boolean might cause the trace to be incorrect. We can't record the data flow of Python values, so this value will be treated as a constant in the future. This means that the trace might not generalize to other inputs!
  assert x.shape[1:] == self.positional_embedding.shape, "incorrect audio shape"
Traceback (most recent call last):
  File "/home/clara/whisper.cpp/models/convert-whisper-to-openvino.py", line 55, in <module>
    convert_encoder(hparams, encoder, args.model)
  File "/home/clara/whisper.cpp/models/convert-whisper-to-openvino.py", line 32, in convert_encoder
    encoder_model = mo.convert_model(onnx_path, compress_to_fp16=True)
  File "/home/clara/whisper.cpp/models/openvino_conv_env/lib/python3.10/site-packages/openvino/tools/mo/convert.py", line 364, in convert_model
    ov_model, _ = _convert(cli_parser, framework, params, True)
  File "/home/clara/whisper.cpp/models/openvino_conv_env/lib/python3.10/site-packages/openvino/tools/mo/convert_impl.py", line 957, in _convert
    raise e.with_traceback(None)
TypeError: load(): incompatible function arguments. The following argument types are supported:
    1. (self: openvino._pyopenvino.FrontEnd, path: object) -> ov::frontend::InputModel

Invoked with: <FrontEnd 'onnx'>, '/home/clara/whisper.cpp/models/onnx_encoder/whisper_encoder.onnx', False

Does anyone have any experience with this type of error? I don't know how to proceed. Any help will be appreciated.
Thank you.

st-gr pushed a commit to st-gr/whisper.cpp that referenced this issue Feb 22, 2024
…v#1870)

Fix issue: Conversion from Whisper to OpenVino failed ggerganov#1870

convert-whisper-to-openvino.py stopped working with OpenVINO version 2023.0.0-10926-b4452d56304-releases/2023/0 .

Error was: TypeError: load(): incompatible function arguments. The following argument types are supported:
    1. (self: openvino._pyopenvino.FrontEnd, path: object) -> ov::frontend::InputModel

Tested successfully with a large-v3 conversion.
ggerganov pushed a commit that referenced this issue Feb 22, 2024
Fix issue: Conversion from Whisper to OpenVino failed #1870

convert-whisper-to-openvino.py stopped working with OpenVINO version 2023.0.0-10926-b4452d56304-releases/2023/0 .

Error was: TypeError: load(): incompatible function arguments. The following argument types are supported:
    1. (self: openvino._pyopenvino.FrontEnd, path: object) -> ov::frontend::InputModel

Tested successfully with a large-v3 conversion.

Co-authored-by: Stefan Grundmann <grundmanns@sandiego.gov>
jiahansu pushed a commit to WiseSync/whisper.cpp that referenced this issue Apr 17, 2024
Fix issue: Conversion from Whisper to OpenVino failed ggerganov#1870

convert-whisper-to-openvino.py stopped working with OpenVINO version 2023.0.0-10926-b4452d56304-releases/2023/0 .

Error was: TypeError: load(): incompatible function arguments. The following argument types are supported:
    1. (self: openvino._pyopenvino.FrontEnd, path: object) -> ov::frontend::InputModel

Tested successfully with a large-v3 conversion.

Co-authored-by: Stefan Grundmann <grundmanns@sandiego.gov>
viktor-silakov pushed a commit to viktor-silakov/whisper_node_mic.cpp that referenced this issue May 11, 2024
Fix issue: Conversion from Whisper to OpenVino failed ggerganov#1870

convert-whisper-to-openvino.py stopped working with OpenVINO version 2023.0.0-10926-b4452d56304-releases/2023/0 .

Error was: TypeError: load(): incompatible function arguments. The following argument types are supported:
    1. (self: openvino._pyopenvino.FrontEnd, path: object) -> ov::frontend::InputModel

Tested successfully with a large-v3 conversion.

Co-authored-by: Stefan Grundmann <grundmanns@sandiego.gov>
iThalay pushed a commit to iThalay/whisper.cpp that referenced this issue Sep 23, 2024
Fix issue: Conversion from Whisper to OpenVino failed ggerganov#1870

convert-whisper-to-openvino.py stopped working with OpenVINO version 2023.0.0-10926-b4452d56304-releases/2023/0 .

Error was: TypeError: load(): incompatible function arguments. The following argument types are supported:
    1. (self: openvino._pyopenvino.FrontEnd, path: object) -> ov::frontend::InputModel

Tested successfully with a large-v3 conversion.

Co-authored-by: Stefan Grundmann <grundmanns@sandiego.gov>
iThalay pushed a commit to iThalay/whisper.cpp that referenced this issue Sep 23, 2024
Fix issue: Conversion from Whisper to OpenVino failed ggerganov#1870

convert-whisper-to-openvino.py stopped working with OpenVINO version 2023.0.0-10926-b4452d56304-releases/2023/0 .

Error was: TypeError: load(): incompatible function arguments. The following argument types are supported:
    1. (self: openvino._pyopenvino.FrontEnd, path: object) -> ov::frontend::InputModel

Tested successfully with a large-v3 conversion.

Co-authored-by: Stefan Grundmann <grundmanns@sandiego.gov>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant