Skip to content

Commit

Permalink
fix error when set device cpu && fix docs error (#866)
Browse files Browse the repository at this point in the history
  • Loading branch information
OldDreamInWind authored Aug 5, 2022
1 parent 4001a06 commit 80d24fc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions docs/zh_cn/02-how-to-run/quantize_model.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ python3 setup.py install

```bash
cd /path/to/mmdeploy
export MODEL_PATH=/path/to/mmclassification/configs/resnet/resnet18_8xb16_cifar10.py
export MODEL_CONFIG=https://download.openmmlab.com/mmclassification/v0/resnet/resnet18_b16x8_cifar10_20210528-bd6371c8.pth
export MODEL_CONFIG=/path/to/mmclassification/configs/resnet/resnet18_8xb16_cifar10.py
export MODEL_PATH=https://download.openmmlab.com/mmclassification/v0/resnet/resnet18_b16x8_cifar10_20210528-bd6371c8.pth

python3 tools/deploy.py configs/mmcls/classification_ncnn-int8_static.py ${MODEL_CONFIG} ${MODEL_PATH} /path/to/self-test.png --work-dir work_dir --device cpu --quant --quant-image-dir /path/to/images
...
Expand Down
2 changes: 1 addition & 1 deletion tools/deploy.py
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ def main():
'ncnn quant table',
target=get_table,
args=(onnx_path, deploy_cfg, model_cfg, quant_onnx,
quant_table, quant_image_dir),
quant_table, quant_image_dir, args.device),
kwargs=dict(),
ret_value=ret_value)

Expand Down

0 comments on commit 80d24fc

Please sign in to comment.