ImportError: cannot import name 'Qwen2VLForConditionalGeneration' from 'transformers'

#5
by ananda296ai - opened

What is the requirements of the environment to run this model? I have transformers latest 4.44.2 but get the error on from transformers import Qwen2VLForConditionalGeneration, AutoTokenizer, AutoProcessor as

ImportError: cannot import name 'Qwen2VLForConditionalGeneration' from 'transformers

There is no other stacktrace. Please help.

Per the README. you still need the development version or you will get this error:

pip install -U git+https://github.com/huggingface/transformers

I am facing the same issue, were you able to resolve this?

solution

pip uninstall transformers
pip install git+https://github.com/huggingface/transformers

chenkq changed discussion status to closed

Try to use the dev version of transformers from huggingface official github. Qwen2VL requires 4.45.0.dev0.

!pip install git+https://github.com/huggingface/transformers@21fac7abba2a37fae86106f87fcf9974fd1e3830 accelerate

What is the requirements of the environment to run this model? I have transformers latest 4.44.2 but get the error on from transformers import Qwen2VLForConditionalGeneration, AutoTokenizer, AutoProcessor as

ImportError: cannot import name 'Qwen2VLForConditionalGeneration' from 'transformers

There is no other stacktrace. Please help.

it still now working , I tried every possible solution mentioned above

This comment has been hidden

Hey, were you able to resolve the issue? I've tried every solution possible but it isn't working

Sign up or log in to comment