Several issues when attempting to infer model

#1
by SasaniP - opened

As provided in the Colab notebook, I attempted to load the model. With transformers==4.53.2

# Load model directly
from transformers import EfficientViTForSemanticSegmentation

Running this gets me an import error,
ImportError: cannot import name 'EfficientViTForSemanticSegmentation' from 'transformers' (/usr/local/lib/python3.11/dist-packages/transformers/__init__.py)

I researched installing efficientvit (https://github.com/mit-han-lab/efficientvit/tree/master), but I have no idea how to use the library with OCR.
Tries importing the model with 'AutoModelForSemanticSegmentation' as well, however, that also fails because the model uses efficientvit architecture.

ValueError: The checkpoint you are trying to load has model type `efficientvit` but Transformers does not recognize this architecture. This could be because of an issue with the checkpoint, or because your version of Transformers is out of date.

If someone could help me use this model for inference, that would be great. Thanks!

Sign up or log in to comment