Skip to content

PTQ-Level Efficiency, QAT-Level Accuracy | 训练后量化的效率,量化感知训练的精度

fix bug (#1011)

Wenhua Chenge3f961058623
diff --git a/auto_round/compressors/base.py b/auto_round/compressors/base.py
index b4ef88201..f43008509 100644
--- a/auto_round/compressors/base.py
+++ b/auto_round/compressors/base.py
@@ -2730,7 +2730,7 @@ class BaseCompressor(object):
)
logger.info(dump_info)
if self.low_gpu_mem_usage:
- clear_memory(self.device_list) # clear cached memory during training
+ clear_memory(device_list=self.device_list) # clear cached memory during training
if len(unquantized_layer_names) != 0:
logger.info(f"{unquantized_layer_names} have not been quantized")
with torch.no_grad():