Skip to content

Commit 3f8cb2f

Browse files
authored
update accuracy evaluation scripts (#184)
* update accuracy evaluation scripts * remove labels of image classification
1 parent 62eaa30 commit 3f8cb2f

File tree

2 files changed

+17
-13
lines changed

2 files changed

+17
-13
lines changed

tools/eval/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Make sure you have the following packages installed:
55
```shell
66
pip install tqdm
77
pip install scikit-learn
8-
pip install scipy
8+
pip install scipy==1.8.1
99
```
1010

1111
Generally speaking, evaluation can be done with the following command:
@@ -27,7 +27,7 @@ Supported datasets:
2727

2828
### Prepare data
2929

30-
Please visit https://image-net.org/ to download the ImageNet dataset and [the labels from caffe](http://dl.caffe.berkeleyvision.org/caffe_ilsvrc12.tar.gz). Organize files as follow:
30+
Please visit https://image-net.org/ to download the ImageNet dataset (only need images in `ILSVRC/Data/CLS-LOC/val`) and [the labels from caffe](http://dl.caffe.berkeleyvision.org/caffe_ilsvrc12.tar.gz). Organize files as follow:
3131

3232
```shell
3333
$ tree -L 2 /path/to/imagenet

tools/eval/eval.py

Lines changed: 15 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -22,24 +22,24 @@
2222

2323
models = dict(
2424
mobilenetv1=dict(
25-
name="MobileNetV1",
25+
name="MobileNet",
2626
topic="image_classification",
2727
modelPath=os.path.join(root_dir, "models/image_classification_mobilenet/image_classification_mobilenetv1_2022apr.onnx"),
2828
topK=5),
2929
mobilenetv1_q=dict(
30-
name="MobileNetV1",
30+
name="MobileNet",
3131
topic="image_classification",
32-
modelPath=os.path.join(root_dir, "models/image_classification_mobilenet/image_classification_mobilenetv1_2022apr-int8-quantized.onnx"),
32+
modelPath=os.path.join(root_dir, "models/image_classification_mobilenet/image_classification_mobilenetv1_2022apr_int8.onnx"),
3333
topK=5),
3434
mobilenetv2=dict(
35-
name="MobileNetV2",
35+
name="MobileNet",
3636
topic="image_classification",
3737
modelPath=os.path.join(root_dir, "models/image_classification_mobilenet/image_classification_mobilenetv2_2022apr.onnx"),
3838
topK=5),
3939
mobilenetv2_q=dict(
40-
name="MobileNetV2",
40+
name="MobileNet",
4141
topic="image_classification",
42-
modelPath=os.path.join(root_dir, "models/image_classification_mobilenet/image_classification_mobilenetv2_2022apr-int8-quantized.onnx"),
42+
modelPath=os.path.join(root_dir, "models/image_classification_mobilenet/image_classification_mobilenetv2_2022apr_int8.onnx"),
4343
topK=5),
4444
ppresnet=dict(
4545
name="PPResNet",
@@ -49,7 +49,7 @@
4949
ppresnet_q=dict(
5050
name="PPResNet",
5151
topic="image_classification",
52-
modelPath=os.path.join(root_dir, "models/image_classification_ppresnet/image_classification_ppresnet50_2022jan-act_int8-wt_int8-quantized.onnx"),
52+
modelPath=os.path.join(root_dir, "models/image_classification_ppresnet/image_classification_ppresnet50_2022jan_int8.onnx"),
5353
topK=5),
5454
yunet=dict(
5555
name="YuNet",
@@ -72,19 +72,23 @@
7272
sface_q=dict(
7373
name="SFace",
7474
topic="face_recognition",
75-
modelPath=os.path.join(root_dir, "models/face_recognition_sface/face_recognition_sface_2021dec-act_int8-wt_int8-quantized.onnx")),
76-
crnn=dict(
75+
modelPath=os.path.join(root_dir, "models/face_recognition_sface/face_recognition_sface_2021dec_int8.onnx")),
76+
crnn_en=dict(
7777
name="CRNN",
7878
topic="text_recognition",
7979
modelPath=os.path.join(root_dir, "models/text_recognition_crnn/text_recognition_CRNN_EN_2021sep.onnx")),
80+
crnn_en_q=dict(
81+
name="CRNN",
82+
topic="text_recognition",
83+
modelPath=os.path.join(root_dir, "models/text_recognition_crnn/text_recognition_CRNN_EN_2022oct_int8.onnx")),
8084
pphumanseg=dict(
8185
name="PPHumanSeg",
8286
topic="human_segmentation",
83-
modelPath=os.path.join(root_dir, "models/human_segmentation_pphumanseg/human_segmentation_pphumanseg_2021oct.onnx")),
87+
modelPath=os.path.join(root_dir, "models/human_segmentation_pphumanseg/human_segmentation_pphumanseg_2023mar.onnx")),
8488
pphumanseg_q=dict(
8589
name="PPHumanSeg",
8690
topic="human_segmentation",
87-
modelPath=os.path.join(root_dir, "models/human_segmentation_pphumanseg/human_segmentation_pphumanseg_2021oct-act_int8-wt_int8-quantized.onnx")),
91+
modelPath=os.path.join(root_dir, "models/human_segmentation_pphumanseg/human_segmentation_pphumanseg_2023mar_int8.onnx")),
8892
)
8993

9094
datasets = dict(

0 commit comments

Comments
 (0)