[Backend] Add KunlunXin XPU deploy support (#747)

* add xpu support

* fix docs

* update code

* update doc

* update code

* update yolov5

* update cmake

* add int64_t data support

* fix

* update download links

* add en doc

* update code

* update xpu options

* update doc

* update doc

* update doc

* update lib links

* update doc

* update code

* update lite xpu link

* update xpu lib

* update doc

* update en doc
This commit is contained in:
yeliang2258
2022-12-15 21:17:14 +08:00
committed by GitHub
parent 6e79df40d9
commit 5be839b322
39 changed files with 870 additions and 58 deletions

11
examples/vision/detection/yolov5/python/README.md Normal file → Executable file
View File

@@ -13,15 +13,18 @@ git clone https://github.com/PaddlePaddle/FastDeploy.git
cd examples/vision/detection/yolov5/python/
#下载yolov5模型文件和测试图片
wget https://bj.bcebos.com/paddlehub/fastdeploy/yolov5s.onnx
wget https://bj.bcebos.com/paddlehub/fastdeploy/yolov5s_infer.tar
tar -xf yolov5s_infer.tar
wget https://gitee.com/paddlepaddle/PaddleDetection/raw/release/2.4/demo/000000014439.jpg
# CPU推理
python infer.py --model yolov5s.onnx --image 000000014439.jpg --device cpu
python infer.py --model yolov5s_infer --image 000000014439.jpg --device cpu
# GPU推理
python infer.py --model yolov5s.onnx --image 000000014439.jpg --device gpu
python infer.py --model yolov5s_infer --image 000000014439.jpg --device gpu
# GPU上使用TensorRT推理
python infer.py --model yolov5s.onnx --image 000000014439.jpg --device gpu --use_trt True
python infer.py --model yolov5s_infer --image 000000014439.jpg --device gpu --use_trt True
# XPU推理
python infer.py --model yolov5s_infer --image 000000014439.jpg --device xpu
```
运行完成可视化结果如下图所示