From e3f3aee6f4206df0c338709614056ce2860ef039 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicol=C3=B2=20Lucchesi?= Date: Thu, 15 May 2025 18:59:38 +0200 Subject: [PATCH] [Misc] Avoid cuda graph log when sizes still match (#18202) Signed-off-by: NickLucche --- vllm/config.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/vllm/config.py b/vllm/config.py index 19de4d0549b64..dddfdabd126a6 100644 --- a/vllm/config.py +++ b/vllm/config.py @@ -3950,11 +3950,12 @@ class CompilationConfig: self.cudagraph_capture_sizes = cudagraph_capture_sizes else: # de-duplicate the sizes provided by the config - self.cudagraph_capture_sizes = list( - set(self.cudagraph_capture_sizes)) - logger.info(("cudagraph sizes specified by model runner" - " %s is overridden by config %s"), - cudagraph_capture_sizes, self.cudagraph_capture_sizes) + dedup_sizes = list(set(self.cudagraph_capture_sizes)) + if len(dedup_sizes) < len(self.cudagraph_capture_sizes): + logger.info(("cudagraph sizes specified by model runner" + " %s is overridden by config %s"), + cudagraph_capture_sizes, dedup_sizes) + self.cudagraph_capture_sizes = dedup_sizes computed_compile_sizes = [] if self.compile_sizes is not None: