mirror of
https://github.com/PaddlePaddle/FastDeploy.git
synced 2025-10-12 20:11:20 +08:00
[Benchmark]Benchmark cpp for YOLOv5 (#1224)
* add GPL lisence * add GPL-3.0 lisence * add GPL-3.0 lisence * add GPL-3.0 lisence * support yolov8 * add pybind for yolov8 * add yolov8 readme * add cpp benchmark * add cpu and gpu mem * public part split * add runtime mode * fixed bugs * add cpu_thread_nums * deal with comments * deal with comments * deal with comments * rm useless code * add FASTDEPLOY_DECL * add FASTDEPLOY_DECL
This commit is contained in:
27
benchmark/python/run_benchmark_uie.sh
Normal file
27
benchmark/python/run_benchmark_uie.sh
Normal file
@@ -0,0 +1,27 @@
|
||||
# wget https://bj.bcebos.com/fastdeploy/benchmark/uie/reimbursement_form_data.txt
|
||||
# wget https://bj.bcebos.com/fastdeploy/models/uie/uie-base.tgz
|
||||
# tar xvfz uie-base.tgz
|
||||
|
||||
DEVICE_ID=0
|
||||
|
||||
echo "[FastDeploy] Running UIE benchmark..."
|
||||
|
||||
# GPU
|
||||
echo "-------------------------------GPU Benchmark---------------------------------------"
|
||||
python benchmark_uie.py --epoch 5 --model_dir uie-base --data_path reimbursement_form_data.txt --backend paddle --device_id $DEVICE_ID --device gpu --enable_collect_memory_info True
|
||||
python benchmark_uie.py --epoch 5 --model_dir uie-base --data_path reimbursement_form_data.txt --backend ort --device_id $DEVICE_ID --device gpu --enable_collect_memory_info True
|
||||
python benchmark_uie.py --epoch 5 --model_dir uie-base --data_path reimbursement_form_data.txt --backend paddle_trt --device_id $DEVICE_ID --device gpu --enable_trt_fp16 False --enable_collect_memory_info True
|
||||
python benchmark_uie.py --epoch 5 --model_dir uie-base --data_path reimbursement_form_data.txt --backend trt --device_id $DEVICE_ID --device gpu --enable_trt_fp16 False --enable_collect_memory_info True
|
||||
python benchmark_uie.py --epoch 5 --model_dir uie-base --data_path reimbursement_form_data.txt --backend paddle_trt --device_id $DEVICE_ID --device gpu --enable_trt_fp16 True --enable_collect_memory_info True
|
||||
python benchmark_uie.py --epoch 5 --model_dir uie-base --data_path reimbursement_form_data.txt --backend trt --device_id $DEVICE_ID --device gpu --enable_trt_fp16 True --enable_collect_memory_info True
|
||||
echo "-----------------------------------------------------------------------------------"
|
||||
|
||||
# CPU
|
||||
echo "-------------------------------CPU Benchmark---------------------------------------"
|
||||
for cpu_num_threads in 1 8;
|
||||
do
|
||||
python benchmark_uie.py --epoch 5 --model_dir uie-base --data_path reimbursement_form_data.txt --backend paddle --device cpu --cpu_num_threads ${cpu_num_threads} --enable_collect_memory_info True
|
||||
python benchmark_uie.py --epoch 5 --model_dir uie-base --data_path reimbursement_form_data.txt --backend ort --device cpu --cpu_num_threads ${cpu_num_threads} --enable_collect_memory_info True
|
||||
python benchmark_uie.py --epoch 5 --model_dir uie-base --data_path reimbursement_form_data.txt --backend ov --device cpu --cpu_num_threads ${cpu_num_threads} --enable_collect_memory_info True
|
||||
done
|
||||
echo "-----------------------------------------------------------------------------------"
|
Reference in New Issue
Block a user