cannot import name 'Pix2StructForConditionalGeneration' and AttributeError in 'AutoProcessor'
#2
by
pathikg
- opened
I avoided Pix2struct error with using transformers 4.28.0.dev0 version. I don't know this is the right way but, while using the pip-installed version, couldn't handle this error. Abut second error AutoProcessor has dependency on torchvision. You can try to install it if you haven't install.
Pix2Struct was introduced on the transformers : v4.28.0, you can check it here : https://github.com/huggingface/transformers/releases
To ensure you have the latest version, run : !pip install --upgrade transformers
Once the installation is complete, you should be able to use Pix2Struct in your code.