NOTE: If you have a compatible Nvidia graphics card with CUDA support, you may install the GPU docker. Remember to run the GPU docker with replacement of vitis-ai-gpu:latest.
$ cd {VITIS_AI_PATH}
$ sudo chmod 666 /var/run/docker.sock
$ ./docker_run.sh --device /dev/video0 xilinx/vitis-ai-cpu:latest
- Quantization
- Using a subset (70 images) of validation data for calibration.
$ python model_quant.py --quant_mode calib --subset_len 70
- Export xmodel
$ python model_quant.py --quant_mode test --subset_len 1 --batch_size 1 --deploy
- Setup VCK5000
$ cd setup/vck5000
$ source ./setup.sh
- Conda Pytorch enviroments
$ conda activate vitis-ai-pytorch
$ source ./setup.sh
- Check DPU
$ sudo chmod o=rw /dev/dri/render*
$ xdputil query
$ cd /workspace/
$ vai_c_xir -x HarDMSEG_int.xmodel -a arch.json -o ./ -n dpu_HarDMSEG
These packages are for showing the windows on local screens.
$ export DISPLAY=":0"
$ sudo apt update
$ sudo apt-get install libcanberra-gtk-module libcanberra-gtk3-module
Note: At most 8 videos are supported due to the limitation of DPU.
$ cd {FOLDER_PATH}
$ bash -x build.sh
$ ./{FOLDER_NAME} dpu_HarDMSEG.xmodel {VIDEO_PATH1} {VIDEO_PATH2} {VIDEO_PATH3} {VIDEO_PATH4}
- Use only one CPU : Intel® Core™ i7-3770