neural_compressor.strategy.conservative
The conservative tuning strategy for quantization level 0.
Classes
Tuning strategy with accuracy first, performance second. |
Module Contents
- class neural_compressor.strategy.conservative.ConservativeTuneStrategy(model, conf, q_dataloader=None, q_func=None, eval_func=None, eval_dataloader=None, eval_metric=None, resume=None, q_hooks=None)[source]
Tuning strategy with accuracy first, performance second.
The quantization level O0 is designed for user who want to keep the accuracy of the model after quantization. It starts with the original(fp32) model, and then quantize the OPs to lower precision OP type wisely and OP wisely.