Getting stuck at Setting `pad_token_id` to `eos_token_id`:11 for open-end generation.
#14
by
ivyas
- opened
I'm having issue with falcon-7b model. I am running sample code from
from transformers import AutoTokenizer, AutoModelForCausalLM
import transformers
import torch
model = "tiiuae/falcon-7b"
tokenizer = AutoTokenizer.from_pretrained(model)
pipeline = transformers.pipeline(
"text-generation",
model=model,
tokenizer=tokenizer,
torch_dtype=torch.bfloat16,
trust_remote_code=True,
device_map="auto",
)
sequences = pipeline(
"Girafatron is obsessed with giraffes, the most glorious animal on the face of this Earth. Giraftron believes all other animals are irrelevant when compared to the glorious majesty of the giraffe.\nDaniel: Hello, Girafatron!\nGirafatron:",
max_length=200,
do_sample=True,
top_k=10,
num_return_sequences=1,
eos_token_id=tokenizer.eos_token_id,
)
for seq in sequences:
print(f"Result: {seq['generated_text']}")
I am getting stuck at Setting pad_token_id
to eos_token_id
:11 for open-end generation.
I am running on my macbook pro with intel chip.
+1
same issue.
Same happening with as well
+1
I've same issue when I try 4096 max_length but I got the output in 200 max_length