Loading pipeline("summarization") failed
See original GitHub issueHi guys, when I try to load pipeline(“summarization”) I get the following error:
Traceback (most recent call last): File "<frozen importlib._bootstrap>", line 983, in _find_and_load File "<frozen importlib._bootstrap>", line 967, in _find_and_load_unlocked File "<frozen importlib._bootstrap>", line 677, in _load_unlocked File "<frozen importlib._bootstrap_external>", line 728, in exec_module File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed File "PATH", line 11, in <module> summarizer = pipeline("summarization") File "PATH\venv\lib\site-packages\transformers\pipelines.py", line 1626, in pipeline return task_class(model=model, tokenizer=tokenizer, modelcard=modelcard, framework=framework, task=task, **kwargs,) File "PATH\venv\lib\site-packages\transformers\pipelines.py", line 367, in __init__ task_specific_params = self.model.config.task_specific_params AttributeError: 'NoneType' object has no attribute 'config'
Setup: Python: 3.7.6 transformers==2.8.0 tensorboard==2.0.2 tensorflow==2.0.0 tensorflow-estimator==2.0.1 tensorflow-hub==0.7.0
from transformers import pipeline
from transformers import TFAutoModelWithLMHead, AutoTokenizer
summarizer = pipeline("summarization")
Issue Analytics
- State:
- Created 3 years ago
- Comments:10 (7 by maintainers)
Top GitHub Comments
The default summarization pipeline doesn’t have support for TF unfortunately, but we should probably add an explicit error message @sshleifer
Do you want to take a stab at a better error message for this @patrickvonplaten?