Installation on Linux laptop
Fairly easy, follow the instructions here:
https://coral.ai/docs/accelerator/get-started/#1-install-the-edge-tpu-runtime
https://coral.ai/docs/accelerator/get-started/#runtime-on-linux
We got side-tracked when the initial attempt failed and we tried to continue. This was because the installation commands change directory in places, and if you are in the wrong directory and try to continue, it won't find the files it expects and will then throw errors.
Eventually it installed correctly.
Installation on Linux floortop
It says you need a USB 3 port, but I only have USB 2 ports right now.
I plugged the TPU in anyway, to see if it would work.
Running the demo code on the laptop
The instructions say you should get results like this:
----INFERENCE TIME----
Note: The first inference on Edge TPU is slow because it includes loading the model into Edge TPU memory.
11.8ms
3.0ms
2.8ms
2.9ms
2.9ms
-------RESULTS--------
Ara macao (Scarlet Macaw): 0.75781
And indeed we did.
Running the demo code on the floortop
I got these results:
136.7ms
16.3ms
16.3ms
16.2ms
16.4ms
This shows it still works but runs slower. Nearly 12 times slower for initial loading of the model, and nearly 6 times slower thereafter.
Just to check it was the TPU and not the CPU, I pulled the TPU out and tried running the program again. I got various errors like: Failed to load delegate from libedgetpu.so.1
Plugging the TPU back in restored working operation.
I had hoped that the software would notice the TPU was not there and assign the work to the CPU. That would make speed comparison tests much easier.
The TPU did not get warm, so presumably it is in a low-power idle mode when not doing work. I expect it will get warm recognising objects in real-time video.
Okay, all I need to do is order a USB 3 card for my PC. I ordered one. This gave the following times:
15.5ms
4.7ms
4.7ms
4.7ms
4.7ms
This is with standard speed. After installing with maximum speed:
sudo apt-get install libedgetpu1-max
I got the following times:
14.1ms
3.2ms
3.2ms
3.2ms
3.1ms
Which is much more satisfactory, 68% of the slow times.
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.