There are up to 14 model samples that are loacated in ~/Vitis-AI/Vitis-AI-Library/overview/samples. Each sample has the following four kinds of test samples.
- test_jpeg_[model type]
- test_video_[model type]
- test_performance_[model type]
- test_accuracy_[model type]
Take yolov3 as an example.
- Before you run the yolov3 detection example, you can choose one of the following
yolov3 model to run.
- yolov3_bdd
- yolov3_voc
- yolov3_voc_tf
- Ensure that the following test program exists.
- test_jpeg_yolov3
- test_video_yolov3
- test_performance_yolov3
- test_accuracy_yolov3
#sh -x build.sh
- To test the image data, execute the following
command.
#./test_jpeg_yolov3 yolov3_bdd sample_yolov3.jpg
You will see the printing result on the terminal. Also, you can view the output image: sample_yolov3_result.jpg.
- To test the video data, execute the following
command.
#./test_video_yolov3 yolov3_bdd video_input.mp4 -t 8
- To test the model performance, execute the following
command.
You will see the printing result on the terminal.#./test_performance_yolov3 yolov3_bdd test_performance_yolov3.list -t 8
- To test the model accurary, prepare your own image dataset, image list file
and the ground truth of the images. Then execute the following
command.
#./test_accuracy_yolov3 yolov3_bdd [image_list_file] [output_file]
After the output_file is generate, a script file is needed to automatically compare the results. Finally, the accuracy result can be obtained.