PTQ-Level Efficiency, QAT-Level Accuracy | 训练后量化的效率,量化感知训练的精度
fix performance regression (#1886)
Wenhua Cheng30f72bdad7d1
diff --git a/auto_round/compressors/data_driven.py b/auto_round/compressors/data_driven.pyindex 718558e7d..2fb3358e6 100644--- a/auto_round/compressors/data_driven.py+++ b/auto_round/compressors/data_driven.py@@ -570,9 +570,9 @@ class DataDrivenCompressor(BaseCompressor):if len(self.compress_context.device_list) > 1 and not self.model_context.is_diffusion:accelerate.hooks.remove_hook_from_submodules(m)mv_module_from_gpu(m)- if self.enable_torch_compile:- torch._dynamo.reset()- self.quantizer._invalidate_block_forward_cache()+ # if self.enable_torch_compile:+ # torch._dynamo.reset()+ # self.quantizer._invalidate_block_forward_cache()# Keep old-arch semantics: the next block's FP reference input comes# from the current block's reference output, while q_input (when# enabled) is only used as the quantized-input companion for the