General Restrictions and APIs
General Restrictions
- AMCT does not perform security verification of passed file paths. Ensure that the file path arguments passed to any API call are correct.
- If the API contains a parameter that requires the user to enter the file path, the value of the parameter will be overwritten when quantization is performed again. The quantization log printed to the screen also contains a warning message indicating that the related file is overwritten.
APIs
Category |
API |
Function |
|---|---|---|
Common API |
Sets the log levels of the messages printed to the screen and those saved in the amct_log/amct_tensorflow.log file. |
|
PTQ APIs |
Finds all quantizable layers in a graph, creates a quantization configuration file, and writes the quantization configuration of the quantizable layers to the configuration file. |
|
Quantizes a graph based on the quantization configuration file, inserts the quantization operators, generates a quantization factor record file record_file, and returns the list of newly added operators. |
||
Saves the original .pb model to be quantized as a .pb model file that serves for online inference on the NPU (AI processor), based on the quantization factor record file (record_file). |
Parent topic: API Description