-
-
Notifications
You must be signed in to change notification settings - Fork 12k
fix: fix engine initialization fails with ValueError #30645
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
base: main
Are you sure you want to change the base?
fix: fix engine initialization fails with ValueError #30645
Conversation
|
Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits. |
|
👋 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 You ask your reviewers to trigger select CI tests on top of 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 If you have any questions, please reach out to us on Slack at https://slack.vllm.ai. 🚀 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request correctly addresses a ValueError that occurs during GLM-4.1V engine initialization. The root cause, related to dummy video input generation, has been accurately identified, and the proposed fix of changing the minimum fallback value for frames is effective. My review includes one suggestion to enhance the code's maintainability by programmatically deriving this fallback value instead of using a hardcoded number.
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com> Signed-off-by: nathon <[email protected]>
DarkLight1337
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Which model repo are you using and what is your transformers version? I can't seem to reproduce the problem even after hardcoding this method to return 1.
Fix GLM-4.1V dummy video input generation failure
Problem
GLM-4.1V engine initialization fails with
ValueError: t:1 must be larger than temporal_factor:2during dummy video input generation.Root Cause
vllm/model_executor/models/glm4_1v.py:995inget_num_frames_with_most_features()functionmax(max_frames_per_video, 1), which can return1when video token allocation is insufficientsmart_resizefunction requiresnum_frames > temporal_factor=2(strict inequality)num_frames=1violates1 > 2, causingValueErrorand engine core crashError Stack Trace
Solution
Change the minimum fallback value from
1to3inget_num_frames_with_most_features():Why 3?
num_frames > temporal_factor=2num_frames >= 33 > 2✓ (constraint satisfied)Impact
Testing
Related Issues
Fixes #30638
Checklist
get_num_frames_with_most_features()num_frames > temporal_factor=2constraint