[Fix] NVFP4 qwen3.5 quant error fix by add packed_modules_mapping (#23471)
Co-authored-by: 百麒 <yaozhong.lyz@alibaba-inc.com>
This commit is contained in:
@@ -932,7 +932,6 @@ ALL_DECODER_LAYER_TYPES = {
|
||||
class Qwen3_5ForCausalLM(nn.Module):
|
||||
"""Qwen3.5 Model with support for dense variant."""
|
||||
|
||||
if _is_gfx95 or _is_npu:
|
||||
packed_modules_mapping = {
|
||||
"qkv_proj": ["q_proj", "k_proj", "v_proj"],
|
||||
"gate_up_proj": ["gate_proj", "up_proj"],
|
||||
@@ -1377,7 +1376,7 @@ class Qwen3_5MoeForCausalLM(Qwen3_5ForCausalLM):
|
||||
|
||||
|
||||
class Qwen3_5ForConditionalGeneration(Qwen3VLForConditionalGeneration):
|
||||
if _is_gfx95 or _is_npu:
|
||||
|
||||
packed_modules_mapping = Qwen3_5ForCausalLM.packed_modules_mapping
|
||||
hf_to_sglang_mapper = None
|
||||
|
||||
@@ -1524,7 +1523,6 @@ class Qwen3_5ForConditionalGeneration(Qwen3VLForConditionalGeneration):
|
||||
class Qwen3_5MoeForConditionalGeneration(Qwen3VLForConditionalGeneration):
|
||||
"""Qwen3.5 MoE Vision-Language Model."""
|
||||
|
||||
if _is_gfx95 or _is_npu:
|
||||
packed_modules_mapping = Qwen3_5ForCausalLM.packed_modules_mapping
|
||||
hf_to_sglang_mapper = None
|
||||
|
||||
|
||||
Reference in New Issue
Block a user