From 63fa86604ce2c8ad87f5c5e4cbd4c38090c66756 Mon Sep 17 00:00:00 2001 From: Chujie Zheng Date: Wed, 6 Mar 2024 14:41:42 -0800 Subject: [PATCH] Add tqdm `dynamic_ncols=True` (#3242) --- vllm/entrypoints/llm.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/vllm/entrypoints/llm.py b/vllm/entrypoints/llm.py index 62f1d172377f6..1f463bdaaedc3 100644 --- a/vllm/entrypoints/llm.py +++ b/vllm/entrypoints/llm.py @@ -191,7 +191,9 @@ def _run_engine(self, use_tqdm: bool) -> List[RequestOutput]: # Initialize tqdm. if use_tqdm: num_requests = self.llm_engine.get_num_unfinished_requests() - pbar = tqdm(total=num_requests, desc="Processed prompts") + pbar = tqdm(total=num_requests, + desc="Processed prompts", + dynamic_ncols=True) # Run the engine. outputs: List[RequestOutput] = [] while self.llm_engine.has_unfinished_requests():