Skip to content

Commit ff1860b

Browse files
[CI]fix lint (#7641)
### What this PR does / why we need it? This pull request addresses a linting issue by reordering a specific configuration assignment within the `apply_config_platform_defaults` method in `vllm_ascend/platform.py`. This change ensures compliance with code style guidelines without altering the functional behavior of the system. ### Does this PR introduce _any_ user-facing change? ### How was this patch tested? - vLLM version: v0.18.0 - vLLM main: vllm-project/vllm@ed359c4 Signed-off-by: Wang Kunpeng <1289706727@qq.com>
1 parent 05a5611 commit ff1860b

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

vllm_ascend/platform.py

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -189,12 +189,6 @@ def _get_default_max_cudagraph_capture_size(cls, vllm_config: VllmConfig) -> int
189189

190190
return min(max_num_seqs * decode_query_len, 512)
191191

192-
@classmethod
193-
def apply_config_platform_defaults(cls, vllm_config: VllmConfig) -> None:
194-
default_max_cg_capture_size = cls._get_default_max_cudagraph_capture_size(vllm_config)
195-
if default_max_cg_capture_size is not None:
196-
vllm_config.compilation_config.max_cudagraph_capture_size = default_max_cg_capture_size
197-
198192
@classmethod
199193
def get_device_capability(cls, device_id: int = 0):
200194
return None
@@ -209,6 +203,10 @@ def apply_config_platform_defaults(cls, vllm_config: VllmConfig) -> None:
209203
pass_config.sp_min_token_num = get_sp_min_token_num(vllm_config)
210204
logger.info(f"set sp_min_token_num to {pass_config.sp_min_token_num}")
211205

206+
default_max_cg_capture_size = cls._get_default_max_cudagraph_capture_size(vllm_config)
207+
if default_max_cg_capture_size is not None:
208+
vllm_config.compilation_config.max_cudagraph_capture_size = default_max_cg_capture_size
209+
212210
@classmethod
213211
def get_device_name(cls, device_id: int = 0) -> str:
214212
return torch.npu.get_device_name(device_id)

0 commit comments

Comments
 (0)