mirror of
https://github.com/NVIDIA/TensorRT-LLM.git
synced 2026-01-13 22:18:36 +08:00
fix: fnmatch usage in modeling_utils.py (#3754)
Signed-off-by: Enwei Zhu <21126786+syuoni@users.noreply.github.com>
This commit is contained in:
parent
8340657ae4
commit
353699a3b3
@ -295,7 +295,7 @@ class LayerQuantConfig(QuantConfig):
|
||||
def layer_quant_mode(self, layer_name) -> QuantMode:
|
||||
|
||||
for name, quant_mode in self.auto_quant_mode.items():
|
||||
if fnmatch(layer_name, name):
|
||||
if fnmatch.fnmatch(layer_name, name):
|
||||
return quant_mode
|
||||
|
||||
return QuantMode(0)
|
||||
@ -324,7 +324,7 @@ class LayerQuantConfig(QuantConfig):
|
||||
quant_res = QuantConfig()
|
||||
|
||||
for name, quant_cfg in self.quantized_layers.items():
|
||||
if fnmatch(module_name, name):
|
||||
if fnmatch.fnmatch(module_name, name):
|
||||
quant_res = quant_cfg
|
||||
break
|
||||
return quant_res
|
||||
|
||||
Loading…
Reference in New Issue
Block a user