ONE
ONE copied to clipboard
[onert/odc] Draft for odc: hidden switching mechanism. fcircle-qcircle step
This is draft for odc: hidden switching mechanism. fcircle-qcircle step was implemented.
Conv2D_000.circle is used as model for test (it was added just for this draft verification) Size of the model: 556B
This draft contains auto compilation (odc: hidden switching mechanism
) , which is executed in nnfw_run_with_auto_compilation
function.
-
nnfw_run_with_auto_compilation
function was added. - odc::QuantizerManager, odc::Quantizer and odc::MinMaxReader were changes for set and minmax threshold and cheсking readiness for quantization. Function for removing minmax file was added. (question about set up the minmax file location)
- OdcInfo class for storaging actual state of the odc was added.
After model quantization, the removing minmax file step was added. After first loading quantized model the following sequence was implemented:
- save the inputs and outputs buffers of the initial fcricle model
- reload qcircle model to the session
- recover inputs and outputs
after that do inference of the quantized model
For running test of this draft:
BUILD_TYPE=Debug BUILD_JOBS=6 make -f Makefile.template
cd ./Product/out/unittest
./nnfw_api_gtest --gtest_filter=TestOdcAutoCompilation*
Time of the test execution: 11 ms Peak memory footprint of the test: 4,939 Kb
ONE-DCO-1.0-Signed-off-by: Evgenii Maltsev [email protected]