@@ -110,12 +110,11 @@ Step2. Choose a quantizer and compress the model
...
@@ -110,12 +110,11 @@ Step2. Choose a quantizer and compress the model
Step3. Export compression result
Step3. Export compression result
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
You can export the quantized model directly by using ``torch.save`` api and the quantized model can be loaded by ``torch.load`` without any extra modification.
After training and calibration, you can export model weight to a file, and the generated calibration parameters to a file as well. Exporting onnx model is also supported.
.. code-block:: python
.. code-block:: python
# Save quantized model which is generated by using NNI QAT algorithm