-
I am trying to do int8 quantization on a pytorch model and am confused as to how to select the accuracy aware method and provide the max accuracy drop. Any help with this would be appreciated. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hi @camhpj,
OpenVINO example: https://github.com/openvinotoolkit/nncf/tree/develop/examples/post_training_quantization/openvino/yolov8_quantize_with_accuracy_control
|
Beta Was this translation helpful? Give feedback.
Hi @camhpj,
nncf.quantize_with_accuracy_control
does not yet support the PyTorch model directly, instead you can export a PyTorch model to OpenVINO or ONNX and runnncf.quantize_with_accuracy_control
on the exported model.OpenVINO example: https://github.com/openvinotoolkit/nncf/tree/develop/examples/post_training_quantization/openvino/yolov8_quantize_with_accuracy_control
ONNX example: https://github.com/openvinotoolkit/nncf/tree/develop/examples/post_training_quantization/onnx/yolov8_quantize_with_accuracy_control
nncf.quantize_with_accuracy_control
controls of accuracy metric by keeping the most impactful operations within the model in the original precision (OpenVINO documentation). …