I am getting in calling tokenizer

#3
by Akshayarohith - opened

code:
from transformers import PegasusTokenizer, PegasusForConditionalGeneration, TFPegasusForConditionalGeneration

model_name = "human-centered-summarization/financial-summarization-pegasus"
tokenizer = PegasusTokenizer.from_pretrained(model_name)
model = PegasusForConditionalGeneration.from_pretrained(model_name)

Error:

TypeError Traceback (most recent call last)
Cell In[20], line 4
1 from transformers import PegasusTokenizer, PegasusForConditionalGeneration, TFPegasusForConditionalGeneration
3 model_name = "human-centered-summarization/financial-summarization-pegasus"
----> 4 tokenizer = PegasusTokenizer.from_pretrained(model_name)
5 model = PegasusForConditionalGeneration.from_pretrained(model_name)

TypeError: 'NoneType' object is not callable

I got this error after install sentencepiece. To solve this, restart your notebook and re-run the code

human-centered-summarization changed discussion status to closed

Sign up or log in to comment