[Main][Refactor]Change ASCEND_QUATIZATION_METHOD to ASCEND_QUANTIZATION_METHOD (#2517)

### What this PR does / why we need it?
The constant ASCEND_QUATIZATION_METHOD in vllm_ascend/utils.py is
misspelled and should be corrected to ASCEND_QUANTIZATION_METHOD.

### Does this PR introduce _any_ user-facing change?
No

### How was this patch tested?
CI passed with new added/existing test.

- vLLM version: v0.10.1.1
- vLLM main:
c9abb10489

Signed-off-by: zhanghaiwen <zhanghaiwen@cmss.chinamobile.com>
Co-authored-by: zhanghaiwen <zhanghaiwen@cmss.chinamobile.com>
This commit is contained in:
zhanghw0354
2025-08-26 09:06:16 +08:00
committed by GitHub
parent 21b5727f9a
commit b3fdd78a6b
5 changed files with 16 additions and 17 deletions

View File

@@ -10,8 +10,7 @@ from vllm.model_executor.layers.linear import (LinearBase,
from tests.ut.base import TestBase
from vllm_ascend.quantization.quant_config import (AscendKVCacheMethod,
AscendQuantConfig)
ASCEND_QUATIZATION_METHOD = "ascend"
from vllm_ascend.utils import ASCEND_QUANTIZATION_METHOD
class TestAscendQuantConfig(TestBase):
@@ -42,7 +41,7 @@ class TestAscendQuantConfig(TestBase):
def test_get_name(self):
self.assertEqual(AscendQuantConfig.get_name(),
ASCEND_QUATIZATION_METHOD)
ASCEND_QUANTIZATION_METHOD)
def test_get_supported_act_dtypes(self):
supported_dtypes = AscendQuantConfig.get_supported_act_dtypes()
@@ -66,7 +65,7 @@ class TestAscendQuantConfig(TestBase):
# Test when NPU is available
mock_is_available.return_value = True
result = AscendQuantConfig.override_quantization_method(None, None)
self.assertEqual(result, ASCEND_QUATIZATION_METHOD)
self.assertEqual(result, ASCEND_QUANTIZATION_METHOD)
# Test when NPU is not available
mock_is_available.return_value = False