Skip to content

[Bugfix] Fix embedding assignment for InternVL-based models #15086

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

Merged
merged 3 commits into from
Mar 20, 2025

Conversation

DarkLight1337
Copy link
Member

@DarkLight1337 DarkLight1337 commented Mar 19, 2025

Similar to #14980, this PR fixes the mismatch between multimodal embeddings and PlaceholderRange indices for InternVL-based models.

FIX #14897 (comment)

Copy link

👋 Hi! Thank you for contributing to the vLLM project.

💬 Join our developer Slack at https://slack.vllm.ai to discuss your PR in #pr-reviews, coordinate on features in #feat- channels, or join special interest groups in #sig- channels.

Just a reminder: PRs would not trigger full CI run by default. Instead, it would only run fastcheck CI which starts running only a small and essential subset of CI tests to quickly catch errors. You can run other CI tests on top of those by going to your fastcheck build on Buildkite UI (linked in the PR checks section) and unblock them. If you do not have permission to unblock, ping simon-mo or khluu to add you in our Buildkite org.

Once the PR is approved and ready to go, your PR reviewer(s) can run CI to test the changes comprehensively before merging.

To run CI, PR reviewers can either: Add ready label to the PR or enable auto-merge.

🚀

@mergify mergify bot added the documentation Improvements or additions to documentation label Mar 19, 2025
Copy link

mergify bot commented Mar 19, 2025

This pull request has merge conflicts that must be resolved before it can be
merged. Please rebase the PR, @DarkLight1337.

https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/syncing-a-fork

@mergify mergify bot added multi-modality Related to multi-modality (#4194) needs-rebase labels Mar 19, 2025
@DarkLight1337
Copy link
Member Author

DarkLight1337 commented Mar 19, 2025

@gohar94 please try out this fix.

@mergify mergify bot removed the needs-rebase label Mar 19, 2025
@DarkLight1337 DarkLight1337 marked this pull request as ready for review March 19, 2025 07:05
@DarkLight1337 DarkLight1337 requested a review from ywang96 as a code owner March 19, 2025 07:05
@DarkLight1337 DarkLight1337 requested a review from Isotr0py March 19, 2025 16:53
@DarkLight1337 DarkLight1337 changed the title [Bugfix] Fix embedding assignment for InternVL-related models on V1 [Bugfix] Fix embedding assignment for InternVL-based models on V1 Mar 19, 2025
@DarkLight1337 DarkLight1337 changed the title [Bugfix] Fix embedding assignment for InternVL-based models on V1 [Bugfix] Fix embedding assignment for InternVL-based models Mar 19, 2025
@gohar94
Copy link

gohar94 commented Mar 19, 2025

Thanks, @DarkLight1337. Seems to work fine now.

@DarkLight1337 DarkLight1337 added the ready ONLY add when PR is ready to merge/full CI is needed label Mar 19, 2025
Copy link
Collaborator

@Isotr0py Isotr0py left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall LGTM. Is it possible to add a test in processor tests for each model to validate the matching between PlaceholderRange and the processed input_ids?

@DarkLight1337
Copy link
Member Author

DarkLight1337 commented Mar 19, 2025

Is it possible to add a test in processor tests for each model to validate the matching between PlaceholderRange and the processed input_ids?

I think we can address this inside V1 Engine, as mentioned in #15144. So if there is any mismatch, the model itself will fail fast, causing model correctness CI to fail. However we need to fix the existing models first before we can enable that.

@DarkLight1337 DarkLight1337 enabled auto-merge (squash) March 19, 2025 17:33
@DarkLight1337 DarkLight1337 merged commit ffa443a into vllm-project:main Mar 20, 2025
49 checks passed
@DarkLight1337 DarkLight1337 deleted the fix-internvl-mm-v1 branch March 20, 2025 04:34
erictang000 pushed a commit to erictang000/vllm that referenced this pull request Mar 25, 2025
gmarinho2 pushed a commit to gmarinho2/vllm that referenced this pull request Apr 1, 2025
lulmer pushed a commit to lulmer/vllm that referenced this pull request Apr 7, 2025
nishith-fujitsu pushed a commit to nishith-fujitsu/vllm that referenced this pull request Apr 9, 2025
shreyankg pushed a commit to shreyankg/vllm that referenced this pull request May 3, 2025
RichardoMrMu pushed a commit to RichardoMrMu/vllm that referenced this pull request May 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation multi-modality Related to multi-modality (#4194) ready ONLY add when PR is ready to merge/full CI is needed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: Gemma3 Offline Batch Inference: Attempted to assign XXX multimodal tokens to YYY placeholders
3 participants