File size: 241 Bytes
2d4936d | 1 2 3 4 | import sys
from onnxruntime.quantization import QuantType, quantize_dynamic
quantize_dynamic(sys.argv[1], sys.argv[2], weight_type=QuantType.QInt8, per_channel=True, op_types_to_quantize=["MatMul"], extra_options={"MatMulConstBOnly": True})
|