Preparation
You need to flash ubuntu image V190830.
Update kernel
You need to update the kernel to add NPU module support.
khadas@Khadas:~$ sudo -i
root@Khadas:~# apt-get update
root@Khadas:~# apt-get upgrade
root@Khadas:~# echo galcore >> /etc/modules
root@Khadas:~# sync
root@Khadas:~# reboot
After reboot, you can check whether the NPU module exist or not.
root@Khadas:~# lsmod | grep galcore
galcore 442368 0
If you find the galcore
module, indicate that the NPU module is loaded.
Install NPU libraries and demo
khadas@Khadas:~$ sudo apt-get update
khadas@Khadas:~$ sudo apt-get install aml-npu aml-npu-demo
There is a Inception V3 demo, you can run it.
khadas@Khadas:~$ sudo -i
root@Khadas:~# cd /usr/share/npu/inceptionv3
root@Khadas:/usr/share/npu/inceptionv3# ./run.sh
Create Neural Network: 82ms or 82537us
Verify...
********pid is 136 *********
Verify Graph: 181ms or 181495us
Start run graph [1] times...
Run the 1 time: 22ms or 22021us
vxProcessGraph execution time:
Total 22ms or 22050us
Average 22.00ms or 22050.00us
--- Top5 ---
2: 0.897461
795: 0.004154
974: 0.001733
408: 0.001349
399: 0.001191
You can check the result with labels in imagenet_slim_labels.txt .
In the End
We are working on the documentation and model convert tools, and we will release them soon.
Thanks.