New Project: CoralAPI

Available now; CoralAPI. Point it at a Google Coral Edge TPU, POST an image, get JSON back.

Coral’s little accelerators are great hardware. Real object detection on a few watts, on a Raspberry Pi or a mini PC, no GPU and no cloud bill. The software stack around them has aged badly, though. The official Python library, pycoral, is stuck on Python 3.9. The projects that put a Coral behind an API, mostly CodeProject.AI’s Coral path, are heavy and half-maintained… when they run at all.

I built CoralAPI because nothing out there was current. Getting a newer model running, a recent YOLO export for example, meant fighting the toolchain or forking someone’s stale wrapper, and in a few cases standing up the existing options was more work than writing a clean one. So I wrote the clean one.

CoralAPI is a small FastAPI service. It runs on current Python and ships a matched libedgetpu and tflite runtime, built on feranick’s community packages, that actually work together; getting that pairing right is harder than it has any right to be. There are build profiles for modern CPUs, older no-AVX2 boxes, and the Raspberry Pi. Models download on demand. What it does:

  • Classification
  • Object detection (SSD and YOLO)
  • Semantic segmentation
  • Pose estimation
  • Image embeddings
  • Raw tensor output for anything it doesn’t recognize

No CPU fallback; if there’s no Coral attached it exits at startup and tells you why. That’s on purpose. A running instance always means real acceleration.

Put a Coral behind a URL and get on with your day. MIT licensed. PRs and feedback welcome.

-Nathan

Leave a Reply

Your email address will not be published. Required fields are marked *