mirror of
https://github.com/wassname/vllm.git
synced 2026-09-12 13:01:01 +08:00
[Model] Add AWQ quantization support for InternVL2 model (#7187)
This commit is contained in:
@@ -131,6 +131,10 @@ def get_quant_config(model_config: ModelConfig,
|
||||
# Read the quantization config from the HF model config, if available.
|
||||
hf_quant_config = getattr(model_config.hf_config, "quantization_config",
|
||||
None)
|
||||
# some vision model may keep quantization_config in their text_config
|
||||
hf_text_config = getattr(model_config.hf_config, "text_config", None)
|
||||
if hf_quant_config is None and hf_text_config is not None:
|
||||
hf_quant_config = getattr(hf_text_config, "quantization_config", None)
|
||||
if hf_quant_config is None:
|
||||
# compressed-tensors uses a compressions_config
|
||||
hf_quant_config = getattr(model_config.hf_config, "compression_config",
|
||||
|
||||
Reference in New Issue
Block a user