-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Model with llama.cpp works, but not with llama-cpp-python #336
Comments
@icarus0508, I converted your Discussion into an issue. This seems to be the same issue: There are three ggml versions. You will want to use Are you sure you're using the latest version, as it your limited description suggests you're trying to load a The following code will tell you the version of model you are using. The same info is reported by
To ensure you running the latest version of
|
Thanks for reply I upgraded version to : llama-cpp-python ver:0.1.59 llama.cpp ver:master-ffb06a3 after upgrade llama-cpp-python to v0.159 My alpaca (ggml-alpaca-7b-q4.bin) works fine but still llama(ggml-model-q4_0.bin) model can't be loaded(). it will occur a exception : Exception has occurred: ValidationError It will be fine for me to just use alpaca model, but I just wonder how to fix to use llama model ? All models are converted using (llama.cpp ver:master-ffb06a3) Thank you. |
The model is likely the wrong version. In any case this is not a |
it lama cpp python supporte flux1-dev-Q8_0.gguf |
Discussed in #334
Originally posted by icarus0508 June 7, 2023
Hi, i just build my llama.cpp model . it works fine on llama.cpp, but when i move the model to llama-cpp-python by following the code like:
nllm = LlamaCpp(
model_path="./ggml-model-q4_0.bin",
callback_manager=callback_manager,
verbose=True,
n_ctx=2048
)
it is always encount an error like this:
llama.cpp: loading model from ./ggml-model-q4_0.bin
error loading model: unrecognized tensor type 14
llama_init_from_file: failed to load model
2023-06-07 15:15:52.963 Uncaught app exception
Traceback (most recent call last):
File "C:\Users\IamUser\AppData\Local\Programs\Python\Python310\lib\site-packages\streamlit\runtime\scriptrunner\script_runner.py", line 565, in _run_script
exec(code, module.dict)
File "D:\PythonPlayground\NN-Playgroud\chatbot_NPC_llama.py", line 39, in
nllm = LlamaCpp(
File "pydantic\main.py", line 341, in pydantic.main.BaseModel.init
pydantic.error_wrappers.ValidationError: 1 validation error for LlamaCpp
root
Could not load Llama model from path: ./ggml-model-q4_0.bin. Received error (type=value_error)
llama.cpp version : master-ffb06a3
llama-cpp-python: v0.157
it will work if i use older version of model and use v0.149 of llama-cpp-python
but i will like to use the lastest version. How can i solve this?
Thank you
The text was updated successfully, but these errors were encountered: