run_yolov3_220.sh 941 B

1234567891011121314151617181920212223242526272829
  1. #! /bin/bash
  2. CURRENT_DIR=$(dirname $(readlink -f $0) )
  3. pushd $CURRENT_DIR
  4. mkdir -p cache
  5. if [ ! -f "cache/yolov3_bs4core4_v1.5.0.cambricon" ]; then
  6. wget -O cache/yolov3_bs4core4_v1.5.0.cambricon http://video.cambricon.com/models/MLU220/Primary_Detector/YOLOv3/yolov3_bs4core4_v1.5.0.cambricon
  7. fi
  8. if [ ! -f "cache/label_map_coco.txt" ]; then
  9. wget -O cache/label_map_coco.txt http://video.cambricon.com/models/MLU220/Primary_Detector/YOLOv3/label_map_coco.txt
  10. fi
  11. model_file="${CURRENT_DIR}/cache/yolov3_bs4core4_v1.5.0.cambricon"
  12. label_path="${CURRENT_DIR}/cache/label_map_coco.txt"
  13. data_path="${CURRENT_DIR}/../data/videos/cars.mp4"
  14. track_model_path="cpu"
  15. ../bin/stream-app \
  16. --model_path $model_file \
  17. --track_model_path $track_model_path \
  18. --label_path $label_path \
  19. --data_path $data_path \
  20. --net_type "YOLOv3" \
  21. --show=false \
  22. --save_video=true \
  23. --wait_time 0 \
  24. --repeat_time 0
  25. popd