Code Monkey home page Code Monkey logo

Comments (7)

Galunid avatar Galunid commented on July 26, 2024 1

See huggingface/transformers#30334, this is not our script and sadly we can't provide support for it.

from llama.cpp.

christianazinn avatar christianazinn commented on July 26, 2024

You'll want to use convert-hf-to-gguf.py. The Llama3 BPE pretokenizer is supported by default in convert-hf-to-gguf-update.py.

from llama.cpp.

ego avatar ego commented on July 26, 2024

How to convert origin Meta-Llama-3 to gguf?

❯ ls models/Meta-Llama-3-8B
checklist.chk       consolidated.00.pth params.json         tokenizer.model

from llama.cpp.

Galunid avatar Galunid commented on July 26, 2024

Convert the .pth weights yourself using https://github.com/huggingface/transformers/blob/main/src/transformers/models/llama/convert_llama_weights_to_hf.py, or download the weights from huggingface. Then you can use convert-hf-to-gguf.py

from llama.cpp.

ego avatar ego commented on July 26, 2024

Convert the .pth weights yourself using https://github.com/huggingface/transformers/blob/main/src/transformers/models/llama/convert_llama_weights_to_hf.py, or download the weights from huggingface. Then you can use convert-hf-to-gguf.py

I have tried it:

python src/transformers/models/llama/convert_llama_weights_to_hf.py --input_dir ../llama.cpp/models/Meta-Llama-3-8B --output_dir converted

but it produce error:

.venv/lib/python3.10/site-packages/sentencepiece/__init__.py", line 316, in LoadFromFile
    return _sentencepiece.SentencePieceProcessor_LoadFromFile(self, arg)
RuntimeError: Internal: could not parse ModelProto from ../llama.cpp/models/Meta-Llama-3-8B/tokenizer.model

from llama.cpp.

ego avatar ego commented on July 26, 2024

Thanks a lot!

from llama.cpp.

ArthurZucker avatar ArthurZucker commented on July 26, 2024

If you update to the latest version of transformers the scripts supports the conversion

from llama.cpp.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.