Closed mmvxc closed 1 year ago
@irexyc hi, does sdk support ort-fp16 inference, which requires input's type is fp16.
Currently, the sdk does not support onnx-fp16.
Are you do the infernece with cpu backend? For cpu backend, onnxruntime probably doesn't have acceleration compared with fp32, you can verify it with onnxruntime python api. https://onnxruntime.ai/docs/api/python/api_summary.html
谢谢,我采用的是gpu
谢谢,我采用的是gpu
Currently, you can use tensorrt for gpu device.
Checklist
Describe the bug
loading mmdeploy_trt_net.dll ... loading mmdeploy_ort_net.dll ... [2023-08-08 17:18:12.721] [mmdeploy] [info] [model.cpp:35] [DirectoryModel] Load model: "rtmdet-ort/rtmdet-m" [2023-08-08 17:18:14.069] [mmdeploy] [error] [tensor.cpp:137] mismatched data type FLOAT vs HALF
Process finished with exit code -1073740791 (0xC0000409)
Reproduction
我想要使用onnxruntime fp16
1、我将RTMPose-m 转换为 ONNX deploy_cfg:https://github.com/open-mmlab/mmdeploy/blob/main/configs/mmdet/detection/detection_onnxruntime-fp16_dynamic.py model_cfg:https://github.com/open-mmlab/mmpose/blob/main/projects/rtmpose/rtmdet/person/rtmdet_m_640-8xb32_coco-person.py checkpoint:https://download.openmmlab.com/mmpose/v1/projects/rtmposev1/rtmpose-l_simcc-aic-coco_pt-aic-coco_420e-256x192-f016ffe0_20230126.pth
2、执行文件object_detection.py实现目标检测,模型采用第一步转换后的ONNX object_detection.py:https://github.com/open-mmlab/mmdeploy/blob/main/demo/python/object_detection.py
Environment
Error traceback
No response