PaddleDetection icon indicating copy to clipboard operation
PaddleDetection copied to clipboard

YOLOX-ConvNeXt-s的推理速度是多少?官网好像没有公布

Open lixiangMindSpore opened this issue 2 years ago • 6 comments

问题确认 Search before asking

  • [X] 我已经搜索过问题,但是没有找到解答。I have searched the question and found no related answer.

请提出你的问题 Please ask your question

YOLOX-ConvNeXt-s的推理速度是多少?官网好像没有公布 image

lixiangMindSpore avatar Sep 15 '22 04:09 lixiangMindSpore

这是trt测速,当时未测paddle版本有问题,普通测速来看慢于原版yolox-s很多。速度要求不高时可选用yolox-convnext

nemonameless avatar Sep 15 '22 05:09 nemonameless

这是trt测速,当时未测paddle版本有问题,普通测速来看慢于原版yolox-s很多。速度要求不高时可选用yolox-convnext

比原版yolox-s慢多少?当前速度要求虽然不是特别高,但是也有一定的要求,想知道相关推理速度指标。

lixiangMindSpore avatar Sep 15 '22 08:09 lixiangMindSpore

测试命令:

export inference model with trt=True

python tools/export_model.py -c configs/convnext/yolox_convnext_s_36e_coco.yml -o weights=https://paddledet.bj.bcebos.com/models/yolox_convnext_s_36e_coco.pdparams exclude_nms=True trt=True

convert to onnx

paddle2onnx --model_dir output_inference/yolox_convnext_s_36e_coco --model_filename model.pdmodel --params_filename model.pdiparams --opset_version 12 --save_file yolox_convnext_s_36e_coco.onnx

trt inference using fp16 and batch_size=1

trtexec --onnx=./yolox_convnext_s_36e_coco.onnx --saveEngine=./yolox_convnext_s_36e_coco_bs1.engine --workspace=1024 --avgRuns=1000 --shapes=image:1x3x640x640,scale_factor:1x2 --fp16 测试结果: yolox-convnext-s: 14.2538ms yolox-s:3.05123ms c96f9ce93a43068466264de05285f6a2 fcc16d6c262f322eb5b5c4bc6903fb06

wjm202 avatar Sep 16 '22 10:09 wjm202

convnext backbone里是gelu,cspdarknet里是silu,silu trt可以加速很多。这些测速都是去除NMS的,实际应用无论在什么平台上,都是要加上NMS的。 不用太关注一点点精度,改NMS参数阈值都会改变整体速度,可以自行调整。

nemonameless avatar Sep 16 '22 11:09 nemonameless

测试命令:

export inference model with trt=True

python tools/export_model.py -c configs/convnext/yolox_convnext_s_36e_coco.yml -o weights=https://paddledet.bj.bcebos.com/models/yolox_convnext_s_36e_coco.pdparams exclude_nms=True trt=True

convert to onnx

paddle2onnx --model_dir output_inference/yolox_convnext_s_36e_coco --model_filename model.pdmodel --params_filename model.pdiparams --opset_version 12 --save_file yolox_convnext_s_36e_coco.onnx

trt inference using fp16 and batch_size=1

trtexec --onnx=./yolox_convnext_s_36e_coco.onnx --saveEngine=./yolox_convnext_s_36e_coco_bs1.engine --workspace=1024 --avgRuns=1000 --shapes=image:1x3x640x640,scale_factor:1x2 --fp16 测试结果: yolox-convnext-s: 14.2538ms yolox-s:3.05123ms c96f9ce93a43068466264de05285f6a2 fcc16d6c262f322eb5b5c4bc6903fb06

您好,您这是在V100上测试的吗?

lixiangMindSpore avatar Sep 19 '22 00:09 lixiangMindSpore

convnext backbone里是gelu,cspdarknet里是silu,silu trt可以加速很多。这些测速都是去除NMS的,实际应用无论在什么平台上,都是要加上NMS的。 不用太关注一点点精度,改NMS参数阈值都会改变整体速度,可以自行调整。

YOLOX-ConvNeXt-s比YOLOX-s提升4.1%,不算小了

lixiangMindSpore avatar Sep 19 '22 01:09 lixiangMindSpore

您好,是在Tesla T4测试的

---原始邮件--- 发件人: @.> 发送时间: 2022年9月19日(周一) 上午8:51 收件人: @.>; 抄送: @.@.>; 主题: Re: [PaddlePaddle/PaddleDetection] YOLOX-ConvNeXt-s的推理速度是多少?官网好像没有公布 (Issue #6944)

wjm202 avatar Oct 11 '22 08:10 wjm202