-
-
Notifications
You must be signed in to change notification settings - Fork 11k
[Doc] Update benchmarks README #14646
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
+165
−13
Merged
Changes from 2 commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
6a72151
update benchmark readme
JenZhao 3d521af
address comments
JenZhao cd7a5f6
Update benchmarks/README.md
ywang96 9ad7879
Update benchmarks/README.md
ywang96 695c432
address comments
JenZhao ed02556
update sharegpt local path
JenZhao 982c42b
address comments
JenZhao File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,29 +1,143 @@ | ||
| # Benchmarking vLLM | ||
|
|
||
| ## Downloading the ShareGPT dataset | ||
| ## Dataset Overview | ||
|
|
||
| You can download the dataset by running: | ||
| <table style="width:100%; border-collapse: collapse;"> | ||
| <thead> | ||
| <tr> | ||
| <th style="width:15%; text-align: left;">Dataset</th> | ||
| <th style="width:10%; text-align: center;">Online</th> | ||
| <th style="width:10%; text-align: center;">Offline</th> | ||
| <th style="width:65%; text-align: left;">Data Path</th> | ||
| </tr> | ||
| </thead> | ||
| <tbody> | ||
| <tr> | ||
| <td><strong>ShareGPT</strong></td> | ||
| <td style="text-align: center;">✅</td> | ||
| <td style="text-align: center;">✅</td> | ||
| <td><code>wget https://huggingface.co/datasets/anon8231489123/ShareGPT_Vicuna_unfiltered/resolve/main/ShareGPT_V3_unfiltered_cleaned_split.json</code></td> | ||
| </tr> | ||
| <tr> | ||
| <td><strong>BurstGPT</strong></td> | ||
| <td style="text-align: center;">✅</td> | ||
| <td style="text-align: center;">✅</td> | ||
| <td><code>wget https://github.com/HPMLL/BurstGPT/releases/download/v1.1/BurstGPT_without_fails_2.csv</code></td> | ||
| </tr> | ||
| <tr> | ||
| <td><strong>Sonnet</strong></td> | ||
| <td style="text-align: center;">✅</td> | ||
| <td style="text-align: center;">✅</td> | ||
| <td>Local file: <code>benchmarks/sonnet.txt</code></td> | ||
| </tr> | ||
| <tr> | ||
| <td><strong>Random</strong></td> | ||
| <td style="text-align: center;">✅</td> | ||
| <td style="text-align: center;">✅</td> | ||
| <td><code>synthetic</code></td> | ||
| </tr> | ||
| <tr> | ||
| <td><strong>HuggingFace</strong></td> | ||
| <td style="text-align: center;">✅</td> | ||
| <td style="text-align: center;">🚧</td> | ||
| <td>Specify your dataset path on HuggingFace</td> | ||
| </tr> | ||
| <tr> | ||
| <td><strong>VisionArena</strong></td> | ||
| <td style="text-align: center;">✅</td> | ||
| <td style="text-align: center;">🚧</td> | ||
| <td><code>lmarena-ai/vision-arena-bench-v0.1</code> (a HuggingFace dataset)</td> | ||
| </tr> | ||
| </tbody> | ||
| </table> | ||
| ✅: supported | ||
| 🚧: to be supported | ||
|
|
||
| **Note**: VisionArena’s `dataset-name` should be set to `hf` | ||
|
|
||
| --- | ||
| ## Example - Online Benchmark | ||
|
|
||
| First start serving your model | ||
|
|
||
| ```bash | ||
| wget https://huggingface.co/datasets/anon8231489123/ShareGPT_Vicuna_unfiltered/resolve/main/ShareGPT_V3_unfiltered_cleaned_split.json | ||
| MODEL_NAME="NousResearch/Hermes-3-Llama-3.1-8B" | ||
| vllm serve ${MODEL_NAME} --disable-log-requests | ||
| ``` | ||
|
|
||
| ## Downloading the ShareGPT4V dataset | ||
|
|
||
| The json file refers to several image datasets (coco, llava, etc.). The benchmark scripts | ||
| will ignore a datapoint if the referred image is missing. | ||
| Then run the benchmarking script | ||
|
|
||
| ```bash | ||
| wget https://huggingface.co/datasets/Lin-Chen/ShareGPT4V/resolve/main/sharegpt4v_instruct_gpt4-vision_cap100k.json | ||
| mkdir coco -p | ||
| wget http://images.cocodataset.org/zips/train2017.zip -O coco/train2017.zip | ||
| unzip coco/train2017.zip -d coco/ | ||
| MODEL_NAME="NousResearch/Hermes-3-Llama-3.1-8B" | ||
| NUM_PROMPTS=10 | ||
| BACKEND="openai-chat" | ||
| DATASET_NAME="sonnet" | ||
| DATASET_PATH="benchmarks/sonnet.txt" | ||
| python3 benchmarks/benchmark_serving.py --backend ${BACKEND} --model ${MODEL_NAME} --endpoint /v1/chat/completions --dataset-name ${DATASET_NAME} --dataset-path ${DATASET_PATH} --num-prompts ${NUM_PROMPTS} | ||
| ``` | ||
|
|
||
| # Downloading the BurstGPT dataset | ||
| VisionArena example | ||
|
|
||
| You can download the BurstGPT v1.1 dataset by running: | ||
| ```bash | ||
| # need a model with vision capability here | ||
| vllm serve Qwen/Qwen2-VL-7B-Instruct --disable-log-requests | ||
| ``` | ||
|
|
||
| ```bash | ||
| wget https://github.com/HPMLL/BurstGPT/releases/download/v1.1/BurstGPT_without_fails_2.csv | ||
| MODEL_NAME="Qwen/Qwen2-VL-7B-Instruct" | ||
| NUM_PROMPTS=10 | ||
| BACKEND="openai-chat" | ||
| DATASET_NAME="hf" | ||
| DATASET_PATH="lmarena-ai/vision-arena-bench-v0.1" | ||
| DATASET_SPLIT='train' | ||
|
|
||
| python3 benchmarks/benchmark_serving.py \ | ||
| --backend "${BACKEND}" \ | ||
| --model "${MODEL_NAME}" \ | ||
| --endpoint "/v1/chat/completions" \ | ||
| --dataset-name "${DATASET_NAME}" \ | ||
| --dataset-path "${DATASET_PATH}" \ | ||
| --hf-split "${DATASET_SPLIT}" \ | ||
| --num-prompts "${NUM_PROMPTS}" | ||
| ``` | ||
|
|
||
| --- | ||
| ## Example - Offline Throughput Benchmark | ||
|
|
||
| ```bash | ||
| MODEL_NAME="NousResearch/Hermes-3-Llama-3.1-8B" | ||
| NUM_PROMPTS=10 | ||
| DATASET_NAME="sonnet" | ||
| DATASET_PATH="benchmarks/sonnet.txt" | ||
|
|
||
| python3 benchmarks/benchmark_throughput.py \ | ||
| --model "${MODEL_NAME}" \ | ||
| --dataset-name "${DATASET_NAME}" \ | ||
| --dataset-path "${DATASET_PATH}" \ | ||
| --num-prompts "${NUM_PROMPTS}" | ||
| ``` | ||
|
|
||
| With LoRA | ||
ywang96 marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| ``` bash | ||
| MODEL_NAME="meta-llama/Llama-2-7b-hf" | ||
| BACKEND="vllm" | ||
| DATASET_NAME="sharegpt" | ||
| DATASET_PATH="/home/jovyan/data/vllm_benchmark_datasets/ShareGPT_V3_unfiltered_cleaned_split.json" | ||
| NUM_PROMPTS=10 | ||
| MAX_LORAS=2 | ||
| MAX_LORA_RANK=8 | ||
| ENABLE_LORA="--enable-lora" | ||
| LORA_PATH="yard1/llama-2-7b-sql-lora-test" | ||
|
|
||
| python3 benchmarks/benchmark_throughput.py \ | ||
| --model "${MODEL_NAME}" \ | ||
| --backend "${BACKEND}" \ | ||
| --dataset_path "${DATASET_PATH}" \ | ||
| --dataset_name "${DATASET_NAME}" \ | ||
| --num-prompts "${NUM_PROMPTS}" \ | ||
| --max-loras "${MAX_LORAS}" \ | ||
| --max-lora-rank "${MAX_LORA_RANK}" \ | ||
| ${ENABLE_LORA} \ | ||
| --lora-path "${LORA_PATH}" | ||
| ``` | ||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.