onnx_transformers
onnx_transformers copied to clipboard
ModuleNotFoundError: No module named 'transformers.configuration_auto'
Hi
I am getting an error when running the example
from onnx_transformers import pipeline
# Initialize a pipeline by passing the task name and
# set onnx to True (default value is also True)
nlp = pipeline("sentiment-analysis", onnx=True)
nlp("Transformers and onnx runtime is an awesome combo!")
---------------------------------------------------------------------------
ModuleNotFoundError Traceback (most recent call last)
<ipython-input-6-b6b36e52d5ec> in <module>
----> 1 from onnx_transformers import pipeline
2
3 # Initialize a pipeline by passing the task name and
4 # set onnx to True (default value is also True)
5 nlp = pipeline("sentiment-analysis", onnx=True)
/opt/anaconda3/lib/python3.8/site-packages/onnx_transformers/__init__.py in <module>
2
3 # Pipelines
----> 4 from .pipelines import (
5 CsvPipelineDataFormat,
6 JsonPipelineDataFormat,
/opt/anaconda3/lib/python3.8/site-packages/onnx_transformers/pipelines.py in <module>
16 from onnxruntime import GraphOptimizationLevel, InferenceSession, SessionOptions, get_all_providers
17 from psutil import cpu_count
---> 18 from transformers.configuration_auto import AutoConfig
19 from transformers.configuration_utils import PretrainedConfig
20 from transformers.convert_graph_to_onnx import convert_pytorch, convert_tensorflow, infer_shapes
ModuleNotFoundError: No module named 'transformers.configuration_auto'
Kindly help
Hello @subhamkhemka.
I guess you use a recent version of transformers (4.11.3 is the actual version)? Unfortunately, I think onnx_transformers is no longer up to date (see this post of @patil-suraj).
Is there any plans to fix this? Or do we consider this project to have died?