Skip to content

Commit 348dc80

Browse files
authored
Fix vllm gptq awq error (#12863)
* fix gptq awq error * fix python style
1 parent a488981 commit 348dc80

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

python/llm/src/ipex_llm/vllm/xpu/model_convert.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -93,10 +93,12 @@ def _ipex_llm_load_model(self) -> None:
9393
vllm_config=new_vllm_config
9494
)
9595
if self.vllm_config.model_config.low_bit_model_path is None:
96-
if "qwen" in self.vllm_config.model_config.model.lower() or \
97-
"baichuan" in self.vllm_config.model_config.model.lower() or \
98-
"codegeex4-all" in self.vllm_config.model_config.model.lower() or \
99-
"chatglm" in self.vllm_config.model_config.model.lower():
96+
if ("qwen" in self.vllm_config.model_config.model.lower() or
97+
"baichuan" in self.vllm_config.model_config.model.lower() or
98+
"codegeex4-all" in self.vllm_config.model_config.model.lower() or
99+
"chatglm" in self.vllm_config.model_config.model.lower()) and \
100+
"gptq" not in self.model_config.model.lower() and \
101+
"awq" not in self.model_config.model.lower():
100102
self.model.apply(padding_mlp)
101103
from ipex_llm import optimize_model
102104
not_convert_last_mlp = os.getenv("IPEX_LLM_NOT_CONVERT_LAST_MLP", None)

0 commit comments

Comments
 (0)