From 3595bbe085aa5674fe9d4907111fac3f324b3066 Mon Sep 17 00:00:00 2001 From: Linkun Chen Date: Mon, 28 Oct 2024 16:58:48 -0700 Subject: [PATCH] fix lint --- benchmarks/benchmark_throughput.py | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/benchmarks/benchmark_throughput.py b/benchmarks/benchmark_throughput.py index fafc7d2f96087..98526e0a3f364 100644 --- a/benchmarks/benchmark_throughput.py +++ b/benchmarks/benchmark_throughput.py @@ -81,12 +81,13 @@ def sample_requests( SampleRequest(prompt=prompt, prompt_len=prompt_len, expected_output_len=output_len)) - print(data) if "image" in data: - filtered_dataset[-1].multi_modal_data = filtered_dataset[-1].multi_modal_data or {} + filtered_dataset[-1].multi_modal_data = filtered_dataset[ + -1].multi_modal_data or {} image_path = data["image"] assert isinstance(image_path, str) - filtered_dataset[-1].multi_modal_data["image"] = Image.open(image_path).convert("RGB") + filtered_dataset[-1].multi_modal_data["image"] = Image.open( + image_path).convert("RGB") return filtered_dataset @@ -103,8 +104,9 @@ def run_vllm( prompts: List[TextPrompt] = [] sampling_params: List[SamplingParams] = [] for request in requests: - prompts.append(TextPrompt(prompt=request.prompt, multi_modal_data=request.multi_modal_data)) - print(prompts[-1]) + prompts.append( + TextPrompt(prompt=request.prompt, + multi_modal_data=request.multi_modal_data)) sampling_params.append( SamplingParams( n=n,