提交 91a3d40e 编写于 作者: B Bin Li

Update quantization doc

上级 15925d14
...@@ -42,14 +42,16 @@ MACE provides tools to do statistics with following steps: ...@@ -42,14 +42,16 @@ MACE provides tools to do statistics with following steps:
.. code:: sh .. code:: sh
# convert images to input tensors for MACE # Convert images to input tensors for MACE, see image_to_tensor.py for more arguments.
python tools/image/image_to_tensor.py --input /path/to/directory/of/input/images python tools/image/image_to_tensor.py --input /path/to/directory/of/input/images
--output_dir /path/to/directory/of/input/tensors --image_shape=299,299,3 --output_dir /path/to/directory/of/input/tensors --image_shape=299,299,3
# rename input tensors to start with input tensor name # Rename input tensors to start with input tensor name(to differentiate multiple
# inputs of a model), input tensor name is what you specified as "input_tensors"
# in yaml config. For example, "input" is the input tensor name of InceptionV3 as below.
rename 's/^/input/' * rename 's/^/input/' *
# run with input tensors # Run with input tensors
python tools/converter.py run --config ../mace-models/inception-v3/inception-v3.yml --example python tools/converter.py run --config ../mace-models/inception-v3/inception-v3.yml --example
--quantize_stat --input_dir /path/to/directory/of/input/tensors > range_log --quantize_stat --input_dir /path/to/directory/of/input/tensors > range_log
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册