Nice to find this thread. I just installed my coral pieces last night:
Integrate two Edge TPUs into legacy and new systems using an M.2 (E key) interface.
coral.ai
Dual Edge TPU Adapter is designed for Coral m.2 Accelerator with Dual Edge TPU to be used on a system with PCIe x1 slot available.
www.makerfabs.com
I see two Coral PCIe Accelerator adapters in Device Manager under Windows and I'm running CPAI 2.9.5.
It won't initialize the second TPU though: Starting Coral gives me this error:
06:35:32
bjectdetection_coral_adapter.py: ERROR:root:TFLite file C:\Program Files\CodeProject\AI\modules\ObjectDetectionCoral\assets\yolov5l-int8_edgetpu.tflite doesn't exist
06:35:32
bjectdetection_coral_adapter.py: WARNING:root:Model file not found: [Errno 2] No such file or directory: 'C:\\Program Files\\CodeProject\\AI\\modules\\ObjectDetectionCoral\\assets\\yolov5l-int8_edgetpu.tflite'
06:35:32
bjectdetection_coral_adapter.py: WARNING:root:No Coral TPUs found or able to be initialized. Using CPU.
06:35:32
bjectdetection_coral_adapter.py: ERROR:root:TFLite file C:\Program Files\CodeProject\AI\modules\ObjectDetectionCoral\assets\yolov5l-int8.tflite doesn't exist
06:35:32
bjectdetection_coral_adapter.py: WARNING:root:Unable to create interpreter for CPU using edgeTPU library: [Errno 2] No such file or directory: 'C:\\Program Files\\CodeProject\\AI\\modules\\ObjectDetectionCoral\\assets\\yolov5l-int8.tflite'
06:35:32
bjectdetection_coral_adapter.py: Using PIL for image manipulation (Either OpenCV or numpy not available for this module)
06:35:32
bjectdetection_coral_adapter.py: TPU detected
06:35:32
bjectdetection_coral_adapter.py: Attempting multi-TPU initialisation
06:35:32
bjectdetection_coral_adapter.py: Failed to init multi-TPU. Falling back to single TPU.
06:35:32
bjectdetection_coral_adapter.py: Using Edge TPU
Switching to single TPU results in no startup errors.
06:39:49:Started Object Detection (Coral) module
06:39:51
bjectdetection_coral_adapter.py: Using PIL for image manipulation (Either OpenCV or numpy not available for this module)
06:39:51
bjectdetection_coral_adapter.py: TPU detected
06:39:51
bjectdetection_coral_adapter.py: Using Edge TPU
Reading this thread
@koops had this problem as well. Is there any solution for it to get both TPUs working?
I did some testing and tuning last night after getting it installed. Set it up to use the YOLOv5 model at medium model size. At first I though it was broken because it was not detecting anything. I had minimum confidence set to 90% to prevent false positives when I was using CPU for object detection. Once I dropped it to 60% is started detecting. But it rare that it would ever get into 70%range. Speed was good at 35-45ms though. Compared to the CPU which was over 1000ms most of the time. Saw quite a few false positives though detecting pine trees as people. After a bit more tuning, I tried the large model size and the detection confidence rose into the 80's% range. It also no longer detecting the pine trees as people even though the minimum confidence was set to 50%. Downside is it now takes 210-225ms to detect. Compared to the 1000+ms before with using the CPU, it's a huge improvement. The CPU usage of the server itself is also much better running about 20-50% instead of 100% during detection. The CPU is still doing face and LPR processing.
Other things I've noticed with using Coral compared to CPU. Coral has a harder time detecting cats and dogs. Coral can't detect objects as far away as the CPU. My Dahua PTZ AI cameras have 25x zoom so that isn't so much a problem if I'm trying to detect a person or vehicle as it will zoom in on those.
So overall, I'm very happy with the Coral performance improvement. Now to just get that second TPU to work and I can call it done.
Any thoughts on the YOLOv5 vs YOLOv8 models? Both seemed to work but I didn't see any better detection between the two.