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

bug: Custom model not loading. #170

Open
NeuralAIM opened this issue Oct 12, 2023 · 1 comment
Open

bug: Custom model not loading. #170

NeuralAIM opened this issue Oct 12, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@NeuralAIM
Copy link

Describe the bug

Code:
!ls /content
Out: ggml-model.bin sample_data whisper whisper.CPP

Code:

from whispercpp import Whisper
w = Whisper.from_pretrained("/content/ggml-model.bin")

Out:

[<ipython-input-16-daf3870535af>](https://localhost:8080/#) in <cell line: 4>()
from whispercpp import Whisper
w = Whisper.from_pretrained("/content/ggml-model.bin")

/usr/local/lib/python3.10/dist-packages/whispercpp/__init__.py in from_pretrained(model_name, basedir, no_state)

RuntimeError: '/content/ggml-model.bin' is not a valid preconverted model. Choose one of ['tiny.en', 'tiny', 'base.en', 'base', 'small.en', 'small', 'medium.en', 'medium', 'large-v1', 'large']

To reproduce

I downloaded the model and converted it using a script:

!python whisper.cpp/models/convert-h5-to-ggml.py /content/whisper-small whisper ./

Expected behavior

No response

Environment

python 3.10.6
Google Colab

@NeuralAIM NeuralAIM added the bug Something isn't working label Oct 12, 2023
@kornpow
Copy link

kornpow commented Nov 21, 2023

I have a similar problem:
In the main whisper.cpp repo I did:

bash ./models/download-ggml-model.sh tiny.en

which downloads the model as ./models/ggml-tiny.en.bin

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants