Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ValueError: Image features and image tokens do not match: tokens: 1991, features 2990 #556

Open
zhangboshen opened this issue Nov 25, 2024 · 6 comments

Comments

@zhangboshen
Copy link

Related discussion : huggingface/transformers#34625
I met this problem when sft qwen2-vl-7b using lora, training data is multi-images QA.

@CloudComputing-linux
Copy link

same problem

@thusinh1969
Copy link

What happened ? I used to be able to finetune Qwen2-VL with multiple images just fine. What is the bug now ?!?!

Cheers,
Steve

@gouqi666
Copy link

gouqi666 commented Jan 7, 2025

@zhangboshen @thusinh1969 @CloudComputing-linux @hzhwcmhf @c0g anyone have solution for this mismatch problem? i use llamafactory to train qwen2-vl

@mrwwk
Copy link

mrwwk commented Jan 22, 2025

same

@zhangboshen
Copy link
Author

@thusinh1969 @gouqi666 @CloudComputing-linux @mrwwk
I'm able to train the model by setting cutoff_len to a larger num that default. e.g., 10000;
It seems like this parameter affect the image token-image feature alignment to some extent.

@koleshjr
Copy link

Same I am facing this issue. Any fixes?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants