-
-
Notifications
You must be signed in to change notification settings - Fork 11k
[CI/Build] Also check DP in benchmarks throughput script #23038
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
Conversation
|
👋 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 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 🚀 |
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 adds a check to the throughput benchmark script to prevent the use of data parallelism, which is unsupported and causes the script to hang. The change correctly raises a ValueError when data_parallel_size is greater than 1. My feedback focuses on improving the formatting of the error message string to adhere to PEP 8 style guidelines and produce a cleaner, more readable error for the user.
| raise ValueError( | ||
| "Data parallel is not supported in offline benchmark, \ | ||
| please use benchmark serving instead" | ||
| ) |
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.
The string continuation using a backslash (\) includes the leading whitespace from the next line in the final string, resulting in a poorly formatted error message. According to PEP 8, the preferred way to wrap long lines is by using Python's implied line continuation inside parentheses. This improves readability and avoids unintended whitespace in the string.1
| raise ValueError( | |
| "Data parallel is not supported in offline benchmark, \ | |
| please use benchmark serving instead" | |
| ) | |
| raise ValueError( | |
| "Data parallel is not supported in offline benchmark, " | |
| "please use benchmark serving instead" | |
| ) |
Style Guide References
Footnotes
-
PEP 8 recommends using implied line continuation within parentheses for long lines over using a backslash, especially for strings, to improve readability and prevent issues with extraneous whitespace. ↩
…t#23038) Co-authored-by: Simon Mo <simon.mo@hey.com>
…t#23038) Co-authored-by: Simon Mo <simon.mo@hey.com>
…t#23038) Co-authored-by: Simon Mo <simon.mo@hey.com> Signed-off-by: Duncan Moss <djm.moss@gmail.com>
…t#23038) Co-authored-by: Simon Mo <simon.mo@hey.com>
…t#23038) Co-authored-by: Simon Mo <simon.mo@hey.com> Signed-off-by: Xiao Yu <xiao.yu@amd.com>
…t#23038) Co-authored-by: Simon Mo <simon.mo@hey.com>
…t#23038) Co-authored-by: Simon Mo <simon.mo@hey.com>
…t#23038) Co-authored-by: Simon Mo <simon.mo@hey.com>
…t#23038) Co-authored-by: Simon Mo <simon.mo@hey.com>
…t#23038) Co-authored-by: Simon Mo <simon.mo@hey.com>
Purpose
Like #16737, DP is not really supported in the throughput benchmarking, adding a checks to raise the issue. (See discussions in #16222)
Test Plan
Test Result
before: test will hang at
Processed prompts:after: raise errors