code for downloading

#2
by idormoy - opened

Hi,
could you please provide code for downloading?
I am trying

from transformers import AutoTokenizer
import transformers
import torch

model = "NousResearch/Llama-2-13b-hf"
tokenizer = AutoTokenizer.from_pretrained(model)
pipeline = transformers.pipeline(
"text-generation",
model=model,
torch_dtype=torch.float16,
device_map="auto",
)

but I am getting this error: ValueError: Tokenizer class LlamaTokenizer does not exist or is not currently imported.

Thanks!

using the last version of HF fixed it

%pip install git+https://github.com/huggingface/transformers

idormoy changed discussion status to closed

Sign up or log in to comment